From: Sergei Shtylyov <sshtylyov@ru.mvista.com>
To: davem@davemloft.net, linux-ide@vger.kernel.org
Cc: rmk@arm.linux.org.uk
Subject: [PATCH 2/2] pdc202xx_old: ignore "FIFO empty" bit in test_irq() method
Date: Wed, 14 Apr 2010 19:52:59 +0400 [thread overview]
Message-ID: <201004141952.59445.sshtylyov@ru.mvista.com> (raw)
The driver takes into account not only the interrupt status bit but also "FIFO
empty" bit in its test_irq() method. This actually is a superfluous check since
for the DMA commands calling the dma_test_irq() method further in the interrupt
handler makes sure FIFO is emptied.
Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>
---
The patch is atop of ide-2.6.git tree...
Russell, would you mind giving this patch a test?
drivers/ide/pdc202xx_old.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
Index: ide-2.6/drivers/ide/pdc202xx_old.c
===================================================================
--- ide-2.6.orig/drivers/ide/pdc202xx_old.c
+++ ide-2.6/drivers/ide/pdc202xx_old.c
@@ -93,13 +93,13 @@ static int pdc202xx_test_irq(ide_hwif_t
* bit 7: error, bit 6: interrupting,
* bit 5: FIFO full, bit 4: FIFO empty
*/
- return ((sc1d & 0x50) == 0x50) ? 1 : 0;
+ return (sc1d & 0x40) ? 1 : 0;
} else {
/*
* bit 3: error, bit 2: interrupting,
* bit 1: FIFO full, bit 0: FIFO empty
*/
- return ((sc1d & 0x05) == 0x05) ? 1 : 0;
+ return (sc1d & 0x04) ? 1 : 0;
}
}
next reply other threads:[~2010-04-14 15:53 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-04-14 15:52 Sergei Shtylyov [this message]
2010-04-23 2:12 ` [PATCH 2/2] pdc202xx_old: ignore "FIFO empty" bit in test_irq() method David Miller
2010-04-27 16:41 ` David Miller
2010-04-27 19:14 ` Mikael Pettersson
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=201004141952.59445.sshtylyov@ru.mvista.com \
--to=sshtylyov@ru.mvista.com \
--cc=davem@davemloft.net \
--cc=linux-ide@vger.kernel.org \
--cc=rmk@arm.linux.org.uk \
/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