Johannes,
I got a CTX monitor/hub this week and spent today
looking into this problem. The problem is that
the hub doesn't like to return a partial descriptor
in usb_hub_configure() [2-byte "header" is requested].
I have made 2 workarounds for this and either one
of them works, but I'd like your opinion on them,
then one of us can make a patch to hub.c.
A. Do the normal 2-byte header request, then handle
this error case (something like):
if (ret == -EPIPE &&
(vendor == CTX) && (product == 0x9999)) {
/* simulate good desc & clear the stall */
bLength = 2;
bDescType = USB_DT_HUB;
if (usb_clear_halt(dev, usbrcvctrlpipe(dev, 0)))
return -1;
}
...
. More direct, less intrusive to the current code.
or:
B. Don't do a 2-byte header request; do a header request
of 13 bytes [or maybe even larger, but 13 bytes is enough
for a 16-port hub]. This requires only one get_hub_desc()
call instead of 2. Instead of the 2nd call, just
memcpy (bitmap, buffer, header->bLength).
[Think we'll ever need to support more than 16 ports on
a hub?]
. More general solution [unless we find some hub that doesn't
like descriptor requests that are _larger_ than actual].
. Calls get_hub_desc() one time instead of 2 times.
I tested both methods with a keyboard and floppy drive
on UHCI (both HCDs) and OHCI.
Which method do you prefer? Do you want to make a hub.c
patch for this or have me do it? I'll be glad to send
my patches to you, of course.
~Randy
___________________________________________________
|Randy Dunlap Intel Corp., DAL Sr. SW Engr.|
|randy.dunlap.at.intel.com 503-696-2055|
|NOTE: Any views presented here are mine alone |
|and may not represent the views of my employer. |
|_________________________________________________|
> -----Original Message-----
> From: Ken Scott [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, May 24, 2000 7:53 PM
> To: Dunlap, Randy
> Cc: [EMAIL PROTECTED]
> Subject: RE: [linux-usb] Monitor with embedded hub
>
> On Tue, 23 May 2000, Dunlap, Randy wrote:
>
> > Hi Ken,
> >
> > Also, your kernel messages file shows:
> > May 22 23:28:01 neon kernel: usb.c: USB disconnect on device 3
> > May 22 23:28:07 neon kernel: usb.c: USB new device connect,
> assigned device number 3
> > May 22 23:28:07 neon kernel: hub.c: USB hub found
> >
> > so it looks like the hub is being detected, but something fails
> > quickly after hub detection. Can you set the console loglevel
> > to 9 and repeat the monitor-hub connection (plug-in) and post
> > that portion of the kernel log file? (Use Alt-SysRq-9 if you
> > have Magic SysRq key enabled. You can also boot linux with
> > the 'debug' option [as in: linux debug] if you don't want to
> > build a kernel with Magic SysRq key enabled.)
> >
>
> I have attached the portion of my /var/log/messages after I
> set the SysRq
> level and attached the hub. Is this the correct log file that you are
> looking for?
>
> I have the user's guide for the monitor, but it doesn't
> include any USB
> information. I will try to contact the mfg. and see if they
> will provide anything.
>
> Thanks,
> Ken
>
> --
> ><> Ken Scott [EMAIL PROTECTED] http://www.pcisys.net/~kscott
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]