From: Damien Le Moal <dlemoal@kernel.org>
To: Markus Probst <markus.probst@posteo.de>,
Niklas Cassel <cassel@kernel.org>,
"James E.J. Bottomley" <James.Bottomley@HansenPartnership.com>,
"Martin K. Petersen" <martin.petersen@oracle.com>
Cc: linux-ide@vger.kernel.org, linux-scsi@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v5 2/3] ata: stop disk on restart if ACPI power resources are found
Date: Tue, 28 Oct 2025 12:53:32 +0900 [thread overview]
Message-ID: <896e0d4a-b9c2-43d6-a8bd-e717bfbab817@kernel.org> (raw)
In-Reply-To: <20251027202339.1043723-3-markus.probst@posteo.de>
On 10/28/25 5:23 AM, Markus Probst wrote:
> Some embedded devices have the ability to control whether power is
> provided to the disks via the SATA power connector or not. ACPI power
> resources are usually off by default, thus making it unclear if the
> specific power resource will retain its state after a restart. If power
> resources are defined on ATA ports / devices in ACPI, we should stop the
> disk on SYSTEM_RESTART, to ensure the disk will not lose power while
> active.
>
> Add a new function, ata_acpi_dev_manage_restart(), that will be used to
> determine if a disk should be stopped before restarting the system. If a
> usable ACPI power resource has been found, it is assumed that the disk
> will lose power after a restart and should be stopped to avoid a power
> failure.
I think you meant to say "to avoid unclean shutdown due to power loss." ?
Because this is not handling a power failure, but rather a power loss on
shutdown with the device still running, right ?
With that clarified, looks OK to me.
Reviewed-by: Damien Le Moal <dlemoal@kernel.org>
--
Damien Le Moal
Western Digital Research
next prev parent reply other threads:[~2025-10-28 3:57 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-10-27 20:23 [PATCH v5 0/3] Support power resources defined in acpi on ata Markus Probst
2025-10-27 20:23 ` [PATCH v5 1/3] scsi: sd: Add manage_restart device attribute to scsi_disk Markus Probst
2025-10-28 3:53 ` Damien Le Moal
2025-10-27 20:23 ` [PATCH v5 2/3] ata: stop disk on restart if ACPI power resources are found Markus Probst
2025-10-28 3:53 ` Damien Le Moal [this message]
2025-10-27 20:23 ` [PATCH v5 3/3] ata: Use ACPI methods to power on disks Markus Probst
2025-10-28 3:58 ` Damien Le Moal
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=896e0d4a-b9c2-43d6-a8bd-e717bfbab817@kernel.org \
--to=dlemoal@kernel.org \
--cc=James.Bottomley@HansenPartnership.com \
--cc=cassel@kernel.org \
--cc=linux-ide@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=markus.probst@posteo.de \
--cc=martin.petersen@oracle.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®