From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: To: 9fans@cse.psu.edu Subject: Re: [9fans] just checking ... From: Charles Forsyth Date: Fri, 24 Mar 2006 17:41:40 +0000 In-Reply-To: <9394663c4db4f35f890ee19ac3e37a17@proxima.alt.za> MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Topicbox-Message-UUID: 1f3f174c-ead1-11e9-9d60-3106f5b1d025 > 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