* dummy irq trace 'Flags mismatch'
@ 2013-04-29 21:16 Dave Jones
2013-04-30 4:59 ` Jiri Kosina
0 siblings, 1 reply; 7+ messages in thread
From: Dave Jones @ 2013-04-29 21:16 UTC (permalink / raw)
To: jkosina; +Cc: Linux Kernel
When set to built-in, the dummy irq driver causes this trace when I boot..
[ 3.996055] genirq: Flags mismatch irq 0. 00000080 (dummy_irq) vs. 00015a20 (timer)
[ 3.997055] Pid: 1, comm: swapper/0 Not tainted 3.9.0+ #29
[ 3.997768] Call Trace:
[ 3.998127] [<ffffffff810f8635>] __setup_irq+0x515/0x550
[ 3.998827] [<ffffffff81f00e8c>] ? loop_init+0x150/0x150
[ 3.999530] [<ffffffff8146adf0>] ? transfer_xor+0x160/0x160
[ 4.000259] [<ffffffff810f8809>] request_threaded_irq+0xf9/0x1a0
[ 4.001041] [<ffffffff81f00e8c>] ? loop_init+0x150/0x150
[ 4.001740] [<ffffffff81f00eb8>] dummy_irq_init+0x2c/0x60
[ 4.002450] [<ffffffff810002e2>] do_one_initcall+0x122/0x170
[ 4.003191] [<ffffffff81ecef5c>] kernel_init_freeable+0x15b/0x1db
[ 4.003978] [<ffffffff81ece7da>] ? do_early_param+0x88/0x88
[ 4.004710] [<ffffffff816a87e0>] ? rest_init+0x140/0x140
[ 4.005413] [<ffffffff816a87ee>] kernel_init+0xe/0x180
[ 4.006094] [<ffffffff816ce91c>] ret_from_fork+0x7c/0xb0
[ 4.006789] [<ffffffff816a87e0>] ? rest_init+0x140/0x140
[ 4.007561] dummy-irq: cannot register IRQ 0
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: dummy irq trace 'Flags mismatch'
2013-04-29 21:16 dummy irq trace 'Flags mismatch' Dave Jones
@ 2013-04-30 4:59 ` Jiri Kosina
2013-04-30 13:28 ` Jonathan Corbet
0 siblings, 1 reply; 7+ messages in thread
From: Jiri Kosina @ 2013-04-30 4:59 UTC (permalink / raw)
To: Dave Jones; +Cc: Linux Kernel
On Mon, 29 Apr 2013, Dave Jones wrote:
> When set to built-in, the dummy irq driver causes this trace when I boot..
>
> [ 3.996055] genirq: Flags mismatch irq 0. 00000080 (dummy_irq) vs. 00015a20 (timer)
> [ 3.997055] Pid: 1, comm: swapper/0 Not tainted 3.9.0+ #29
> [ 3.997768] Call Trace:
> [ 3.998127] [<ffffffff810f8635>] __setup_irq+0x515/0x550
> [ 3.998827] [<ffffffff81f00e8c>] ? loop_init+0x150/0x150
> [ 3.999530] [<ffffffff8146adf0>] ? transfer_xor+0x160/0x160
> [ 4.000259] [<ffffffff810f8809>] request_threaded_irq+0xf9/0x1a0
> [ 4.001041] [<ffffffff81f00e8c>] ? loop_init+0x150/0x150
> [ 4.001740] [<ffffffff81f00eb8>] dummy_irq_init+0x2c/0x60
> [ 4.002450] [<ffffffff810002e2>] do_one_initcall+0x122/0x170
> [ 4.003191] [<ffffffff81ecef5c>] kernel_init_freeable+0x15b/0x1db
> [ 4.003978] [<ffffffff81ece7da>] ? do_early_param+0x88/0x88
> [ 4.004710] [<ffffffff816a87e0>] ? rest_init+0x140/0x140
> [ 4.005413] [<ffffffff816a87ee>] kernel_init+0xe/0x180
> [ 4.006094] [<ffffffff816ce91c>] ret_from_fork+0x7c/0xb0
> [ 4.006789] [<ffffffff816a87e0>] ? rest_init+0x140/0x140
> [ 4.007561] dummy-irq: cannot register IRQ 0
Thanks for the report, Dave. That's actually kind of expected -- when one
of the handlers on the IRQ line that is being debugged doesn't share IRQs,
this is exactly what you want to get by the dummy-irq debugging facility.
In this case you haven't specified any IRQ# to the dummy-irq driver via
kernel commandline, i.e. IRQ# is 0, and timer is not sharing IRQs,
therefore dummy-irq debugging facility did its job, and you know that the
IRQ can't be shared.
Not really sure whether this is something to fix. We could make dummy-irq
a module-only thing, but that might be counter-productive in cases you
really want to debug very early problems.
Or have it depend on CONFIG_EXPERT would probably make most sense ... ?
Thanks,
--
Jiri Kosina
SUSE Labs
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: dummy irq trace 'Flags mismatch'
2013-04-30 4:59 ` Jiri Kosina
@ 2013-04-30 13:28 ` Jonathan Corbet
2013-04-30 20:42 ` [PATCH] dummy-irq: require the user to specify an IRQ number Jiri Kosina
0 siblings, 1 reply; 7+ messages in thread
From: Jonathan Corbet @ 2013-04-30 13:28 UTC (permalink / raw)
To: Jiri Kosina; +Cc: Dave Jones, Linux Kernel
On Tue, 30 Apr 2013 06:59:22 +0200 (CEST)
Jiri Kosina <jkosina@suse.cz> wrote:
> Or have it depend on CONFIG_EXPERT would probably make most sense ... ?
We could also just have it tell you when you screwed up? Something like
the following (compile tested only)?
jon
---
dummy-irq: require the user to specify an IRQ number
Reported-by: Dave Jones <davej@redhat.com>
Signed-off-by: Jonathan Corbet <corbet@lwn.net>
diff --git a/drivers/misc/dummy-irq.c b/drivers/misc/dummy-irq.c
index 7014167..c37eeed 100644
--- a/drivers/misc/dummy-irq.c
+++ b/drivers/misc/dummy-irq.c
@@ -19,7 +19,7 @@
#include <linux/irq.h>
#include <linux/interrupt.h>
-static int irq;
+static int irq = -1;
static irqreturn_t dummy_interrupt(int irq, void *dev_id)
{
@@ -36,6 +36,10 @@ static irqreturn_t dummy_interrupt(int irq, void *dev_id)
static int __init dummy_irq_init(void)
{
+ if (irq < 0) {
+ printk(KERN_ERR "dummy-irq: no IRQ given. Use irq=N\n");
+ return -EIO;
+ }
if (request_irq(irq, &dummy_interrupt, IRQF_SHARED, "dummy_irq", &irq)) {
printk(KERN_ERR "dummy-irq: cannot register IRQ %d\n", irq);
return -EIO;
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH] dummy-irq: require the user to specify an IRQ number
2013-04-30 13:28 ` Jonathan Corbet
@ 2013-04-30 20:42 ` Jiri Kosina
2013-04-30 20:50 ` Greg Kroah-Hartman
0 siblings, 1 reply; 7+ messages in thread
From: Jiri Kosina @ 2013-04-30 20:42 UTC (permalink / raw)
To: Jonathan Corbet, Greg Kroah-Hartman; +Cc: Dave Jones, Linux Kernel
From: Jonathan Corbet <corbet@lwn.net>
Subject: [PATCH] dummy-irq: require the user to specify an IRQ number
Make sure that we let the user know that without specifying IRQ#,
dummy-irq driver is useless.
Reported-by: Dave Jones <davej@redhat.com>
Signed-off-by: Jonathan Corbet <corbet@lwn.net>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
diff --git a/drivers/misc/dummy-irq.c b/drivers/misc/dummy-irq.c
index 7014167..c37eeed 100644
--- a/drivers/misc/dummy-irq.c
+++ b/drivers/misc/dummy-irq.c
@@ -19,7 +19,7 @@
#include <linux/irq.h>
#include <linux/interrupt.h>
-static int irq;
+static int irq = -1;
static irqreturn_t dummy_interrupt(int irq, void *dev_id)
{
@@ -36,6 +36,10 @@ static irqreturn_t dummy_interrupt(int irq, void *dev_id)
static int __init dummy_irq_init(void)
{
+ if (irq < 0) {
+ printk(KERN_ERR "dummy-irq: no IRQ given. Use irq=N\n");
+ return -EIO;
+ }
if (request_irq(irq, &dummy_interrupt, IRQF_SHARED, "dummy_irq", &irq)) {
printk(KERN_ERR "dummy-irq: cannot register IRQ %d\n", irq);
return -EIO;
--
Jiri Kosina
SUSE Labs
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH] dummy-irq: require the user to specify an IRQ number
2013-04-30 20:42 ` [PATCH] dummy-irq: require the user to specify an IRQ number Jiri Kosina
@ 2013-04-30 20:50 ` Greg Kroah-Hartman
2013-04-30 21:12 ` Jiri Kosina
0 siblings, 1 reply; 7+ messages in thread
From: Greg Kroah-Hartman @ 2013-04-30 20:50 UTC (permalink / raw)
To: Jiri Kosina; +Cc: Jonathan Corbet, Dave Jones, Linux Kernel
On Tue, Apr 30, 2013 at 10:42:33PM +0200, Jiri Kosina wrote:
> From: Jonathan Corbet <corbet@lwn.net>
> Subject: [PATCH] dummy-irq: require the user to specify an IRQ number
>
> Make sure that we let the user know that without specifying IRQ#,
> dummy-irq driver is useless.
>
> Reported-by: Dave Jones <davej@redhat.com>
> Signed-off-by: Jonathan Corbet <corbet@lwn.net>
> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Nice, I'll queue this up after 3.10-rc1 is out, thanks.
greg k-h
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] dummy-irq: require the user to specify an IRQ number
2013-04-30 20:50 ` Greg Kroah-Hartman
@ 2013-04-30 21:12 ` Jiri Kosina
2013-04-30 23:53 ` Greg Kroah-Hartman
0 siblings, 1 reply; 7+ messages in thread
From: Jiri Kosina @ 2013-04-30 21:12 UTC (permalink / raw)
To: Greg Kroah-Hartman; +Cc: Jonathan Corbet, Dave Jones, Linux Kernel
On Tue, 30 Apr 2013, Greg Kroah-Hartman wrote:
> > From: Jonathan Corbet <corbet@lwn.net>
> > Subject: [PATCH] dummy-irq: require the user to specify an IRQ number
> >
> > Make sure that we let the user know that without specifying IRQ#,
> > dummy-irq driver is useless.
> >
> > Reported-by: Dave Jones <davej@redhat.com>
> > Signed-off-by: Jonathan Corbet <corbet@lwn.net>
> > Signed-off-by: Jiri Kosina <jkosina@suse.cz>
>
> Nice, I'll queue this up after 3.10-rc1 is out, thanks.
Thanks Greg.
Do you want me to resend this after rc1, or is it somewhere in your
post-rc1 queue already?
--
Jiri Kosina
SUSE Labs
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] dummy-irq: require the user to specify an IRQ number
2013-04-30 21:12 ` Jiri Kosina
@ 2013-04-30 23:53 ` Greg Kroah-Hartman
0 siblings, 0 replies; 7+ messages in thread
From: Greg Kroah-Hartman @ 2013-04-30 23:53 UTC (permalink / raw)
To: Jiri Kosina; +Cc: Jonathan Corbet, Dave Jones, Linux Kernel
On Tue, Apr 30, 2013 at 11:12:04PM +0200, Jiri Kosina wrote:
> On Tue, 30 Apr 2013, Greg Kroah-Hartman wrote:
>
> > > From: Jonathan Corbet <corbet@lwn.net>
> > > Subject: [PATCH] dummy-irq: require the user to specify an IRQ number
> > >
> > > Make sure that we let the user know that without specifying IRQ#,
> > > dummy-irq driver is useless.
> > >
> > > Reported-by: Dave Jones <davej@redhat.com>
> > > Signed-off-by: Jonathan Corbet <corbet@lwn.net>
> > > Signed-off-by: Jiri Kosina <jkosina@suse.cz>
> >
> > Nice, I'll queue this up after 3.10-rc1 is out, thanks.
>
> Thanks Greg.
>
> Do you want me to resend this after rc1, or is it somewhere in your
> post-rc1 queue already?
It's in my queue already, no need for you to resend this.
thanks,
greg k-h
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2013-04-30 23:53 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-04-29 21:16 dummy irq trace 'Flags mismatch' Dave Jones
2013-04-30 4:59 ` Jiri Kosina
2013-04-30 13:28 ` Jonathan Corbet
2013-04-30 20:42 ` [PATCH] dummy-irq: require the user to specify an IRQ number Jiri Kosina
2013-04-30 20:50 ` Greg Kroah-Hartman
2013-04-30 21:12 ` Jiri Kosina
2013-04-30 23:53 ` Greg Kroah-Hartman
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox