Increase CONFIG_SND_MAX_CARDS?

Hi,
I’m able to load 2 4 port hubs (MIDIBOX and MIDIHub) in addition to an Arturia Beatstep via unpowered USB hub and everything shows up so I do not think there is an 8 port USB device limit.
I now have 9 USB ports plus 1 MIDI DIN Pair, plus 1 network attached port to my PC.

How are you powering the BomeBox? If via USB, see if you can use a different power cable or adapter or even better still POE (which is what I use as the higher voltage seems less susceptible to voltage variations.

Steve Caldwell
Bome Customer Care


Also available for paid consulting services: bome@sniz.biz

More than eight class compliant midi devices in general — they’re mostly synths, argon8, minitaur, etc. I’d rather run stuff on USB midi than cables if I can; less wire to deal with. I pulled the ESI out of USB 3 mode, but no change in the behavior. If the Bome doesn’t support USB 3, it would have to be auto-negotiating down anyway, but I guess it’s good to eliminate that somehow messing up the whole USB stack or something. I also confirmed again that I get the same out of audio devices kernel message even with only single-port class compliant devices plugged in.

So, the situation here would be more like plugging in 9 midihubs or 9 keysteps via a powered USB hub. When I say I get an error with more than eight USB ports, I don’t mean USB midi virtual devices, I mean actual class compliant USB midi hardware boxes. The Bome is bring powered off the factor USB cable, plugged into a 120W Belkin USB power supply that guarantees 2.4A per device.

(And the powered hub I’m using is the Startech industrial hub that has a 60W power supply; no signs that anything isn’t getting enough power on that side, either, and no other notable kernel errors)

OK, maybe I can plug in 9 controllers (separately) via USB instead to see what happens. Just need to find a good powered USB hub lying around.

So your issue is with max USB ports not max USB MIDI Devices. Again, I don’t think there is a limit but will check.

Steve Caldwell
Bome Customer Care


Also available for paid consulting services: bome@sniz.biz

Yes, that’s right — doesn’t seem to make a difference how many virtual midi devices the USB device presents.

(Also, thank you very much for digging into debugging with me here!)

OK,
I now have the following hooked up through 2 powered USB hubs (cascaded)
2 - MIDI Fighter Twister
1- Arturia Beatstep
1- Novation Launch Control
1–Novation Launch Control XL
1-Korg NanoKontrol2
1-Novation Launchpad MINI
1-Novation Launchpad MINI MK3

Whoops that is 8 let me add another. So much for my math skills :wink:

All 8 are physically attached devices are recognized by my BomeBox but not the 9th
2 of these devices have more than 1 virtual MIDI port exposed so I have 11 USB MIDI ports exposed as well as 1 network port and the MIDI DIN Port.

Steve Caldwell
Bome Customer Care


Also available for paid consulting services: bome@sniz.biz

Interesting! And no kernel errors about USB audio devices?

I only had 8. I just tried adding an iCon I controls to the mix and it doesn’t show up.

Still testing …

Aha, yeah — that was the behavior. Did you get the error in the kernel log?

Yes,

[ 1886.690000] no available usb audio device
[ 1886.690000] snd-usb-audio: probe of 1-1.4:1.0 failed with error -5
[ 1896.730000] input: iCON iCON iControls V2.04 as /devices/platform/ehci-platform/usb1/1-1/1-1.4/1-1.4:1.1/input/input1
[ 1896.730000] hid-generic 0003:1D03:001A.0001: input,hidraw0: USB HID v1.10 Mouse [iCON iCON iControls V2.04] on usb-ehci-platform-1.4/input1

I’m going to try and load some Beta firmware on my BomeBox to see if it fixes it.

Steve Caldwell
Bome Customer Care


Also available for paid consulting services: bome@sniz.biz

Aha, yeah, it looks like CONFIG_SND_MAX_CARDS is 8 by default: https://elixir.bootlin.com/linux/v4.0/source/include/sound/core.h. I think it may take a custom kernel build to increase it beyond that.

OK, yes I’m now on Beta 1.5 and same problem (just different device not showing up). I’ll see what can be done and let you know.

Steve Caldwell
Bome Customer Care


Also available for paid consulting services: bome@sniz.biz

Hi, we have run tests with many devices (including multi-port devices), but there is a pending bug report of a user hitting a limit of, I think, 32 devices. We had not prioritized that bug, because 32 USB devices is plenty already. But 8 is definitely not enough!

I have just run a quick test with a USB 3 hub and indeed, I can confirm a maximum of 8 devices.

It could be an accidental reconfiguration in one of the last BomeBox firmware updates.
A bug report is filed.

Hi @florian

Just to be clear. If we have less than or equal to 8 physical USB devices, we are OK, even if there is more than 8 logical USB ports (within the physical devices). The issue is if there are more than 8 “physical” USB devices attached.

For instance, with 2 USB interfaces and 1 device (3 physical devices), it works fine even though 2 of the USB interfaces each have 4 logical devices ( 9 logical USB devices total).

I think the key question is how many physical USB devices should be realistically configured (maybe 16)?

Steve Caldwell
Bome Customer Care


Also available for paid consulting services: bome@sniz.biz

Yes, it seems that this is due to the linux kernel setting CONFIG_SND_DYNAMIC_MINORS . If it is not set, the kernel only allows 8 USB devices (no matter how many MIDI ports each device provides). If it’s set, we’re back to 32 USB devices.
I’ll run some tests tomorrow.

1 Like

Great — I thought this would have to be a regression, or it would have been mentioned in the docs. 32 devices would be great, and would be plenty of headroom.

No rush of course — I’m sure you’ve got a bunch of stuff to juggle, but when you get there, it’d be great to have a heads up on how long you think it’ll take to ship a fix, especially as we’re getting into the holidays (and I hope you’ll get some time off). If it’s going to be more than a week or two, I’ll either pick up a second box or some more midi interface ports so I can run off DIN for the time being.

I have a firmware build available which works with more than 8 USB devices here. I’ll PM you with a download link.

2 Likes