From: Michael Schmitz <schmitzmic@gmail.com>
To: linux-m68k@vger.kernel.org
Cc: geert@linux-m68k.org, Michael Schmitz <schmitz@debian.org>
Subject: [PATCH] m68k/atari - ide: do not register interrupt if host->get_lock is set
Date: Tue, 28 Jan 2014 21:07:46 +1300 [thread overview]
Message-ID: <1390896466-16446-2-git-send-email-schmitz@debian.org> (raw)
In-Reply-To: <1390896466-16446-1-git-send-email-schmitz@debian.org>
On m68k, host->get_lock may be used to both lock and register the
interrupt that the IDE host shares with other device drivers. Registering
the IDE interrupt handler in ide-probe.c results in duplicating the
interrupt registered, and may result in IDE accepting interrupts even
when another driver has locked the interrupt hardware.
Signed-off-by: Michael Schmitz <schmitz@debian.org>
---
drivers/ide/ide-probe.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/ide/ide-probe.c b/drivers/ide/ide-probe.c
index 2a744a9..ae691da 100644
--- a/drivers/ide/ide-probe.c
+++ b/drivers/ide/ide-probe.c
@@ -853,8 +853,9 @@ static int init_irq (ide_hwif_t *hwif)
if (irq_handler == NULL)
irq_handler = ide_intr;
- if (request_irq(hwif->irq, irq_handler, sa, hwif->name, hwif))
- goto out_up;
+ if (!host->get_lock)
+ if (request_irq(hwif->irq, irq_handler, sa, hwif->name, hwif))
+ goto out_up;
#if !defined(__mc68000__)
printk(KERN_INFO "%s at 0x%03lx-0x%03lx,0x%03lx on irq %d", hwif->name,
--
1.7.0.4
next prev parent reply other threads:[~2014-01-28 8:07 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-01-28 8:07 [PATCH 0/1] m68k/atari - ide: do not register interrupt if host->get_lock is set Michael Schmitz
2014-01-28 8:07 ` Michael Schmitz [this message]
2014-01-30 15:03 ` [PATCH] " Geert Uytterhoeven
2014-01-30 19:41 ` Michael Schmitz
-- strict thread matches above, loose matches on Subject: below --
2014-02-01 0:48 [PATCH] Do not register the IDE interrupt handler " Michael Schmitz
2014-02-01 0:48 ` [PATCH] m68k/atari - ide: do not register interrupt " Michael Schmitz
2014-03-04 20:59 ` David Miller
2014-03-06 6:47 ` Michael Schmitz
2014-03-06 17:50 ` David Miller
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=1390896466-16446-2-git-send-email-schmitz@debian.org \
--to=schmitzmic@gmail.com \
--cc=geert@linux-m68k.org \
--cc=linux-m68k@vger.kernel.org \
--cc=schmitz@debian.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