Bug 80170

Summary: Disk standby timer is broken
Product: udisks Reporter: Phillip Susi <psusi>
Component: generalAssignee: David Zeuthen (not reading bugmail) <zeuthen>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: medium    
Version: unspecified   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:
Attachments: 0001-Fix-standby-timers.patch

Description Phillip Susi 2014-06-17 23:01:01 UTC
udisks' / gnome-disk-utility's support for the drive standby timer is broken. If the standby timer is set to at least 10 minutes ( which is the minimum on many drives ), every 10 minutes udisks tries to update the smart status of the drive, which resets the standby timer.

Reported in Ubuntu: https://bugs.launchpad.net/bugs/1281588

As David Zuthern noted in a private message, my initial patches to fix this also prevent ever updating smart data on disks that are never used, even if they do not have a standby timer enabled.  I will fix them to be contingent on a standby timer and post updated patches here soon.
Comment 1 Phillip Susi 2014-06-22 23:26:15 UTC
Created attachment 101544 [details] [review]
0001-Fix-standby-timers.patch

Ok, here is an updated version that bypasses the no io skip check when the standby timer has not been enabled.  I verified that it keeps reading the smart stats on an idle drive when you disable the standby timer in gnome-disks.
Comment 2 David Zeuthen (not reading bugmail) 2014-06-25 23:45:14 UTC
I'll take a look.
Comment 3 David Zeuthen (not reading bugmail) 2014-07-08 17:53:35 UTC
(Sorry for being slow. Will post feedback soon.)
Comment 4 Phillip Susi 2014-10-24 18:15:07 UTC
Bump...

If you don't have time to review/test the patch yourself, are you satisfied with my description of the changes to the point that you would not have a problem with Martin Pitt reviewing and pushing it now?
Comment 5 Phillip Susi 2014-12-08 20:37:16 UTC
Hi David, it has now been six months of waiting for an ACK ;)
Comment 6 Martin Pitt 2014-12-18 10:14:56 UTC
Thanks for the updated patch! I looks good to me, I pushed it with some minor cleanups (variable names, PATH_MAX).

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.