]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
udev/ata_id: export read look-ahead values
authorTomas Bzatek <tbzatek@redhat.com>
Tue, 10 Sep 2024 10:26:02 +0000 (12:26 +0200)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Tue, 10 Sep 2024 13:04:30 +0000 (22:04 +0900)
Indicates whether the ATA read look-ahead feature is supported
and enabled.

Signed-off-by: Tomas Bzatek <tbzatek@redhat.com>
src/udev/ata_id/ata_id.c

index 6baf1390449a7ee5812bb4e8c44712e5116893fb..c3388e640cb154be15dcc243dd9911b21339839a 100644 (file)
@@ -507,6 +507,10 @@ static int run(int argc, char *argv[]) {
                         printf("ID_ATA_WRITE_CACHE=1\n");
                         printf("ID_ATA_WRITE_CACHE_ENABLED=%d\n", (id.cfs_enable_1 & (1<<5)) ? 1 : 0);
                 }
+                if (id.command_set_1 & (1<<6)) {
+                        printf("ID_ATA_READ_LOOKAHEAD=1\n");
+                        printf("ID_ATA_READ_LOOKAHEAD_ENABLED=%d\n", (id.cfs_enable_1 & (1<<6)) ? 1 : 0);
+                }
                 if (id.command_set_1 & (1<<10)) {
                         printf("ID_ATA_FEATURE_SET_HPA=1\n");
                         printf("ID_ATA_FEATURE_SET_HPA_ENABLED=%d\n", (id.cfs_enable_1 & (1<<10)) ? 1 : 0);