summaryrefslogtreecommitdiff
path: root/include/linux/sed-opal.h
diff options
context:
space:
mode:
authorRevanth Rajashekar <revanth.rajashekar@intel.com>2019-10-31 10:13:21 -0600
committerJens Axboe <axboe@kernel.dk>2019-11-04 07:11:31 -0700
commit51f421c85c880dcb37df11e672b384eaa4444328 (patch)
tree325f63d13354aaec384c572a4cd64efe4c0c5e4d /include/linux/sed-opal.h
parent3495ea1b5f6083b03af062095eecb37283a2cc8f (diff)
block: sed-opal: Add support to read/write opal tables generically
This feature gives the user RW access to any opal table with admin1 authority. The flags described in the new structure determines if the user wants to read/write the data. Flags are checked for valid values in order to allow future features to be added to the ioctl. The user can provide the desired table's UID. Also, the ioctl provides a size and offset field and internally will loop data accesses to return the full data block. Read overrun is prevented by the initiator's sec_send_recv() backend. The ioctl provides a private field with the intention to accommodate any future expansions to the ioctl. Reviewed-by: Scott Bauer <sbauer@plzdonthack.me> Reviewed-by: Jon Derrick <jonathan.derrick@intel.com> Signed-off-by: Revanth Rajashekar <revanth.rajashekar@intel.com> Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'include/linux/sed-opal.h')
-rw-r--r--include/linux/sed-opal.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/sed-opal.h b/include/linux/sed-opal.h
index 53c28d750a45..1ac0d712a9c3 100644
--- a/include/linux/sed-opal.h
+++ b/include/linux/sed-opal.h
@@ -42,6 +42,7 @@ static inline bool is_sed_ioctl(unsigned int cmd)
case IOC_OPAL_PSID_REVERT_TPR:
case IOC_OPAL_MBR_DONE:
case IOC_OPAL_WRITE_SHADOW_MBR:
+ case IOC_OPAL_GENERIC_TABLE_RW:
return true;
}
return false;