From: Stephen Hemminger <shemminger@linux-foundation.org>
To: "John W. Linville" <linville@tuxdriver.com>,
James Ketrenos <jketreno@linux.intel.com>
Cc: linux-wireless@vger.kernel.org
Subject: [PATCH] iwlwifi: MSI support
Date: Wed, 13 Jun 2007 11:29:39 -0700 [thread overview]
Message-ID: <20070613112939.3b73f928@localhost> (raw)
Add Message Signal Interrupt support to iwlwifi. Tested on 3945.
Enable by default, but have parameter to disable for buggy platforms.
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
--- a/drivers/net/wireless/mac80211/iwlwifi/base.c 2007-06-13 11:10:10.000000000 -0700
+++ b/drivers/net/wireless/mac80211/iwlwifi/base.c 2007-06-13 11:26:30.000000000 -0700
@@ -80,6 +80,8 @@ int param_antenna = 0; /* def: 0 =
int param_hwcrypto = 0; /* def: using software encryption */
int param_qos_enable = 0;
+static int disable_msi;
+
/*
* module name, copyright, version, etc.
* NOTE: DRV_NAME is defined in iwlwifi.h for use by iwl-debug.h and printk
@@ -8117,6 +8119,10 @@ static int iwl_pci_probe(struct pci_dev
/* If power management is turned on, default to AC mode */
priv->power_mode = IWL_POWER_AC;
priv->user_txpower_limit = IWL_DEFAULT_TX_POWER;
+
+ if (!disable_msi)
+ pci_enable_msi(pdev);
+
err = request_irq(pdev->irq, iwl_isr, IRQF_SHARED, DRV_NAME, priv);
if (err) {
IWL_ERROR("Error allocating IRQ %d\n", pdev->irq);
@@ -8155,6 +8161,7 @@ static int iwl_pci_probe(struct pci_dev
sysfs_remove_group(&pdev->dev.kobj, &iwl_attribute_group);
out_release_irq:
+ pci_disable_msi(pdev);
free_irq(pdev->irq, priv);
out_destroy_workqueue:
@@ -8224,6 +8231,8 @@ static void iwl_pci_remove(struct pci_de
destroy_workqueue(priv->workqueue);
priv->workqueue = NULL;
+ pci_disable_msi(pdev);
+
free_irq(pdev->irq, priv);
iounmap(priv->hw_base);
pci_release_regions(pdev);
@@ -8352,6 +8361,9 @@ static void __exit iwl_exit(void)
pci_unregister_driver(&iwl_driver);
}
+module_param(disable_msi, int, 0);
+MODULE_PARM_DESC(disable_msi, "Disable Message Signaled Interrupt (MSI)");
+
module_param_named(antenna, param_antenna, int, 0444);
MODULE_PARM_DESC(antenna, "select antenna (1=Main, 2=Aux, default 0 [both])");
module_param_named(disable, param_disable, int, 0444);
next reply other threads:[~2007-06-13 18:30 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-06-13 18:29 Stephen Hemminger [this message]
2007-06-13 18:39 ` [PATCH] iwlwifi: MSI support Jeff Garzik
2007-06-13 20:28 ` Stephen Hemminger
2007-06-13 20:30 ` Jeff Garzik
2007-06-13 18:41 ` Randy Dunlap
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=20070613112939.3b73f928@localhost \
--to=shemminger@linux-foundation.org \
--cc=jketreno@linux.intel.com \
--cc=linux-wireless@vger.kernel.org \
--cc=linville@tuxdriver.com \
/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).