Thread (1 message) 1 message, 1 author, 2012-12-14

Re: [PATCHv2][RFC] smsc95xx: enable dynamic autosuspend

From: Oliver Neukum <hidden>
Date: 2012-12-14 14:22:31

On Friday 14 December 2012 13:35:04 Steve Glendinning wrote:
Thanks Ming, I've updated this.
Very good. Good catch Ming.
quoted
IMO, it is better to keep smsc95xx_info.manage_power as NULL
for devices without FEATURE_AUTOSUSPEND, so that fewer code
and follow the current .mange_power usage(see its comment).

Currently, if the function pointer of manage_power is set, it means that
the device supports USB autosuspend, but your trick will make the
manage_power() can return errors. So the assumption was always
strictly speaking invalid.
quoted
assumption not true for some smsc devices.
Oliver?
On second thought, I think that if a driver can do manage_power(), even
only for a subset of devices, it should implement it. Doctoring the table of methods
is very, very ugly, especially as this not protected by a lock.

But this is not nice. We need a better way.

	Regards
		Oliver

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help