All of lore.kernel.org
 help / color / mirror / Atom feed
* Using a composite device with kernel drivers and libusb at the same time
@ 2024-03-27 11:33 Martijn Braam
  2024-03-27 13:04 ` Greg KH
  2024-03-27 14:07 ` Alan Stern
  0 siblings, 2 replies; 3+ messages in thread
From: Martijn Braam @ 2024-03-27 11:33 UTC (permalink / raw)
  To: linux-usb

I hope this is an acceptable place to ask this question. I've spend a 
bit of time reverse-engineering the USB protocol for a subset of 
Blackmagic Design video mixers and I have made a userspace 
implementation to make these devices usable in Linux with libusb. This 
is working great but the roadblock I have that I can't find a reasonable 
solution for is that these devices also expose an UVC webcam.

While my control software is active it's not possible to use the UVC 
webcam functionality of the device because with libusb I have to detach 
the kernel from the interfaces to make my userspace access work. As far 
as I can find documented online there's no way to have half a composite 
device handled by kernel drivers and half with userspace drivers in 
Linux. It seems to me the only solution is to make a kernel driver to 
bind to the control interface and have that kernel driver pass-through 
to userspace somehow with a custom protocol? If that is the case would 
such a driver even be supported in Linux?

For reference the device I'm working has these looks like this:

USB 1-4  [1edb:be55] Blackmagic design Blackmagic Design [serial]
    Class EF SubClass 02 Protocol 01
       Interface 0 FF/03/00 Unknown <- Blackmagic USB configuration protocol
       Interface 1 FF/02/00 Unknown <- Blackmagic USB control protocol 
(I'm using this with libusb)
       Interface 2 FF/04/00 Unknown <- Unknown
       Interface 3 FE/01/01 Unknown <- DFU
       Interface 4 0E/01/01 Blackmagic Design <- UVC camera
       Interface 5 0E/02/01 Unknown <- UVC camera
       Interface 6 01/01/00 Blackmagic Design <- ALSA
       Interface 7 01/02/00 Unknown <- ALSA

If this is not the right place for this question, then where would the 
right place be?

Greetings,
Martijn Braam


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2024-03-27 14:07 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-03-27 11:33 Using a composite device with kernel drivers and libusb at the same time Martijn Braam
2024-03-27 13:04 ` Greg KH
2024-03-27 14:07 ` Alan Stern

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.