
From: "Luis R. Rodriguez" <mcgrof@studorgs.rutgers.edu>

2004-03-22	Aurelien Alleaume <slts@free.fr>

- oid_mgt.c, isl_ioctl.c : Minor bugfixes : #74 and #75.

Signed-off-by: Andrew Morton <akpm@osdl.org>
---

 25-akpm/drivers/net/wireless/prism54/isl_ioctl.c |    9 +++++----
 25-akpm/drivers/net/wireless/prism54/oid_mgt.c   |    4 ++--
 2 files changed, 7 insertions(+), 6 deletions(-)

diff -puN drivers/net/wireless/prism54/isl_ioctl.c~prism54-fix-prism54org-bugs-74-75 drivers/net/wireless/prism54/isl_ioctl.c
--- 25/drivers/net/wireless/prism54/isl_ioctl.c~prism54-fix-prism54org-bugs-74-75	Wed May 26 16:17:01 2004
+++ 25-akpm/drivers/net/wireless/prism54/isl_ioctl.c	Wed May 26 16:17:01 2004
@@ -1,4 +1,4 @@
-/*  $Header: /var/lib/cvs/prism54-ng/ksrc/isl_ioctl.c,v 1.149 2004/03/20 16:58:36 mcgrof Exp $
+/*  $Header: /var/lib/cvs/prism54-ng/ksrc/isl_ioctl.c,v 1.150 2004/03/22 11:21:22 ajfa Exp $
  *  
  *  Copyright (C) 2002 Intersil Americas Inc.
  *            (C) 2003,2004 Aurelien Alleaume <slts@free.fr>
@@ -329,9 +329,9 @@ prism54_set_freq(struct net_device *ndev
 	int rvalue;
 	u32 c;
 
-	if (fwrq->m  < 1000)
+	if (fwrq->m < 1000)
 		/* we have a channel number */
-		c =  fwrq->m;
+		c = fwrq->m;
 	else
 		c = (fwrq->e == 1) ? channel_of_freq(fwrq->m / 100000) : 0;
 
@@ -1893,7 +1893,8 @@ prism54_process_trap(void *data)
 	struct net_device *ndev = frame->ndev;
 	enum oid_num_t n = mgt_oidtonum(frame->header->oid);
 
-	prism54_process_trap_helper(netdev_priv(ndev), n, frame->data);
+	if (n != OID_NUM_LAST)
+		prism54_process_trap_helper(netdev_priv(ndev), n, frame->data);
 	islpci_mgt_release(frame);
 }
 
diff -puN drivers/net/wireless/prism54/oid_mgt.c~prism54-fix-prism54org-bugs-74-75 drivers/net/wireless/prism54/oid_mgt.c
--- 25/drivers/net/wireless/prism54/oid_mgt.c~prism54-fix-prism54org-bugs-74-75	Wed May 26 16:17:01 2004
+++ 25-akpm/drivers/net/wireless/prism54/oid_mgt.c	Wed May 26 16:17:01 2004
@@ -688,13 +688,13 @@ mgt_oidtonum(u32 oid)
 {
 	int i;
 
-	for (i = 0; i < OID_NUM_LAST - 1; i++)
+	for (i = 0; i < OID_NUM_LAST; i++)
 		if (isl_oid[i].oid == oid)
 			return i;
 
 	printk(KERN_DEBUG "looking for an unknown oid 0x%x", oid);
 
-	return 0;
+	return OID_NUM_LAST;
 }
 
 int
_
