Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=fa8e29cff748efc7118c66b51f1241a927d86b98
Commit:     fa8e29cff748efc7118c66b51f1241a927d86b98
Parent:     6e3632f66110b144183d53d550a51cbbbabc178f
Author:     Ulrich Kunitz <[EMAIL PROTECTED]>
AuthorDate: Mon Jan 29 00:59:40 2007 +0000
Committer:  John W. Linville <[EMAIL PROTECTED]>
CommitDate: Wed Feb 7 15:23:54 2007 -0500

    [PATCH] zd1211rw: Fixed array size issue in reset_mode
    
    Andy Green found this issue.
    
    Signed-off-by: Daniel Drake <[EMAIL PROTECTED]>
    Signed-off-by: John W. Linville <[EMAIL PROTECTED]>
---
 drivers/net/wireless/zd1211rw/zd_mac.c |    5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/net/wireless/zd1211rw/zd_mac.c 
b/drivers/net/wireless/zd1211rw/zd_mac.c
index a085241..1379c91 100644
--- a/drivers/net/wireless/zd1211rw/zd_mac.c
+++ b/drivers/net/wireless/zd1211rw/zd_mac.c
@@ -156,7 +156,7 @@ void zd_mac_clear(struct zd_mac *mac)
 static int reset_mode(struct zd_mac *mac)
 {
        struct ieee80211_device *ieee = zd_mac_to_ieee80211(mac);
-       struct zd_ioreq32 ioreqs[3] = {
+       struct zd_ioreq32 ioreqs[] = {
                { CR_RX_FILTER, STA_RX_FILTER },
                { CR_SNIFFER_ON, 0U },
        };
@@ -164,10 +164,9 @@ static int reset_mode(struct zd_mac *mac)
        if (ieee->iw_mode == IW_MODE_MONITOR) {
                ioreqs[0].value = 0xffffffff;
                ioreqs[1].value = 0x1;
-               ioreqs[2].value = ENC_SNIFFER;
        }
 
-       return zd_iowrite32a(&mac->chip, ioreqs, 3);
+       return zd_iowrite32a(&mac->chip, ioreqs, ARRAY_SIZE(ioreqs));
 }
 
 int zd_mac_open(struct net_device *netdev)
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to