diff options
author | Niklas Cassel <niklas.cassel@wdc.com> | 2022-10-07 15:23:37 +0200 |
---|---|---|
committer | Damien Le Moal <damien.lemoal@opensource.wdc.com> | 2022-10-18 13:53:24 +0900 |
commit | fddb1a6424787d8089a9032bd5d21c428670f854 (patch) | |
tree | 56765c7a4f109ad984b70321808388b3aaa61aa2 /include/linux/libata.h | |
parent | dc62c7e6ed5351058bbb57495e73fa6b3757587a (diff) | |
download | linux-fddb1a6424787d8089a9032bd5d21c428670f854.tar.gz linux-fddb1a6424787d8089a9032bd5d21c428670f854.tar.bz2 linux-fddb1a6424787d8089a9032bd5d21c428670f854.zip |
ata: add ata_port_is_frozen() helper
At the request of the libata maintainer, introduce a 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 'include/linux/libata.h')
-rw-r--r-- | include/linux/libata.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/include/linux/libata.h b/include/linux/libata.h index fe990176e6ee..af4953b95f76 100644 --- a/include/linux/libata.h +++ b/include/linux/libata.h @@ -1043,6 +1043,11 @@ static inline int ata_port_is_dummy(struct ata_port *ap) return ap->ops == &ata_dummy_port_ops; } +static inline bool ata_port_is_frozen(const struct ata_port *ap) +{ + return ap->pflags & ATA_PFLAG_FROZEN; +} + extern int ata_std_prereset(struct ata_link *link, unsigned long deadline); extern int ata_wait_after_reset(struct ata_link *link, unsigned long deadline, int (*check_ready)(struct ata_link *link)); |