Re: USB card reader autosuspend

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

 



Am Sonntag, 8. August 2010, 23:03:55 schrieb Alan Stern:
> Oliver:
> 
> I did a little testing.  You are right that we will run into problems
> with card readers that don't properly track media changes while at low
> power.  Going through all the partition/volume ID/RAID detection stuff
> every few seconds (thanks to hal's polling) would be a real drain.

That is unfortunate, even if intellectually somewhat satisfying.

> To avoid these problems, I changed sd to make it autosuspend only when
> the device file is closed _and_ there is no medium present.  The patch
> below is just a proof-of-principle; in the end we'll want something
> more flexible.  Maybe a sysfs attribute to select the conditions under
> which autosuspend is allowed.
> 
> What do you think?

I agree in principle. But I don't think you can depend on sdkp->media_present
remaining constant between sd_open() and sd_release()

	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