aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/zd1211rw/zd_mac.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/wireless/zd1211rw/zd_mac.c')
-rw-r--r--drivers/net/wireless/zd1211rw/zd_mac.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/net/wireless/zd1211rw/zd_mac.c b/drivers/net/wireless/zd1211rw/zd_mac.c
index d6f3e02a0b54..0eda534a648c 100644
--- a/drivers/net/wireless/zd1211rw/zd_mac.c
+++ b/drivers/net/wireless/zd1211rw/zd_mac.c
@@ -127,11 +127,9 @@ out:
127 127
128void zd_mac_clear(struct zd_mac *mac) 128void zd_mac_clear(struct zd_mac *mac)
129{ 129{
130 /* Aquire the lock. */
131 spin_lock(&mac->lock);
132 spin_unlock(&mac->lock);
133 zd_chip_clear(&mac->chip); 130 zd_chip_clear(&mac->chip);
134 memset(mac, 0, sizeof(*mac)); 131 ZD_ASSERT(!spin_is_locked(&mac->lock));
132 ZD_MEMCLEAR(mac, sizeof(struct zd_mac));
135} 133}
136 134
137static int reset_mode(struct zd_mac *mac) 135static int reset_mode(struct zd_mac *mac)