Skip to content

Support power resources defined in acpi on ata

Markus Probst linux-ide linux-scsi lkml 6 versions – Applied

Status from this message: Applied to 6.19/scsi-staging, thanks!

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v6 Latest3 patches 6 repliesApplied
  2. v53 patches 3 repliesSuperseded
  3. v43 patches 2 repliesSuperseded
Earlier versions · 3
VersionPostedPatchesRepliesStatus
v32 patches3 repliesSuperseded
v22 patches3 repliesSuperseded
v12 patches7 repliesSuperseded

Changes in v6 from the cover letter

- moved the 3. patch before the 2. patch
- removed unnecessary blank line
- improved commit messages
- improved documentation
- fixed typo in error message

Patches in v6 Applied

#Subject and filesSizeRepliesApplied
1/3scsi: sd: Add manage_restart device attribute to scsi_diskdrivers/scsi/sd.c include/scsi/scsi_device.h+39 -10 replies
2/3ata: Use ACPI methods to power on disksdrivers/ata/libata-acpi.c drivers/ata/libata-core.c drivers/ata/libata.h+45 -01 reply
3/3ata: stop disk on restart if ACPI power resources are founddrivers/ata/libata-acpi.c drivers/ata/libata-scsi.c drivers/ata/libata.h+29 -00 replies

Reviews trailers per patch

All 3 patches have a Reviewed-by or Acked-by.

PatchDamien Le Moal
1/3R-b
2/3R-b
3/3R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v6 thread

Cover letter [PATCH v6 0/3] Support power resources defined in acpi on ata

This series adds support for power resources defined in acpi on ata ports/devices. A device can define a power resource in an ata port/device, which then gets powered on right before the port is probed. This can be useful for devices, which have sata power connectors that are:
a: powered down by default
b: can be individually powered on
like in some synology nas devices. If thats the case it will be assumed, that the power resource won't survive reboots and therefore the disk will be stopped.

Changes since v5:
- moved the 3. patch before the 2. patch
- removed unnecessary blank line
- improved commit messages
- improved documentation
- fixed typo in error message

Changes since v4:
- improved documentation
- use false/true instead of 0/1
- removed repeating code in ata_acpi_dev_manage_restart
- split long lines
- removed debug message
- improved error message

Changes since v3:
- rename function from "ata_port_set_power_state"
to "ata_acpi_port_power_on" and remove enable argument
- split "ata_acpi_port_power_on" and "ata_acpi_dev_manage_restart" into two commits
- improved commit messages
- improved comments (style and new comments)

Changes since v2:
- improved commit messages
- addressed warning from kernel test robot

Changes since v1:
- improved commit messages
- addressed style issues (too long lines and docs)
- removed ata_dev_manage_restart() and ata_port_set_power_state() methods
- improved log messages in ata_acpi_port_set_power_state

Markus Probst (3):
scsi: sd: Add manage_restart device attribute to scsi_disk
ata: Use ACPI methods to power on disks
ata: stop disk on restart if ACPI power resources are found

 drivers/ata/libata-acpi.c  | 67 ++++++++++++++++++++++++++++++++++++++
 drivers/ata/libata-core.c  |  2 ++
 drivers/ata/libata-scsi.c  |  1 +
 drivers/ata/libata.h       |  4 +++
 drivers/scsi/sd.c          | 34 ++++++++++++++++++-
 include/scsi/scsi_device.h |  6 ++++
 6 files changed, 113 insertions(+), 1 deletion(-)
Signature · 1 line
2.51.0