LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 08-02-2023, 03:44 AM   #1
lambo69
Member
 
Registered: Sep 2012
Distribution: Slackware, Manjaro, Slackarm, Raspbian, Debian
Posts: 68

Rep: Reputation: Disabled
Reserve IRQ/Interrupt exclusively for one device


Hi all,
Code:
# cat /proc/interrupts |grep hdsp
shows
Code:
 18:          0     257590          0          0   IO-APIC  18-fasteoi   i801_smbus, snd_hdsp
how can i manage it, to have snd_hdsp exlusively using one interrupt? All i found was distributing interrupts on processors (irqthreads, irqbalance, affinity), but nothing about how to have an irq reserved for only one device.

Thanks in advance
 
Old 08-03-2023, 01:57 PM   #2
0XBF
Member
 
Registered: Nov 2018
Distribution: Slackware
Posts: 796

Rep: Reputation: 913Reputation: 913Reputation: 913Reputation: 913Reputation: 913Reputation: 913Reputation: 913Reputation: 913
Quote:
Originally Posted by lambo69 View Post
Hi all,
Code:
# cat /proc/interrupts |grep hdsp
shows
Code:
 18:          0     257590          0          0   IO-APIC  18-fasteoi   i801_smbus, snd_hdsp
how can i manage it, to have snd_hdsp exlusively using one interrupt? All i found was distributing interrupts on processors (irqthreads, irqbalance, affinity), but nothing about how to have an irq reserved for only one device.

Thanks in advance
From what I've read, the interrupt vectors that the IO-APIC interrupt controller uses are set at startup via data stored in ACPI tables. Not something that is easily adjustable, or something that I have any experience tinkering with.

The way I would normally handle this is to boot the kernel with the 'threadirqs' option set. Then you can set the realtime priority of the snd_hdsp irq thread higher so that interrupt requests from the sound card are prioritized over the SMBus interrupt.

Here is a resource I have bookmarked about irq priorities. It is focused around a FireWire card, but the concepts can be applied to PCI and USB audio irq priorities as well: http://subversion.ffado.org/wiki/IrqPriorities

Note that this is geared towards setting IRQs higher to achieve lower latency audio recording, which I assume is what you are trying to do? The rtirq program mentioned in that writeup is helpful and I use it for setting irq priorities. A slackbuild for it is also on slackbuilds.org: https://slackbuilds.org/repository/15.0/system/rtirq/


On a side note: If the i801_smbus driver is causing problems like interrupt storms then it can be disabled at boot with the command line option:
Code:
i2c-i801.disable_features=0x10
I've read about a bug that did this in pre 5.16 kernels when loading the jc42 kernel module, as mentioned here: https://bugzilla.kernel.org/show_bug.cgi?id=177311

Personally I have never seen the problem or have needed to disable the SMBus interrupt. If its not causing problems then just leave it. Adjusting the realtime priority should allow you to prioritize the sound card over the SMBus on the shared interrupt either way.

HTH.
 
Old 08-05-2023, 12:30 AM   #3
lambo69
Member
 
Registered: Sep 2012
Distribution: Slackware, Manjaro, Slackarm, Raspbian, Debian
Posts: 68

Original Poster
Rep: Reputation: Disabled
Thank you for the answer, especially for link to ffado. That was the information about realtime scheduling and irqs i was looking for.
I wasn't aware, that this driver belongs to the i2c world, so i simply built a new kernel without it and now everything works fine again. The ffado page will be a guide for further optimization (which is now not really neccesary).
You were right, it's about audio.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] VirtualBox: USB device "is being exclusively used by the host computer" catkin Linux - Virtualization and Cloud 21 10-28-2016 05:40 PM
Doubt in interrupt number, how to decide device interrupted on sharing interrupt pin? ayyasprings Linux - Embedded & Single-board computer 1 06-22-2015 08:45 AM
UNIQ IRQ and Shared IRQ...I want to make Shared IRQ routin chxooi Linux - Hardware 1 06-12-2010 07:30 AM
How do I 'reserve' my sound device? So more then one piece of software can use sound RHLinuxGUY Linux - Software 4 12-06-2006 10:42 PM
How do I reserve an IRQ to ISA? peso Linux - Hardware 9 02-07-2004 04:20 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 06:52 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration