public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
From: Hannes Reinecke <hare@kernel.org>
To: Jens Axboe <axboe@kernel.dk>
Cc: Christoph Hellwig <hch@lst.de>,
	"Martin K. Petersen" <martin.petersen@oracle.com>,
	linux-block@vger.kernel.org, linux-scsi@vger.kernel.org,
	James Bottomley <james.bottomley@hansenpartnership.com>,
	Hannes Reinecke <hare@kernel.org>
Subject: [PATCH 0/3] block: expose 'read_keys' and 'read_reservation' PR callbacks
Date: Tue,  3 Jun 2025 12:04:13 +0200	[thread overview]
Message-ID: <20250603100416.131490-1-hare@kernel.org> (raw)

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(-)

-- 
2.35.3


             reply	other threads:[~2025-06-03 10:06 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-06-03 10:04 Hannes Reinecke [this message]
2025-06-03 10:04 ` [PATCH 1/3] block: add 'read_keys' persistent reservation ioctl Hannes Reinecke
2025-06-03 10:04 ` [PATCH 2/3] block: add 'read_reservation' " Hannes Reinecke
2025-06-03 10:04 ` [PATCH 3/3] scsi: return PR generation if no reservation is held Hannes Reinecke

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250603100416.131490-1-hare@kernel.org \
    --to=hare@kernel.org \
    --cc=axboe@kernel.dk \
    --cc=hch@lst.de \
    --cc=james.bottomley@hansenpartnership.com \
    --cc=linux-block@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=martin.petersen@oracle.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox