From: Tomas Winkler <tomas.winkler@intel.com>
To: gregkh@linuxfoundation.org
Cc: alan@linux.intel.com, devel@linuxdriverproject.org,
linux-kernel@vger.kernel.org,
Samuel Ortiz <sameo@linux.intel.com>,
Tomas Winkler <tomas.winkler@intel.com>
Subject: [PATCH for v3.5 1/2] misc: mei: Disable MSI when IRQ registration fails
Date: Mon, 11 Jun 2012 12:18:30 +0300 [thread overview]
Message-ID: <1339406311-27283-1-git-send-email-tomas.winkler@intel.com> (raw)
From: Samuel Ortiz <sameo@linux.intel.com>
Since MSI is enabled right before that, we should disable it when
registration fails.
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
---
drivers/misc/mei/main.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/misc/mei/main.c b/drivers/misc/mei/main.c
index a5a17e7..7de1389 100644
--- a/drivers/misc/mei/main.c
+++ b/drivers/misc/mei/main.c
@@ -992,7 +992,7 @@ static int __devinit mei_probe(struct pci_dev *pdev,
if (err) {
dev_err(&pdev->dev, "request_threaded_irq failure. irq = %d\n",
pdev->irq);
- goto unmap_memory;
+ goto disable_msi;
}
INIT_DELAYED_WORK(&dev->timer_work, mei_timer);
if (mei_hw_init(dev)) {
@@ -1023,8 +1023,8 @@ release_irq:
mei_disable_interrupts(dev);
flush_scheduled_work();
free_irq(pdev->irq, dev);
+disable_msi:
pci_disable_msi(pdev);
-unmap_memory:
pci_iounmap(pdev, dev->mem_addr);
free_device:
kfree(dev);
--
1.7.4.4
next reply other threads:[~2012-06-11 9:18 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-06-11 9:18 Tomas Winkler [this message]
2012-06-11 9:18 ` [PATCH for v3.5 2/2] misc: mei: set WDIOF_ALARMONLY on mei watchdog Tomas Winkler
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=1339406311-27283-1-git-send-email-tomas.winkler@intel.com \
--to=tomas.winkler@intel.com \
--cc=alan@linux.intel.com \
--cc=devel@linuxdriverproject.org \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=sameo@linux.intel.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
all inboxes | Powered by JetHome®