Re: [PATCH] fixed bug in usbsevseg using USB autosuspend incorrectly

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Am Montag, 8. März 2010 16:15:14 schrieb Harrison Metzger:
> Also, the old logic would call usb_autopm_put_interface() if
> shadow_power == 1 and the user requested the display to be off ("echo
> 0 > /sys/$DEVICE/powered"). If usb autosuspend was disabled the
> suspend() function would never be called, and the shadow_power
> variable would still be 1. So the user could "echo 0" multiple times
> (even though the display is already off) and this would really screw
> up the reference count (it would be negative from calling
> usb_autopm_put_interface() multiple times).
> 
> This is why there is a separate variable to track if we have called
> usb_autopm_get/put_interface().

OK, why not remove shadow_power?

	Regards
		Oliver
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux