public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
From: Jeff Garzik <jgarzik@pobox.com>
To: SCSI Mailing List <linux-scsi@vger.kernel.org>,
	James Bottomley <James.Bottomley@steeleye.com>,
	linuxraid@amcc.com
Cc: Mark Lord <liml@rtr.ca>
Subject: [PATCH 1/3] Fix 3ware irq handling: correct IRQ_HANDLED
Date: Wed, 02 Mar 2005 02:20:34 -0500	[thread overview]
Message-ID: <42256942.2050408@pobox.com> (raw)
In-Reply-To: <422568CF.3060307@pobox.com>

[-- Attachment #1: Type: text/plain, Size: 166 bytes --]

Only indicate irq-handled if that is really true

Driver currently returns IRQ_HANDLED for all interrupts.  Fix this.

Signed-off-by: Jeff Garzik <jgarzik@pobox.com>

[-- Attachment #2: patch.1 --]
[-- Type: text/plain, Size: 1294 bytes --]

diff -Nru a/drivers/scsi/3w-9xxx.c b/drivers/scsi/3w-9xxx.c
--- a/drivers/scsi/3w-9xxx.c	2005-03-02 02:14:42 -05:00
+++ b/drivers/scsi/3w-9xxx.c	2005-03-02 02:14:42 -05:00
@@ -1176,14 +1176,14 @@
 	/* See if the interrupt matches this instance */
 	if (tw_dev->tw_pci_dev->irq == (unsigned int)irq) {
 
-		handled = 1;
-
 		/* Read the registers */
 		status_reg_value = readl(TW_STATUS_REG_ADDR(tw_dev));
 
 		/* Check if this is our interrupt, otherwise bail */
 		if (!(status_reg_value & TW_STATUS_VALID_INTERRUPT))
 			goto twa_interrupt_bail;
+
+		handled = 1;
 
 		/* Check controller for errors */
 		if (twa_check_bits(status_reg_value)) {
diff -Nru a/drivers/scsi/3w-xxxx.c b/drivers/scsi/3w-xxxx.c
--- a/drivers/scsi/3w-xxxx.c	2005-03-02 02:14:42 -05:00
+++ b/drivers/scsi/3w-xxxx.c	2005-03-02 02:14:42 -05:00
@@ -2091,14 +2091,14 @@
 	/* See if the interrupt matches this instance */
 	if (tw_dev->tw_pci_dev->irq == (unsigned int)irq) {
 
-		handled = 1;
-
 		/* Read the registers */
 		status_reg_value = inl(TW_STATUS_REG_ADDR(tw_dev));
 
 		/* Check if this is our interrupt, otherwise bail */
 		if (!(status_reg_value & TW_STATUS_VALID_INTERRUPT))
 			goto tw_interrupt_bail;
+
+		handled = 1;
 
 		/* Check controller for errors */
 		if (tw_check_bits(status_reg_value)) {

  reply	other threads:[~2005-03-02  7:20 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20050224015859.55191.qmail@web40910.mail.yahoo.com>
     [not found] ` <421D3D33.9060707@pobox.com>
     [not found]   ` <20050226193255.GA6256@ime.usp.br>
     [not found]     ` <4220D9DE.10904@pobox.com>
     [not found]       ` <42234279.6030004@rtr.ca>
2005-03-02  7:18         ` [PATCH 0/3] Fix 3ware irq handling Jeff Garzik
2005-03-02  7:20           ` Jeff Garzik [this message]
2005-03-02  7:21           ` [PATCH 2/3] Fix 3ware irq handling: remove bogus test Jeff Garzik
2005-03-02  7:22           ` [PATCH 3/3] Fix 3ware irq handling: update irq handler indentation Jeff Garzik
2005-03-02  7:31             ` Jeff Garzik

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=42256942.2050408@pobox.com \
    --to=jgarzik@pobox.com \
    --cc=James.Bottomley@steeleye.com \
    --cc=liml@rtr.ca \
    --cc=linux-scsi@vger.kernel.org \
    --cc=linuxraid@amcc.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