Re: [PATCH 3/3] blkpr: add read-reservation command
Karel Zak <[email protected]> Wed, 17 Dec 2025 11:53:46 +0100
| Newsgroups | org.kernel.vger.util-linux |
|---|---|
| Message-ID | <ce5rsy5oycyuyfke6kcyrqokgim3cctjewhuv4gw2ptbkev7zh@ehw77wgurx7y> |
On Thu, Dec 11, 2025 at 11:09:56AM -0500, Stefan Hajnoczi wrote:
>
> diff --git a/meson.build b/meson.build
> index 47b43c2af..b759e992f 100644
> --- a/meson.build
> +++ b/meson.build
> @@ -768,6 +768,9 @@ conf.set('HAVE_DECL_PR_REP_CAPACITY', have ? 1 : false)
> have = cc.has_header_symbol('linux/pr.h', 'IOC_PR_READ_KEYS')
> conf.set('HAVE_DECL_IOC_PR_READ_KEYS', have ? 1 : false)
>
> +have = cc.has_header_symbol('linux/pr.h', 'IOC_PR_READ_RESERVATION')
> +conf.set('HAVE_DECL_IOC_PR_READ_RESERVATION', have ? 1 : false)
It seems you do not need to define HAVE_DECL_IOC_PR_READ_RESERVATION
and care about this in meson.build or configure.ac.
> +#if HAVE_DECL_IOC_PR_READ_RESERVATION
> + {IOC_PR_READ_RESERVATION, "read-reservation",
> + " * read-reservation: This command shows the current reservation.\n"},
> +#endif
I think you can use directly
#ifdef IOC_PR_READ_RESERVATION
#endif
as IOC_PR_READ_RESERVATION is macro in linux/pr.h
Karel
--
Karel Zak <[email protected]>
http://karelzak.blogspot.com