I have a HiFiBerry DAC2 Pro working in a buildroot image, but with the following issue. If I boot the system without a USB MIDI device plugged in, the DAC2 Pro comes up correctly. It continues to work properly if I then hot plug in a USB MIDI device. However, if I boot the system with the USB MIDI device already plugged in, the DAC2 Pro will not open properly. It shows up as an available device using aplay -l, the same as it does when booted without the MIDI device in, but it fails to open either in my app or in alsamixer.
I've examined the boot log, but so far have not found a problem.
Any thoughts as to the best way to debug this?