Re: [RFC PATCH] USB: enable "power/wakeup" to control remote wakeup in the runtime suspend

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

 



Sorry for later reply. :)

On 2012年07月21日 01:08, Sarah Sharp wrote:
On Thu, Jul 19, 2012 at 11:42:57AM +0200, Oliver Neukum wrote:
On Thursday 19 July 2012 15:42:37 Lan Tianyu wrote:
On 2012年07月19日 14:37, Oliver Neukum wrote:

But this leaves me with a question. Has anybody ever measured the additional
power savings compared to a suspended state for devices? Or are you doing
this only as a prelude to become able to send host controllers to D3cold?
hi Oliver:
	I have done a test on a usb3.0 ORICO SSD which may cost 3w normally.
Traditional suspend can save 1w. Power off can save additional 2w. I also test

Well, then the device violates the standard for power consumption.

Not necessarily.

Tianyu, are you measuring the whole system power consumption or just the
power drawn by the device?  How are you measuring power consumption?
I measure the whole system power consumption. First, boot system and wait
for the power consumption stable. Second, kill udev and disable block layer
check event. Third, enable the device runtime pm. Observe the power consumption
change. Get result.


Also, are you sure the mass storage device was actually suspended?
I am sure the device was suspended via power/runtime_status.

Unfortunately, userspace polls unmounted drives every two seconds or so
to see if there's a medium change.  So even though you may have enabled
auto-suspend, userspace will still be waking the device out of suspend
every two seconds.  That might explain your high suspend power
consumption.
Just like you said, udev may poll usb device drives every two seconds.
Moreover, the block layer also will check the disk status periodically.
AS alan pointed, echo 0 >/sys/block/sdX/events_poll_msec to stop check
event. So before I tested, I kill udev and disable the block layer check
event. Finally, I got stable power consumption. I will also test other
usb3.0 devices.


You would need to unload the mass storage driver to truly measure
uninterrupted suspend power consumption.

You can also set the power/autosuspend_delay_ms to something very low,
like 10, in order to get the mass storage device into suspend faster
than every two seconds.
Thanks for reminder. I have done it. Following is my script to enable
runtime pm under usb device's sysfs directory.

rtauto:
for f in `find . -name control | grep power` ; do
        echo auto > $f
done

for f in `find . -name autosuspend_delay_ms` ; do
        echo 100 > $f > /dev/zero
done

Sarah Sharp

--
Best Regards
Tianyu Lan
linux kernel enabling team
--
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