Re: [linux-pm] power_state: get rid of write-only variable in SATA

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

 



> libata uses it under the assumption that "other parts" of the system are 
> aware of this variable.
>
> May I assume that the API has changed such that this is no longer necessary?

Yes.  The original motivation for dev->power.power_state was to let
the writes to /sys/devices/.../power/state support a PCI-specific
policy for device power state transition.  And the motivation for
any driver (or framework) to modify that was that the PM core didn't
update it in all the relevant code paths (it wan't clear how to do
that either), which mean those sysfs files could make trouble.

That file is gone; everything supporting its usage can now go away.
(And the PCI-specific policy -- "only transitions to/from D0 are
allowed" -- can be managed by PCI drivers, and ignored by others
on more flexible hardware.)

The minor problem removing it is that there's some code which has
used fields in power_state for some driver state.  But if all that
usage is write-only in the drivers (is that true now for SATA?),
then it's safe to remove the /sys/devices/.../power/state support
from framework code and elsewhere.

- Dave


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

[Index of Archives]     [Linux Filesystems]     [Linux SCSI]     [Linux RAID]     [Git]     [Kernel Newbies]     [Linux Newbie]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Samba]     [Device Mapper]

  Powered by Linux