> Actually, no, I need to debug /sys/src/9/pc/devusb.c as it does not
> detect the device the way NetBSD does.  Incidentally, its VID and DID

it isn't really involved, except to store the values and return
them when a status file is read.  usbd does the enumeration etc.
and it tags the device with vendor and device IDs once it has
got them, by writing them in a control message ("class" i think)
to the usb device ctl file.  that's why you needed the updated
usbd as well as the usb driver.  you need the latter to implement
the message; you need the former to do the work.

{usb/usbd -v} will trace some of its actions.

the driver is not even involved much in root port detection:
even then it's just a matter of returning to usbd
values it reads from the port control registers.
that's partly because the things must be polled, and
that might as well be programmed at user level,
where one can use thread.h

Reply via email to