From: Chuck Lever <cel@kernel.org>
To: NeilBrown <neil@brown.name>, Jeff Layton <jlayton@kernel.org>,
Olga Kornievskaia <okorniev@redhat.com>,
Dai Ngo <dai.ngo@oracle.com>, Tom Talpey <tom@talpey.com>
Cc: <linux-nfs@vger.kernel.org>
Subject: [PATCH 4/5] xdrgen: Add XDR width macros for short integer types
Date: Sun, 12 Jul 2026 15:31:21 -0400 [thread overview]
Message-ID: <20260712193122.116845-5-cel@kernel.org> (raw)
In-Reply-To: <20260712193122.116845-1-cel@kernel.org>
Commit ae78eb497868 ("xdrgen: Implement short (16-bit) integer
types") taught the generator to emit XDR_short and
XDR_unsigned_short in the computed maxsize macros and added the
matching encode and decode primitives to _builtins.h, but it left
the two width macros themselves undefined in _defs.h.
Define XDR_short and XDR_unsigned_short, each one XDR unit wide, to
match the width the generator's maxsize table assigns them.
Fixes: ae78eb497868 ("xdrgen: Implement short (16-bit) integer types")
Signed-off-by: Chuck Lever <cel@kernel.org>
---
include/linux/sunrpc/xdrgen/_defs.h | 2 ++
1 file changed, 2 insertions(+)
diff --git a/include/linux/sunrpc/xdrgen/_defs.h b/include/linux/sunrpc/xdrgen/_defs.h
index 20c7270aa64d..8f3776ef3229 100644
--- a/include/linux/sunrpc/xdrgen/_defs.h
+++ b/include/linux/sunrpc/xdrgen/_defs.h
@@ -25,6 +25,8 @@ typedef struct {
#define XDR_void (0)
#define XDR_bool (1)
+#define XDR_short (1)
+#define XDR_unsigned_short (1)
#define XDR_int (1)
#define XDR_unsigned_int (1)
#define XDR_long (1)
--
2.54.0
next prev parent reply other threads:[~2026-07-12 19:31 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-12 19:31 [PATCH 0/5] Minor fixes for xdrgen Chuck Lever
2026-07-12 19:31 ` [PATCH 1/5] xdrgen: Emit a blank line ahead of enum declarations Chuck Lever
2026-07-12 19:31 ` [PATCH 2/5] xdrgen: Share void RPC procedure handlers across programs Chuck Lever
2026-07-12 19:31 ` [PATCH 3/5] xdrgen: Do not declare union XDR functions in the definitions header Chuck Lever
2026-07-12 19:31 ` Chuck Lever [this message]
2026-07-12 19:31 ` [PATCH 5/5] xdrgen: Fix opaque and string encoders for unbounded members Chuck Lever
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=20260712193122.116845-5-cel@kernel.org \
--to=cel@kernel.org \
--cc=dai.ngo@oracle.com \
--cc=jlayton@kernel.org \
--cc=linux-nfs@vger.kernel.org \
--cc=neil@brown.name \
--cc=okorniev@redhat.com \
--cc=tom@talpey.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