From: Anatolij Gustschin <agust@denx.de>
To: linux-kernel@vger.kernel.org
Cc: "Hans J. Koch" <hjk@hansjkoch.de>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Subject: [PATCH] uio_pdrv_genirq: don't re-setup irq if already configured by OF
Date: Tue, 29 Jan 2013 16:55:59 +0100 [thread overview]
Message-ID: <1359474959-1708-1-git-send-email-agust@denx.de> (raw)
If an OF node doesn't specify an interrupt property, 'uioinfo->irq'
will be assigned to the UIO_IRQ_NONE value meaning no interrupt
support. Trying to re-setup the irq later results in an error again
and probing fails. To prevent this do not try to re-setup the irq
if it was configured to UIO_IRQ_NONE by OF related code.
Signed-off-by: Anatolij Gustschin <agust@denx.de>
---
drivers/uio/uio_pdrv_genirq.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/uio/uio_pdrv_genirq.c b/drivers/uio/uio_pdrv_genirq.c
index c122bca..16f7ae4 100644
--- a/drivers/uio/uio_pdrv_genirq.c
+++ b/drivers/uio/uio_pdrv_genirq.c
@@ -146,7 +146,7 @@ static int uio_pdrv_genirq_probe(struct platform_device *pdev)
priv->flags = 0; /* interrupt is enabled to begin with */
priv->pdev = pdev;
- if (!uioinfo->irq) {
+ if (!pdev->dev.of_node && !uioinfo->irq) {
ret = platform_get_irq(pdev, 0);
if (ret < 0) {
dev_err(&pdev->dev, "failed to get IRQ\n");
--
1.7.5.4
reply other threads:[~2013-01-29 15:56 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=1359474959-1708-1-git-send-email-agust@denx.de \
--to=agust@denx.de \
--cc=gregkh@linuxfoundation.org \
--cc=hjk@hansjkoch.de \
--cc=linux-kernel@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
all inboxes | Powered by JetHome®