From d033d3a6b16cc0bbd9defaa048c65cbef9feab14 Mon Sep 17 00:00:00 2001 From: Avinash Patil Date: Fri, 19 Apr 2013 17:44:42 -0700 Subject: [PATCH] mwifiex: use PCI_DMA_FROMDEVICE for RX queue de-init There is a typo in mwifiex_cleanup_rxq_ring() which uses PCI_DMA_TODEVICE while unmapping PCI memory. We should actually use PCI_DMA_FROMDEVICE. Signed-off-by: Avinash Patil Signed-off-by: Yogesh Ashok Powar Signed-off-by: Bing Zhao Signed-off-by: John W. Linville --- drivers/net/wireless/mwifiex/pcie.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/wireless/mwifiex/pcie.c b/drivers/net/wireless/mwifiex/pcie.c index 856959b64bc7..80f282c0bd4d 100644 --- a/drivers/net/wireless/mwifiex/pcie.c +++ b/drivers/net/wireless/mwifiex/pcie.c @@ -572,7 +572,7 @@ static void mwifiex_cleanup_rxq_ring(struct mwifiex_adapter *adapter) if (card->rx_buf_list[i]) { skb = card->rx_buf_list[i]; pci_unmap_single(card->dev, desc2->paddr, - skb->len, PCI_DMA_TODEVICE); + skb->len, PCI_DMA_FROMDEVICE); dev_kfree_skb_any(skb); } memset(desc2, 0, sizeof(*desc2)); @@ -581,7 +581,7 @@ static void mwifiex_cleanup_rxq_ring(struct mwifiex_adapter *adapter) if (card->rx_buf_list[i]) { skb = card->rx_buf_list[i]; pci_unmap_single(card->dev, desc->paddr, - skb->len, PCI_DMA_TODEVICE); + skb->len, PCI_DMA_FROMDEVICE); dev_kfree_skb_any(skb); } memset(desc, 0, sizeof(*desc)); -- 2.30.2