mbox series

[0/3] block: expose 'read_keys' and 'read_reservation' PR callbacks

Message ID 20250603100416.131490-1-hare@kernel.org
Headers show
Series block: expose 'read_keys' and 'read_reservation' PR callbacks | expand

Message

Hannes Reinecke June 3, 2025, 10:04 a.m. UTC
Hi all,

the generic persistent reservation framework already has callbacks for 'read_keys'
and 'read_reservation', but these callbacks are not exposed via ioctls (unlike
the other callbacks). As we need this information if we want to work with persistent
reservations reliably add two new persistent reservation ioctls 'IOC_PR_READ_KEYS'
and 'IOC_PR_READ_RESV' to expose this information to userspace.

As usual, comments and reviews are welcome.

Hannes Reinecke (3):
  block: add 'read_keys' persistent reservation ioctl
  block: add 'read_reservation' persistent reservation ioctl
  scsi: return PR generation if no reservation is held

 block/ioctl.c           | 61 +++++++++++++++++++++++++++++++++++++++++
 drivers/scsi/sd.c       | 10 +++++--
 include/linux/pr.h      | 12 --------
 include/uapi/linux/pr.h | 14 ++++++++++
 4 files changed, 82 insertions(+), 15 deletions(-)