linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Nishant Sarmukadam <nishants@marvell.com>
To: linux-wireless@vger.kernel.org
Cc: buytenh@wantstofly.org, Nishant Sarmukadam <nishants@marvell.com>
Subject: [PATCH] mwl8k: interrupt handling changes
Date: Fri,  8 Apr 2011 14:00:49 +0530	[thread overview]
Message-ID: <1302251449-763-1-git-send-email-nishants@marvell.com> (raw)

We do not need to enable all the interrupts in mwl8k_probe_hw.
We need to enable only MWL8K_A2H_INT_OPC_DONE interrupt for sending
commands to the firmware. Keep the other interrupts masked in
mwl8k_probe_hw. Also, in mwl8k_start, where we expect other interrupts,
enable only those interrupts we are interested in.

Signed-off-by: Nishant Sarmukadam <nishants@marvell.com>
---
 drivers/net/wireless/mwl8k.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/drivers/net/wireless/mwl8k.c b/drivers/net/wireless/mwl8k.c
index 8913180..07e8134 100644
--- a/drivers/net/wireless/mwl8k.c
+++ b/drivers/net/wireless/mwl8k.c
@@ -4285,6 +4285,8 @@ static int mwl8k_start(struct ieee80211_hw *hw)
 
 	/* Enable interrupts */
 	iowrite32(MWL8K_A2H_EVENTS, priv->regs + MWL8K_HIU_A2H_INTERRUPT_MASK);
+	iowrite32(MWL8K_A2H_EVENTS,
+		  priv->regs + MWL8K_HIU_A2H_INTERRUPT_STATUS_MASK);
 
 	rc = mwl8k_fw_lock(hw);
 	if (!rc) {
@@ -5283,7 +5285,8 @@ static int mwl8k_probe_hw(struct ieee80211_hw *hw)
 	iowrite32(MWL8K_A2H_INT_TX_DONE|MWL8K_A2H_INT_RX_READY|
 		  MWL8K_A2H_INT_BA_WATCHDOG,
 		  priv->regs + MWL8K_HIU_A2H_INTERRUPT_CLEAR_SEL);
-	iowrite32(0xffffffff, priv->regs + MWL8K_HIU_A2H_INTERRUPT_STATUS_MASK);
+	iowrite32(MWL8K_A2H_INT_OPC_DONE,
+		  priv->regs + MWL8K_HIU_A2H_INTERRUPT_STATUS_MASK);
 
 	rc = request_irq(priv->pdev->irq, mwl8k_interrupt,
 			 IRQF_SHARED, MWL8K_NAME, hw);
-- 
1.6.0.3


             reply	other threads:[~2011-04-08  9:15 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-04-08  8:30 Nishant Sarmukadam [this message]
  -- strict thread matches above, loose matches on Subject: below --
2011-04-08  9:08 [PATCH] mwl8k: interrupt handling changes Nishant Sarmukadam
2011-04-08 18:19 ` Lennert Buytenhek
2011-04-11  6:13   ` Nishant Sarmukadam

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=1302251449-763-1-git-send-email-nishants@marvell.com \
    --to=nishants@marvell.com \
    --cc=buytenh@wantstofly.org \
    --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).