public inbox for linux-ide@vger.kernel.org
 help / color / mirror / Atom feed
From: Niklas Cassel <cassel@kernel.org>
To: Damien Le Moal <dlemoal@kernel.org>
Cc: wolf@yoxt.cc, linux-ide@vger.kernel.org
Subject: Re: [REGRESSION] libata: SATA LPM forcibly disabled on Intel Raptor Lake since Linux 6.14.
Date: Wed, 7 Jan 2026 12:20:44 +0100	[thread overview]
Message-ID: <aV5BjOXc1uK2HSZA@ryzen> (raw)
In-Reply-To: <85cae643-f3bc-43db-966c-3f57d8daa6b6@kernel.org>

On Wed, Jan 07, 2026 at 11:19:42AM +0100, Damien Le Moal wrote:
> > 
> > This is most likely because your ports are marked as External / Hotplug
> > capable by BIOS.
> 
> I do not think so. There is no "ext" advertized in the log for the valid ports.
> But still worth trying to see if the BIOS has a hotplug option and disable it if
> it does.

Good catch.

One thing that caught my eye:
[    1.433187] ata6.00: ATAPI: PIONEER BD-RW  BDR-S12JX, 1.01, max UDMA/100
[    1.433272] ata5.00: ATAPI: PIONEER BD-RW  BDR-S12JX, 1.01, max UDMA/100

We've had so many problems with PIONEER...


So, since we concluded that you don't have any ports marked as External,
to get deeper sleep states, all SATA ports will need to be in a power
saving state.

Ports that don't have any device connected will get powered off, so they
are no problem.


For LPM to work, you need to use either HIPM (host-initiated) or DIPM
(device initiated). You can have both enabled, but the device needs to
support one of them to enter a power saving state.


I think the problem is:

[    3.010059] ata8.00: ATA-11: ST16000NM000J-2TW103, SN06, max UDMA/133
[    3.010079] ata7.00: ATA-11: ST16000NM000J-2TW103, SN06, max UDMA/133
[    3.012748] ata6.00: ATAPI: PIONEER BD-RW  BDR-S12JX, 1.01, max UDMA/100
[    3.012779] ata5.00: ATAPI: PIONEER BD-RW  BDR-S12JX, 1.01, max UDMA/100
[    3.061873] ata8.00: Features: DIPM NCQ-sndrcv
[    3.065319] ata7.00: Features: DIPM NCQ-sndrcv

The ST drives advertise support for DIPM, so these two ports should enter
a lower power state.


For the PIONEER optical drives however, we don't seem to get any "Features: "
print at all. My guess is that the support neither HIPM nor DIPM, and thus
stops the whole system from entering a lower power state.


What I think happens:

For a device that does not support HIPM, we will clear flag ATA_LPM_HIPM from
hints:
https://github.com/torvalds/linux/blob/v6.19-rc4/drivers/ata/libata-eh.c#L2168-L2169

If flag ATA_LPM_HIPM is not set, we will disable HIPM (ALPE) for the port:
https://github.com/torvalds/linux/blob/v6.19-rc4/drivers/ata/libahci.c#L835-L847

Thus the HBA will never tell the device to enter a low power state.
(And if DIPM is not supported, the device itself will never enter a low
power state.)


Questions:
-Why was this not a problem on older kernels?

If you are willing try some patches from us, we could give you a patch with more
debug prints, to show for each device, when we {enable,disable} {HIPM,DIPM}.


-Why don't we get the Features: print for ATAPI devices?

We probably need something like this:

diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c
index fc250b494ce3..a8af200ac24f 100644
--- a/drivers/ata/libata-core.c
+++ b/drivers/ata/libata-core.c
@@ -3161,11 +3161,13 @@ int ata_dev_configure(struct ata_device *dev)
                /* print device info to dmesg */
                if (print_info)
                        ata_dev_info(dev,
-                                    "ATAPI: %s, %s, max %s%s%s%s\n",
+                                    "ATAPI: %s, %s, max %s%s%s%s%s%s\n",
                                     modelbuf, fwrevbuf,
                                     ata_mode_string(xfer_mask),
                                     cdb_intr_string, atapi_an_string,
-                                    dma_dir_string);
+                                    dma_dir_string,
+                                    ata_id_has_hipm(dev->id) ? " HIPM" : "",
+                                    ata_id_has_dipm(dev->id) ? " DIPM" : "");
        }
 
        /* determine max_sectors */



Kind regards,
Niklas

  parent reply	other threads:[~2026-01-07 11:20 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-01-06 19:57 [REGRESSION] libata: SATA LPM forcibly disabled on Intel Raptor Lake since Linux 6.14 wolf
2026-01-07 10:14 ` Niklas Cassel
2026-01-07 10:19   ` Damien Le Moal
     [not found]     ` <70a55b1ecd97f30795879994a07764bc@yoxt.cc>
2026-01-07 10:38       ` Damien Le Moal
2026-01-07 11:20     ` Niklas Cassel [this message]
2026-01-07 15:16       ` 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=aV5BjOXc1uK2HSZA@ryzen \
    --to=cassel@kernel.org \
    --cc=dlemoal@kernel.org \
    --cc=linux-ide@vger.kernel.org \
    --cc=wolf@yoxt.cc \
    /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