kappa8086
Posts: 7
Joined: Mon Mar 21, 2016 12:03 am

Kernel panic (?) caused by USB MIDI

Mon Mar 21, 2016 12:59 am

Steps to reproduce:
1. connect a usb midi device onto any usb port and power it on (should connect 1 more if you have, then may skip step 2)
2. start fluidsynth, whatever params, make it run
3. aconnect to connect the two MIDI ports above created
4. unplug / power down the device

then USB subsystem error like

......
usb 1-1.3: urb status -32
hub 1-1:1.0: hub_port_status failed (err = -110)

and then everything freezes, keyboard, networking, and background music (mpd) after a few seconds, leaving the green LED on board lid constantly.

I think this is related to linux-rsapberrypi USB driver or snd_seq_midi module, since another board (cubieboard2), running archlinux as well, behaves normally in the same situation. (I have written a udev rule for cleanup automatically.)

kappa8086
Posts: 7
Joined: Mon Mar 21, 2016 12:03 am

Re: Kernel panic (?) caused by USB MIDI

Mon Mar 21, 2016 8:32 am

Im using Rpi2
forgot to say that.

User avatar
DougieLawson
Posts: 38883
Joined: Sun Jun 16, 2013 11:19 pm
Location: A small cave in deepest darkest Basingstoke, UK
Contact: Website Twitter

Re: Kernel panic (?) caused by USB MIDI

Mon Mar 21, 2016 6:22 pm

Have you added

Code: Select all

max_usb_current=1
to your /boot/config.txt?
Note: Any requirement to use a crystal ball or mind reading will result in me ignoring your question.

Criticising any questions is banned on this forum.

Any DMs sent on Twitter will be answered next month.
All non-medical doctors are on my foes list.

kappa8086
Posts: 7
Joined: Mon Mar 21, 2016 12:03 am

Re: Kernel panic (?) caused by USB MIDI

Tue Mar 22, 2016 6:41 am

DougieLawson wrote:Have you added

Code: Select all

max_usb_current=1
to your /boot/config.txt?
Not yet, I will try later, but I doubt if it can solve the problem, because everything is OK if I don't try to disconnect it, or "acconect -d" first

kappa8086
Posts: 7
Joined: Mon Mar 21, 2016 12:03 am

Re: Kernel panic (?) caused by USB MIDI

Wed Mar 23, 2016 3:26 pm

No luck, still crashes. :(
a kernel BUG rather than a hardware issue I think,
a midi keyboard should not be that power-cost indeed

User avatar
DougieLawson
Posts: 38883
Joined: Sun Jun 16, 2013 11:19 pm
Location: A small cave in deepest darkest Basingstoke, UK
Contact: Website Twitter

Re: Kernel panic (?) caused by USB MIDI

Thu Mar 24, 2016 7:06 am

It looks like a hardware issue. What happens if you plug your USB device into a Windows laptop or Mac?
Note: Any requirement to use a crystal ball or mind reading will result in me ignoring your question.

Criticising any questions is banned on this forum.

Any DMs sent on Twitter will be answered next month.
All non-medical doctors are on my foes list.

gregeric
Posts: 1509
Joined: Mon Nov 28, 2011 10:08 am

Re: Kernel panic (?) caused by USB MIDI

Thu Mar 24, 2016 7:46 am

Think it's RPi related as the OP reports all fine on his Cubieboard2, also running Arch.

Is your kernel up to date? There were patches applied to the Pi's dwc_otg USB host controller driver about a month to make it robust against the quirks of the upstream DM9601 driver, maybe those changes will help with your USB Midi - worth a shot.

kappa8086
Posts: 7
Joined: Mon Mar 21, 2016 12:03 am

Re: Kernel panic (?) caused by USB MIDI

Thu Mar 24, 2016 9:58 am

DougieLawson wrote:It looks like a hardware issue. What happens if you plug your USB device into a Windows laptop or Mac?
No issue.

I'd to say it's not a normal way to shut it down before "acconnect -d xx xxx" closes the software-layer connection, but I want to use it headlessly, so the disconnect signal is used to trigger udev script, however the system has always been crashed before the script runs.

I have a MIDI keyboard and a USB midi converter, I also tried the latter one instead, as long as aconnect shows the connection, I can't unplug it without a crash.

kappa8086
Posts: 7
Joined: Mon Mar 21, 2016 12:03 am

Re: Kernel panic (?) caused by USB MIDI

Thu Mar 24, 2016 9:59 am

gregeric wrote:Think it's RPi related as the OP reports all fine on his Cubieboard2, also running Arch.

Is your kernel up to date? There were patches applied to the Pi's dwc_otg USB host controller driver about a month to make it robust against the quirks of the upstream DM9601 driver, maybe those changes will help with your USB Midi - worth a shot.
Always the newest I think.

kappa8086
Posts: 7
Joined: Mon Mar 21, 2016 12:03 am

Re: Kernel panic (?) caused by USB MIDI

Fri Aug 05, 2016 5:31 am

Still existing, where else should I report this to the kernel developers?

Return to “Arch”