diff options
| author | Damien Le Moal <dlemoal@kernel.org> | 2026-06-20 20:44:43 +0900 |
|---|---|---|
| committer | Damien Le Moal <dlemoal@kernel.org> | 2026-07-18 10:09:10 +0900 |
| commit | 1e307ca61a9cdd8c3b721577e4889c47816654d8 (patch) | |
| tree | ef2dc2a06742fc3aa787db0de9196e9b071f512e /include/linux/ata.h | |
| parent | db496721cb0d369f34d7e0bf66692b050e2b6ff8 (diff) | |
ata: libata-scsi: add support for the RESTORE ELEMENTS AND REBUILD command
Define the translation for the RESTORE ELEMENTS AND REBUILD command
(SERVICE ACTION IN command with service action
SAI_RESTORE_ELEMENTS_AND_REBUILD) into the ATA command
ATA_CMD_RESTORE_ELEMENTS_AND_REBUILD with the new function
ata_scsi_restore_elements_and_rebuild_xlat()
The array of supported commands ata_supported_cmds is modified to add a
new entry for this command. ata_scsi_cmd_is_supported() is also modify to
correctly handle this new entry depending on the target device flag
ATA_DFLAG_DEPOP_RESTORE being set.
The ATA command completion is handled using the function
ata_scsi_depop_ua_cap_changed_complete() so that on a successful
completion, a UNIT ATTENTION with the additional sense code set to
CAPACITY DATA HAS CHANGED is raised.
Signed-off-by: Damien Le Moal <dlemoal@kernel.org>
Reviewed-by: Martin K. Petersen <martin.petersen@oracle.com>
Reviewed-by: Hannes Reinecke <hare@kernel.org>
Diffstat (limited to 'include/linux/ata.h')
| -rw-r--r-- | include/linux/ata.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/ata.h b/include/linux/ata.h index 89ac27743f50..a1cd68cfb44f 100644 --- a/include/linux/ata.h +++ b/include/linux/ata.h @@ -291,6 +291,7 @@ enum { ATA_CMD_ZAC_MGMT_OUT = 0x9F, ATA_CMD_GET_PHYS_ELEMENT_STATUS = 0x12, ATA_CMD_REMOVE_ELEMENT_AND_TRUNCATE = 0x7c, + ATA_CMD_RESTORE_ELEMENTS_AND_REBUILD = 0x7d, /* marked obsolete in the ATA/ATAPI-7 spec */ ATA_CMD_RESTORE = 0x10, |
