[LAU] anyone running 4.13.15-300.rt5.1.fc27.ccrma.x86_64+rt + snd_usb yet?

Chris Caudle chris at chriscaudle.org
Sat Dec 9 19:43:51 UTC 2017


On Mon, December 4, 2017 2:44 pm, Chris Caudle wrote:
> OK, I guess that is good in general for PlanetCCRMA, but I still don't
> have any good place to start with no error messages.  I don't know where
> to even start debugging a driver problem.

Just to follow up in case this helps someone else some day:
I tried the same interface on a different machine running the same kernel,
no problems, found just as Fernando did that the kernel in general has no
problem with USB interfaces.

Back to the original machine, works fine on standard kernel (which in the
case of Fedora does not enable CONFIG_PREEMPT, only
CONFIG_PREEMPT_VOLUNTARY, so I think that may mean no threadirq support). 
Still unusable on RT.

I changed the physical USB port in use, and now the interface works.  I'm
not completely sure yet why that is the case.  These are some clues I
have:

message from syslogd at chubb at Dec  9 13:00:02 ...
 kernel:Disabling IRQ #20

So something is causing a problem from IRQ 20 and the kernel had to
disable that IRQ.

These are the RT priorities for IRQ:
$ rtirq status
  PID CLS RTPRIO  NI PRI %CPU STAT COMMAND
  215 FF      95   - 135  0.0 S    irq/20-uhci_hcd
  217 FF      94   - 134  0.0 S    irq/22-uhci_hcd
  216 FF      93   - 133  0.0 S    irq/23-uhci_hcd
  219 FF      93   - 133  0.0 S    irq/22-uhci_hcd
 1257 FF      93   - 133  0.0 S    irq/55-enp3s4f1
  218 FF      92   - 132  0.0 S    irq/23-uhci_hcd
  222 FF      91   - 131  0.0 S    irq/1-i8042
  221 FF      90   - 130  0.0 S    irq/12-i8042

But wait, there is a non-RT thread later on the same IRQ:
214 FF      50   -  90  0.0 S    irq/20-ehci_hcd

So this connection did not work:
$ lsusb
Bus 006 Device 002: ID 03f0:1027 Hewlett-Packard Virtual keyboard and mouse
Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 005 Device 003: ID 1210:0009 DigiTech
Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

but this connection did:
$ lsusb
Bus 006 Device 002: ID 03f0:1027 Hewlett-Packard Virtual keyboard and mouse
Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 004 Device 002: ID 1210:0009 DigiTech
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

Tree view of non-working:
$ lsusb -t
/:  Bus 06.Port 1: Dev 1, Class=root_hub, Driver=uhci_hcd/2p, 12M
    |__ Port 1: Dev 2, If 0, Class=Human Interface Device, Driver=usbhid, 12M
    |__ Port 1: Dev 2, If 1, Class=Human Interface Device, Driver=usbhid, 12M
/:  Bus 05.Port 1: Dev 1, Class=root_hub, Driver=uhci_hcd/2p, 12M
    |__ Port 2: Dev 4, If 0, Class=Audio, Driver=snd-usb-audio, 12M
    |__ Port 2: Dev 4, If 1, Class=Audio, Driver=snd-usb-audio, 12M
    |__ Port 2: Dev 4, If 2, Class=Audio, Driver=snd-usb-audio, 12M
    |__ Port 2: Dev 4, If 4, Class=Application Specific Interface,
Driver=, 12M
    |__ Port 2: Dev 4, If 6, Class=Audio, Driver=snd-usb-audio, 12M
    |__ Port 2: Dev 4, If 7, Class=Audio, Driver=snd-usb-audio, 12M
/:  Bus 04.Port 1: Dev 1, Class=root_hub, Driver=uhci_hcd/2p, 12M
/:  Bus 03.Port 1: Dev 1, Class=root_hub, Driver=uhci_hcd/2p, 12M
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=uhci_hcd/2p, 12M
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=ehci-pci/8p, 480M


Tree view of working:
$ lsusb -t
/:  Bus 06.Port 1: Dev 1, Class=root_hub, Driver=uhci_hcd/2p, 12M
    |__ Port 1: Dev 2, If 0, Class=Human Interface Device, Driver=usbhid, 12M
    |__ Port 1: Dev 2, If 1, Class=Human Interface Device, Driver=usbhid, 12M
/:  Bus 05.Port 1: Dev 1, Class=root_hub, Driver=uhci_hcd/2p, 12M
/:  Bus 04.Port 1: Dev 1, Class=root_hub, Driver=uhci_hcd/2p, 12M
    |__ Port 2: Dev 2, If 0, Class=Audio, Driver=snd-usb-audio, 12M
    |__ Port 2: Dev 2, If 1, Class=Audio, Driver=snd-usb-audio, 12M
    |__ Port 2: Dev 2, If 2, Class=Audio, Driver=snd-usb-audio, 12M
    |__ Port 2: Dev 2, If 4, Class=Application Specific Interface,
Driver=, 12M
    |__ Port 2: Dev 2, If 6, Class=Audio, Driver=snd-usb-audio, 12M
    |__ Port 2: Dev 2, If 7, Class=Audio, Driver=snd-usb-audio, 12M
/:  Bus 03.Port 1: Dev 1, Class=root_hub, Driver=uhci_hcd/2p, 12M
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=uhci_hcd/2p, 12M
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=ehci-pci/8p, 480M

I changed rtirq setup so that the interrupt 20 which is shared between the
ehci and uhci controllers is prioritized, just in case having the ehci at
lower priority was causing problems, but even with this still no usable
sound:
$ rtirq status

  PID CLS RTPRIO  NI PRI %CPU STAT COMMAND
  214 FF      95   - 135  0.0 S    irq/20-ehci_hcd
  215 FF      95   - 135  0.0 S    irq/20-uhci_hcd
  217 FF      92   - 132  0.0 S    irq/22-uhci_hcd
  216 FF      91   - 131  0.0 S    irq/23-uhci_hcd
  219 FF      91   - 131  0.0 S    irq/22-uhci_hcd
 1257 FF      91   - 131  0.0 S    irq/55-enp3s4f1
  218 FF      90   - 130  0.0 S    irq/23-uhci_hcd
  222 FF      89   - 129  0.0 S    irq/1-i8042
  221 FF      88   - 128  0.2 S    irq/12-i8042

tl;dr  I can correct the problem by moving my USB interface to a
physically less convenient connector, but I do not really understand what
is happening in the drivers or kernel IRQ prioritization which makes that
so, and I do not understand why only the RT kernel has this problem and
not the PREEMPT_VOLUNTARY standard fedora kernel.

For now I have spent enough time today working on this, I will just move
the cable to the front connector on my machine, and hope I do not
accidentally bump into the cable and break the connector.  Maybe later I
can find some information to explain the behavior.

-- 
Chris Caudle




More information about the Linux-audio-user mailing list