All of lore.kernel.org
 help / color / mirror / Atom feed
From: Arnaldo Carvalho de Melo <acme@ghostprotocols.net>
To: "K.R. Foley" <kr@cybsft.com>
Cc: John Sigler <linux.kernel@free.fr>,
	Steven Rostedt <rostedt@goodmis.org>,
	linux-rt-users@vger.kernel.org
Subject: Re: Priorities of IRQ handlers
Date: Wed, 28 Nov 2007 13:02:01 -0200	[thread overview]
Message-ID: <20071128150201.GE25255@ghostprotocols.net> (raw)
In-Reply-To: <474D7748.8@cybsft.com>

Em Wed, Nov 28, 2007 at 08:12:24AM -0600, K.R. Foley escreveu:
> John Sigler wrote:
> > Hello Steven,
> > 
> > Steven Rostedt wrote:
> > 
> >> John Sigler wrote:
> >>
> >>> I need to change the priorities of several soft and hard IRQ handlers.
> >>>
> >>> Namely,
> >>>
> >>> o reduce the prio of "softirq-timer" handler to 10
> >>>
> >>> o reduce the prio of IRQ14 and IRQ15 handlers to 20
> >>>    (my flash drives do not support DMA BTW...)
> >>>
> >>> o boost the prio of my I/O boards' IRQ handlers to 60
> >>>    (there can be 1 or 2 boards, the driver is a kernel module
> >>>     which is loaded after the system has booted.)
> >>>
> >>> I've written a short program that calls
> >>>    sched_setscheduler(pid, SCHED_FIFO, &param);
> >>> with the appropriate pid, which I look up using ps -ef
> >>
> >> Look for the program "chrt". It does this for you. This program is
> >> available in all major distributions of Linux.
> > 
> > Thanks for the tip.
> > 
> > For the record, I found schedutils on Robert Love's page:
> > 
> > http://rlove.org/
> > http://rlove.org/misc/schedutils-1.5.0.tar.gz
> > 
> > However, I had already solved that part of the problem with a
> > program of my own.
> > 
> > My real problem is: the IRQ handlers for the I/O boards are
> > only instantiated when the kernel module is inserted. How do
> > I /reliably/ determine their pid?
> 
> What about something like:
> chrt -f -p 99 `/sbin/pidof 'IRQ 8'`

If he knows that IRQ 8 is associated with his device, that is ok,
but how to map device -> IRQ in the first place?
 
> > 
> > e.g. on one system, the IRQ handler for my I/O board is IRQ5
> > with pid 745. On another system, it's IRQ20 with pid 808.
> > On a third system they're IRQ20 and IRQ21 with pid 239 and 240.

See?

Perhaps he could use a kernel command line where he would tell that
for the string used in request_irq the kthread priority should be N.

IIRC there was somebody trying to write a patch to support this at some
point in this list...

- Arnaldo

  reply	other threads:[~2007-11-28 15:05 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-11-26 15:31 Priorities of IRQ handlers John Sigler
2007-11-27 16:26 ` Steven Rostedt
2007-11-28 11:05   ` John Sigler
2007-11-28 14:12     ` K.R. Foley
2007-11-28 15:02       ` Arnaldo Carvalho de Melo [this message]
2007-11-28 21:38       ` Sven-Thorsten Dietrich
2007-11-30 11:26     ` Dominique Michel

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=20071128150201.GE25255@ghostprotocols.net \
    --to=acme@ghostprotocols.net \
    --cc=kr@cybsft.com \
    --cc=linux-rt-users@vger.kernel.org \
    --cc=linux.kernel@free.fr \
    --cc=rostedt@goodmis.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.