From: Mikulas Patocka <mpatocka@redhat.com>
To: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
Cc: torvalds@linux-foundation.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] Limit irq nesting
Date: Thu, 17 Jul 2008 07:59:35 -0400 (EDT) [thread overview]
Message-ID: <Pine.LNX.4.64.0807170750410.31185@devserv.devel.redhat.com> (raw)
In-Reply-To: <20080717105532.157E.KOSAKI.MOTOHIRO@jp.fujitsu.com>
On Thu, 17 Jul 2008, KOSAKI Motohiro wrote:
> Hi Mikulas,
>
> > ---
> > include/linux/interrupt.h | 7 ++++++-
> > 1 file changed, 6 insertions(+), 1 deletion(-)
> >
> > Index: linux-2.6.26-rc8/include/linux/interrupt.h
> > ===================================================================
> > --- linux-2.6.26-rc8.orig/include/linux/interrupt.h 2008-06-25 03:58:20.000000000 +0200
> > +++ linux-2.6.26-rc8/include/linux/interrupt.h 2008-07-01 17:42:44.000000000 +0200
> > @@ -16,6 +16,11 @@
> > #include <asm/system.h>
> >
> > /*
> > + * Max number of interrupt handlers on a stack. To prevent stack overflow.
> > + */
> > +#define MAX_NESTED_INTERRUPTS 2
> > +
> > +/*
> > * These correspond to the IORESOURCE_IRQ_* defines in
> > * linux/ioport.h to select the interrupt line behaviour. When
> > * requesting an interrupt without specifying a IRQF_TRIGGER, the
>
> I have no objection to your approach.
> but I don't know MAX_NESTED_INTERRUPTS is properly or not.
>
> Could you explain why MAX_NESTED_INTERRUPTS is two?
> Is it architecture independent properly number?
I assume that there is at most one active bad-behaving device with long
interrupt processing time. For example IDE disk in PIO mode.
If someone starts whining that he is simultaneously using two disks in PIO
mode and is losing characters on serial line, we can make an architecture
override for this (after we check that the architecture has enough stack
space to hold more interrupts). But PIO mode is dead anyway, so there's no
need to preemptively care about it.
Mikulas
next prev parent reply other threads:[~2008-07-17 11:59 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-07-17 1:42 [PATCH] Limit irq nesting Mikulas Patocka
2008-07-17 1:57 ` KOSAKI Motohiro
2008-07-17 11:59 ` Mikulas Patocka [this message]
-- strict thread matches above, loose matches on Subject: below --
2008-06-24 5:54 [10 PATCHES] inline functions to avoid stack overflow Mikulas Patocka
2008-06-24 6:06 ` [PATCH] limit irq nesting Mikulas Patocka
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=Pine.LNX.4.64.0807170750410.31185@devserv.devel.redhat.com \
--to=mpatocka@redhat.com \
--cc=kosaki.motohiro@jp.fujitsu.com \
--cc=linux-kernel@vger.kernel.org \
--cc=torvalds@linux-foundation.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