Re: [LAU] Issue with the priority of the sound cards using rtirq

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Jeremy Jongepier <jeremy@...>
Cc: <linux-audio-user@...>
Date: Thursday, May 3, 2012 - 6:26 am

On 05/02/2012 12:19 AM, Jeremy Jongepier wrote:

That's how we all would like things to work, regretfully that is not how
things actually work.

>> AFAIK it is not possible (or simple) to raise _just_ the soundcard as it

For soundcard drivers there is no convention for naming the irq process
that services its interrupt. The name of the irq process does not match
the name of the kernel module (which would be an obvious choice). The
ascii that is printed by ps is defined in the kernel code for each
driver, and driver authors pick different names that are not consistent.
That means you can't pattern match for the right irq process if the
interrupt number is shared by several devices.

It would be possible to pattern match if, for example, all soundcards
used a "snd_" prefix for the name of the irq process, but that is not
the case (at least until last time I looked at the kernel code for this
very same reason).

>So the graphics card gets a

The rtirq code does the following (simplified):

- rtirq gets the irq number from /proc/asound/cards
- that number is used to search the output of ps looking for matches
with that particular irq number
- there is no way to tell which irq process corresponds to a soundcard,
rtirq does not try AFAICT
- so, all irq processes that match the number get the elevated priority

For example, in my laptop, from /proc/interrupts:

16: 2551 516 113 95 IO-APIC-fasteoi
nouveau, snd_hda_intel, mmc0

rtirq happily gives them 75, 74 and 73:

222 FF 75 - 115 0.0 S irq/16-nouveau
11077 FF 74 - 114 0.0 S irq/16-snd_hda_
11082 FF 73 - 113 0.0 S irq/16-mmc0

Please let me know if there is a way to, given an irq number, know what
is the pid of the irq process that services that irq number for a
particular _soundcard_, I have found no way of doing that so far[*].

Note that in all other cases other than soundcards rtirq looks for the
name, not the number of the irq (for example for usb the names are well
known and unique and hardwired into rtirq).

-- Fernando

[*] other than scanning the kernel source code for the names of all
possible soundcard driver irq processes, making a list and matching
against that - it would work but it would depend on those names not
changing, and of having the list that matches the kernel you are running.
_______________________________________________
Linux-audio-user mailing list
Linux-audio-user@lists.linuxaudio.org
http://lists.linuxaudio.org/listinfo/linux-audio-user

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Re: [LAU] Issue with the priority of the sound cards using r..., Fernando Lopez-Lezcano, (Tue May 1, 6:32 pm)
Re: [LAU] Issue with the priority of the sound cards using r..., Fernando Lopez-Lezcano, (Thu May 3, 6:26 am)
Re: [LAU] Issue with the priority of the sound cards using r..., Fernando Lopez-Lezcano, (Thu May 3, 5:01 pm)
Re: [LAU] Issue with the priority of the sound cards using r..., Fernando Lopez-Lezcano, (Thu May 3, 11:39 pm)
Re: [LAU] new rtirq release, Fernando Lopez-Lezcano, (Fri May 4, 7:08 pm)
[LAU] rtirq question, Ivica Ico Bukvic, (Sat May 5, 2:42 am)
Re: [LAU] rtirq question, Ivica Ico Bukvic, (Sat May 5, 3:02 am)
Re: [LAU] new rtirq release, Rui Nuno Capela, (Fri May 4, 9:56 pm)
Re: [LAU] new rtirq release, Fernando Lopez-Lezcano, (Fri May 4, 11:14 pm)
Re: [LAU] new rtirq release, Rui Nuno Capela, (Fri May 4, 11:42 pm)
Re: [LAU] new rtirq release, Brendan Jones, (Fri May 4, 3:36 pm)
Re: [LAU] new rtirq release, Ralf Mardorf, (Fri May 4, 4:26 pm)
Re: [LAU] Issue with the priority of the sound cards using r..., Fernando Lopez-Lezcano, (Thu May 3, 8:23 pm)