]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
ata: libata-sata: Simplify sense_valid fetching
authorNiklas Cassel <cassel@kernel.org>
Wed, 16 Apr 2025 09:31:30 +0000 (11:31 +0200)
committerDamien Le Moal <dlemoal@kernel.org>
Sun, 20 Apr 2025 23:59:00 +0000 (08:59 +0900)
commitf54464458d34141911047258090f25c67204cda4
tree4ac37daab2d52df580658bfb5f876e1687c541b2
parente8866e26f5e8ec551eec73dca1c30d458f9dca86
ata: libata-sata: Simplify sense_valid fetching

While the SENSE DATA VALID field in the ACS-6 specification is 47 bits,
we are currently only fetching 32 bits, because these are the only bits
that we care about (these bits represent the tags (which can be 0-31)).

Thus, replace the existing logic with a simple get_unaligned_le32().

While at it, change the type of sense_valid to u32.

Signed-off-by: Niklas Cassel <cassel@kernel.org>
Reviewed-by: Hannes Reinecke <hare@suse.de>
Reviewed-by: Igor Pylypiv <ipylypiv@google.com>
Signed-off-by: Damien Le Moal <dlemoal@kernel.org>
drivers/ata/libata-sata.c