lkml.org 
[lkml]   [2011]   [Aug]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCHv3 2/4] usb: gadget: replace "is_dualspeed" with "max_speed"
Date
From
On Tue, 23 Aug 2011 22:49:37 +0200, Alan Stern <stern@rowland.harvard.edu>  
wrote:
> Still, maybe I was wrong. Maybe it would be better to use the fastest
> speed supported by at least one of the function drivers. The user can
> always force a SuperSpeed-capable device to run at high speed by using
> a USB-2 cable to plug it in. I'm not sure whether the user could force
> such a device to run at full speed, however.

I'm actually wondering whether we really need to worry about it.
composite_driver has the “max_speed” field and I would just leave it as
composite driver's author responsibility to put correct value there.

One thing that could be worth doing is iterate over all the configurations
and figure out if at least one supports the speed declared by “max_speed”
and if not, lower it.

Like I've said before, as additional functionality, composite.c could
check if it's USB_SPEED_UNKWONW in which case it would look for the lowest
speed that all the functions support.

Such configuration would allow composite driver authors set the speed to
USB_SPEED_SUPER when they mean “choose maximum speed at least one function
supports” and to “USB_SPEED_UNKWONW” when they mean “choose maximum speed
all the functions support”.

Does that make sense?

--
Best regards, _ _
.o. | Liege of Serenely Enlightened Majesty of o' \,=./ `o
..o | Computer Science, Michal "mina86" Nazarewicz (o o)
ooo +-----<email/xmpp: mnazarewicz@google.com>-----ooO--(_)--Ooo--
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2011-08-24 15:13    [W:0.172 / U:0.716 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site