linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jonathan Bither <jonbither@gmail.com>
To: linux-wireless@vger.kernel.org
Subject: ath5k: add missing iounmap to AHB probe removal
Date: Tue, 24 Apr 2012 04:29:51 -0400	[thread overview]
Message-ID: <4F96647F.9060803@gmail.com> (raw)

When our driver device is removed on the AHB bus, our IO memory is never unmapped.

Signed-off-by: Jonathan Bither <jonbither@gmail.com>

diff --git a/drivers/net/wireless/ath/ath5k/ahb.c b/drivers/net/wireless/ath/ath5k/ahb.c
index 8c50d9d..eebf439 100644
--- a/drivers/net/wireless/ath/ath5k/ahb.c
+++ b/drivers/net/wireless/ath/ath5k/ahb.c
@@ -197,12 +197,14 @@ static int ath_ahb_remove(struct platform_device *pdev)
 	struct ar231x_board_config *bcfg = pdev->dev.platform_data;
 	struct ieee80211_hw *hw = platform_get_drvdata(pdev);
 	struct ath5k_hw *ah;
+	void __iomem *mem;
 	u32 reg;
 
 	if (!hw)
 		return 0;
 
 	ah = hw->priv;
+	mem = ah->iobase;
 
 	if (bcfg->devid >= AR5K_SREV_AR2315_R6) {
 		/* Disable WMAC AHB arbitration */
@@ -222,6 +224,7 @@ static int ath_ahb_remove(struct platform_device *pdev)
 	ath5k_deinit_ah(ah);
 	platform_set_drvdata(pdev, NULL);
 	ieee80211_free_hw(hw);
+	iounmap(mem);
 
 	return 0;
 }

             reply	other threads:[~2012-04-24  8:29 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-24  8:29 Jonathan Bither [this message]
2012-04-24  8:42 ` ath5k: add missing iounmap to AHB probe removal Florian Fainelli
2012-04-24  8:45   ` Jonathan Bither

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4F96647F.9060803@gmail.com \
    --to=jonbither@gmail.com \
    --cc=linux-wireless@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).