summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/mwifiex/pcie.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2013-04-30 04:11:37 (GMT)
committerDavid S. Miller <davem@davemloft.net>2013-04-30 04:11:37 (GMT)
commit1ab137bc99138dd0d459655642bee16afec8b7ce (patch)
treef43367184618f8927f6a8a675b54c835aee5e705 /drivers/net/wireless/mwifiex/pcie.c
parentb807a3d688c7b1da86662b220ace548389c48167 (diff)
parent17a2911f3395d66694fcbd2e8970015904d9b034 (diff)
downloadlinux-fsl-qoriq-1ab137bc99138dd0d459655642bee16afec8b7ce.tar.xz
Merge branch 'for-davem' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next
John W. Linville says: ==================== A few more stragglers intended for 3.10... For the Bluetooth bits, Gustavo says: "A few more patches intended for 3.10, the most important one is the support in btusb for fw loading for the Intel Bluetooth device. Other than that we have only fixes and clean ups." For the iwlwifi bits, Johannes says: "Here are a few more changes for the 3.10 stream, some bugfixes, adjustments to some powersave parameters and a new device ID." For the NFC bits, Samuel says: "This pull request includes Marcel's Kconfig dependency fix on top of the LLCP code move to net/nfc." On top of that...Yogesh Ashok Powar provides a few PCI-related mwifiex updates, Hauke Mehrtens provides a small ssb feature for spurious tone avoidance on a specific chip, and Larry Finger provides a small rtlwifi fix related to avoiding false detection of AP loss. ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/wireless/mwifiex/pcie.c')
-rw-r--r--drivers/net/wireless/mwifiex/pcie.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/drivers/net/wireless/mwifiex/pcie.c b/drivers/net/wireless/mwifiex/pcie.c
index 80f282c..20c9c4c 100644
--- a/drivers/net/wireless/mwifiex/pcie.c
+++ b/drivers/net/wireless/mwifiex/pcie.c
@@ -861,9 +861,8 @@ static int mwifiex_pcie_delete_cmdrsp_buf(struct mwifiex_adapter *adapter)
if (card && card->cmd_buf) {
MWIFIEX_SKB_PACB(card->cmd_buf, &buf_pa);
- pci_unmap_single(card->dev, buf_pa, MWIFIEX_SIZE_OF_CMD_BUFFER,
+ pci_unmap_single(card->dev, buf_pa, card->cmd_buf->len,
PCI_DMA_TODEVICE);
- dev_kfree_skb_any(card->cmd_buf);
}
return 0;
}
@@ -1573,7 +1572,7 @@ static int mwifiex_pcie_cmdrsp_complete(struct mwifiex_adapter *adapter,
skb_tmp = card->cmd_buf;
if (skb_tmp) {
MWIFIEX_SKB_PACB(skb_tmp, &buf_pa);
- pci_unmap_single(card->dev, buf_pa, MWIFIEX_UPLD_SIZE,
+ pci_unmap_single(card->dev, buf_pa, skb_tmp->len,
PCI_DMA_FROMDEVICE);
card->cmd_buf = NULL;
}
@@ -2294,9 +2293,9 @@ static void mwifiex_pcie_cleanup(struct mwifiex_adapter *adapter)
if (pdev) {
pci_iounmap(pdev, card->pci_mmap);
pci_iounmap(pdev, card->pci_mmap1);
-
- pci_release_regions(pdev);
pci_disable_device(pdev);
+ pci_release_region(pdev, 2);
+ pci_release_region(pdev, 0);
pci_set_drvdata(pdev, NULL);
}
}