iwlwifi: fix 4965 notification wait setup
authorJohannes Berg <johannes.berg@intel.com>
Wed, 5 Jan 2011 00:22:03 +0000 (16:22 -0800)
committerJohn W. Linville <linville@tuxdriver.com>
Fri, 21 Jan 2011 20:32:21 +0000 (15:32 -0500)
The notification wait support code is shared
between 4965 and other AGN devices, so 4965
also has to initialize the data structures
for it, otherwise it crashes.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/iwlwifi/iwl-4965.c

index 3f1e5f1bf84720932e25ffa88f63b4f80d972d9a..d9a7d93def6cf914ac3772e2e91d22f5a969096f 100644 (file)
@@ -2316,6 +2316,11 @@ static void iwl4965_rx_handler_setup(struct iwl_priv *priv)
        priv->rx_handlers[REPLY_RX] = iwlagn_rx_reply_rx;
        /* Tx response */
        priv->rx_handlers[REPLY_TX] = iwl4965_rx_reply_tx;
+
+       /* set up notification wait support */
+       spin_lock_init(&priv->_agn.notif_wait_lock);
+       INIT_LIST_HEAD(&priv->_agn.notif_waits);
+       init_waitqueue_head(&priv->_agn.notif_waitq);
 }
 
 static void iwl4965_setup_deferred_work(struct iwl_priv *priv)