|
@@ -2852,15 +2852,15 @@ static void iwl3945_bg_request_scan(struct work_struct *data)
|
|
goto done;
|
|
goto done;
|
|
}
|
|
}
|
|
|
|
|
|
- if (!priv->scan) {
|
|
|
|
- priv->scan = kmalloc(sizeof(struct iwl3945_scan_cmd) +
|
|
|
|
- IWL_MAX_SCAN_SIZE, GFP_KERNEL);
|
|
|
|
- if (!priv->scan) {
|
|
|
|
|
|
+ if (!priv->scan_cmd) {
|
|
|
|
+ priv->scan_cmd = kmalloc(sizeof(struct iwl3945_scan_cmd) +
|
|
|
|
+ IWL_MAX_SCAN_SIZE, GFP_KERNEL);
|
|
|
|
+ if (!priv->scan_cmd) {
|
|
IWL_DEBUG_SCAN(priv, "Fail to allocate scan memory\n");
|
|
IWL_DEBUG_SCAN(priv, "Fail to allocate scan memory\n");
|
|
goto done;
|
|
goto done;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
- scan = priv->scan;
|
|
|
|
|
|
+ scan = priv->scan_cmd;
|
|
memset(scan, 0, sizeof(struct iwl3945_scan_cmd) + IWL_MAX_SCAN_SIZE);
|
|
memset(scan, 0, sizeof(struct iwl3945_scan_cmd) + IWL_MAX_SCAN_SIZE);
|
|
|
|
|
|
scan->quiet_plcp_th = IWL_PLCP_QUIET_THRESH;
|
|
scan->quiet_plcp_th = IWL_PLCP_QUIET_THRESH;
|
|
@@ -4245,7 +4245,7 @@ static void __devexit iwl3945_pci_remove(struct pci_dev *pdev)
|
|
|
|
|
|
iwl_free_channel_map(priv);
|
|
iwl_free_channel_map(priv);
|
|
iwlcore_free_geos(priv);
|
|
iwlcore_free_geos(priv);
|
|
- kfree(priv->scan);
|
|
|
|
|
|
+ kfree(priv->scan_cmd);
|
|
if (priv->ibss_beacon)
|
|
if (priv->ibss_beacon)
|
|
dev_kfree_skb(priv->ibss_beacon);
|
|
dev_kfree_skb(priv->ibss_beacon);
|
|
|
|
|