Re: [PATCH 1/2 v2] usb/core: consider link speed while looking at bMaxPower

2012-12-06 Thread Sebastian Andrzej Siewior
On 12/05/2012 09:42 PM, Alan Stern wrote: value based on config& usb_device's speed value. The sysfs interface& the device descriptor dump compute the value on their own. Why doesn't the sysfs function use usb_get_max_power? Am I missing something? I have no idea. Updated the function. A

Re: [PATCH 1/2 v2] usb/core: consider link speed while looking at bMaxPower

2012-12-05 Thread Alan Stern
On Wed, 5 Dec 2012, Sebastian Andrzej Siewior wrote: > The USB 2.0 specification says that bMaxPower is the maximum power > consumption expressed in 2 mA units and the USB 3.0 specification says > that it is expressed in 8 mA units. > This patch adds a helper function usb_get_max_power() which com