On Mon, 2 Jul 2007, jidong xiao wrote:

> Another separate issue,still focus on this piece of code,(inside
> drivers/usb/core/hub.c, hub_configure())
> 
> > >
> > >     570         switch (hdev->descriptor.bDeviceProtocol) {
> > >     571                 case 0:
> > >     572                         break;
> > >     573                 case 1:
> > >     574                         dev_dbg(hub_dev, "Single TT\n");
> > >     575                         hub->tt.hub = hdev;
> > >     576                         break;
> > >     577                 case 2:
> > >     578                         ret = usb_set_interface(hdev, 0, 1);
> > >     579                         if (ret == 0) {
> > >     580                                 dev_dbg(hub_dev, "TT per port\n");
> > >     581                                 hub->tt.multi = 1;
> > >     582                         } else
> > >     583                                 dev_err(hub_dev, "Using single
> > > TT (err %d)\n",
> > >     584                                         ret);
> > >     ...
> 
> see case 2,note that usb_set_interface() is called,I don't understand
> the purpose of calling this function,you know,based on usb spec 2.0,
> Table 11-14, "hubs are allowed to support only one interface",thus
> neither GET_INTERFACE nor SET_INTERFACE is supported by hubs,or say,
> undefined.So I also looked through the internal part of
> usb_set_interface,maybe we actually won't send any request to the
> hub,but why we call this function at this situation.

Hubs can have only one interface, but that interface can have two
different altsettings.  See section 11.23.1 of the spec and see the
revised version of Table 11-14 in the USB 2.0 Errata document.

Alan Stern


-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
linux-usb-devel@lists.sourceforge.net
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to