Hi,

> > Those might be a good place to start. IOKit provides the drivers and
> > also the io registry which is probably where you can get if a driver
> > is bound to a device and which one is it. How to dissociate the
> > driver from the device though I don't know.

> https://developer.apple.com/library/archive/documentation/DeviceDrivers/Conceptual/IOKitFundamentals/DeviceRemoval/DeviceRemoval.html

> According to this article a driver has a stop() and detach() method
> that is called by the IOKit to remove a device. I'm thinking QEMU can
> be the one that calls these methods for a certain device.

libusb should do that.  Interfaces exist already (see
libusb_detach_kernel_driver & friends) because we have the very same
problem on linux.

take care,
  Gerd


Reply via email to