summaryrefslogtreecommitdiffstats
path: root/drivers/ata/libata-acpi.c
diff options
context:
space:
mode:
authorNiklas Cassel <niklas.cassel@wdc.com>2022-10-07 15:23:38 +0200
committerDamien Le Moal <damien.lemoal@opensource.wdc.com>2022-10-18 13:53:27 +0900
commit4cb7c6f1ef9642cd2c8580b495fde47ffbaddef7 (patch)
tree86895369e211cbf8def44a05346e994adfe1d43d /drivers/ata/libata-acpi.c
parentfddb1a6424787d8089a9032bd5d21c428670f854 (diff)
downloadlinux-4cb7c6f1ef9642cd2c8580b495fde47ffbaddef7.tar.bz2
ata: make use of ata_port_is_frozen() helper
Clean up the code by making use of the newly introduced ata_port_is_frozen() helper function. Signed-off-by: Niklas Cassel <niklas.cassel@wdc.com> Signed-off-by: Damien Le Moal <damien.lemoal@opensource.wdc.com>
Diffstat (limited to 'drivers/ata/libata-acpi.c')
-rw-r--r--drivers/ata/libata-acpi.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/ata/libata-acpi.c b/drivers/ata/libata-acpi.c
index 61b4ccf88bf1..d36e71f475ab 100644
--- a/drivers/ata/libata-acpi.c
+++ b/drivers/ata/libata-acpi.c
@@ -992,7 +992,7 @@ int ata_acpi_on_devcfg(struct ata_device *dev)
acpi_err:
/* ignore evaluation failure if we can continue safely */
- if (rc == -EINVAL && !nr_executed && !(ap->pflags & ATA_PFLAG_FROZEN))
+ if (rc == -EINVAL && !nr_executed && !ata_port_is_frozen(ap))
return 0;
/* fail and let EH retry once more for unknown IO errors */
@@ -1007,7 +1007,7 @@ int ata_acpi_on_devcfg(struct ata_device *dev)
/* We can safely continue if no _GTF command has been executed
* and port is not frozen.
*/
- if (!nr_executed && !(ap->pflags & ATA_PFLAG_FROZEN))
+ if (!nr_executed && !ata_port_is_frozen(ap))
return 0;
return rc;