xdr_stream_decode_u32(9)
π xdr_stream_decode_u32 β the kernel API manual, bestie edition
Okay so real talk: this page is all about xdr_stream_decode_u32(9), a lil kernel function that pulls a 32-bit integer out of an XDR stream. That's it. That's the whole vibe. Slay. π
β¨ SYNOPSIS β¨
ssize_t xdr_stream_decode_u32 (struct xdr_stream *xdr , __u32 *ptr );
That's the whole signature, no cap β it hands you back an ssize_t, takes a pointer to your xdr_stream, and a spot to drop the number. π«Ά
πΈ ARGUMENTS πΈ
xdrβ pointer to thexdr_stream. This is the stream bestie, the main character, the thing you're reading from.ptrβ location to store the integer. Yes queen, this is where the decoded 32-bit number goes. π
β RETURN β
0on success. Iconic, flawless, no notes. π-EBADMSGon XDR buffer overflow. Yeah that's the vibe check failing β your buffer ran out, and the kernel is telling you about it very directly. π
π₯ SEE ALSO π₯
Everything lives in the kernel file ./include/linux/sunrpc/xdr.h β that's the mothership. And here is the entire friend group, alphabetically-ish and in order, no skips, no cap, fr fr:
xdr_set_scratch_buffer(9)xdr_set_scratch_folio(9)xdr_reset_scratch_buffer(9)xdr_commit_encode(9)xdr_stream_remaining(9)xdr_align_size(9)xdr_pad_size(9)xdr_stream_encode_item_present(9)xdr_stream_encode_item_absent(9)xdr_encode_bool(9)xdr_stream_encode_bool(9)xdr_stream_encode_u32(9)xdr_stream_encode_be32(9)xdr_stream_encode_u64(9)xdr_stream_encode_opaque_inline(9)xdr_stream_encode_opaque_fixed(9)xdr_stream_encode_opaque(9)xdr_stream_encode_uint32_array(9)xdr_item_is_absent(9)xdr_item_is_present(9)xdr_stream_decode_bool(9)xdr_stream_decode_be32(9)xdr_stream_decode_u64(9)xdr_stream_decode_opaque_fixed(9)xdr_stream_decode_opaque_inline(9)xdr_stream_decode_uint32_array(9)
Likeβ¦ go read those too, they're literally all cousins of this function. Go off. π
π and that's the page, bestie π
Shoutout to the source <pink>./include/linux/sunrpc</pink> and the date stamp <purple>October 2026</purple> β that's the era this page is serving, and honestly? Ate. π¦β¨
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms