From: Mike Frysinger <vapier@gentoo.org>
To: linux-sh@vger.kernel.org
Subject: [PATCH] sh: dma: fix request_irq usage
Date: Sun, 05 Aug 2012 01:54:05 +0000 [thread overview]
Message-ID: <1344131645-10813-1-git-send-email-vapier@gentoo.org> (raw)
When calling request_irq with IRQF_SHARED, the dev cookie must be set
(i.e. non-NULL), otherwise the code rejects it immediately with -EINVAL.
So restore the logic here where we'd pass a pointer to the name as a
dummy unique val.
Otherwise, booting up on my LANDISK system would fail with:
DMAC Address Error0 request_irq fail
This was introduced in commit 7f47c7189b3e8f19a589f77a3ad169d7b691b582.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
---
arch/sh/drivers/dma/dma-sh.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/sh/drivers/dma/dma-sh.c b/arch/sh/drivers/dma/dma-sh.c
index 4c171f1..b225656 100644
--- a/arch/sh/drivers/dma/dma-sh.c
+++ b/arch/sh/drivers/dma/dma-sh.c
@@ -335,7 +335,7 @@ static int dmae_irq_init(void)
for (n = 0; n < NR_DMAE; n++) {
int i = request_irq(get_dma_error_irq(n), dma_err,
- IRQF_SHARED, dmae_name[n], NULL);
+ IRQF_SHARED, dmae_name[n], (void *)dmae_name[n]);
if (unlikely(i < 0)) {
printk(KERN_ERR "%s request_irq fail\n", dmae_name[n]);
return i;
--
1.7.9.7
next reply other threads:[~2012-08-05 1:54 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-05 1:54 Mike Frysinger [this message]
2012-08-27 8:38 ` [PATCH] sh: dma: fix request_irq usage Simon Horman
2012-08-27 8:39 ` Simon Horman
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=1344131645-10813-1-git-send-email-vapier@gentoo.org \
--to=vapier@gentoo.org \
--cc=linux-sh@vger.kernel.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;
as well as URLs for NNTP newsgroup(s).