xdr_encode_opaque(9)
πΈ xdr_encode_opaque(9) πΈ
okay so bestie, welcome to the xdr_encode_opaque(9) page β this is a Kernel API Manual moment, and we're about to make variable-length opaque data encoding make sense, no cap π
β¨ NAME β¨
xdr_encode_opaque β encode variable length opaque data π
π¦ SYNOPSIS π¦
__be32 * xdr_encode_opaque (__be32 *p , const void *ptr , unsigned int nbytes );
like, that's the whole signature. read it, love it, memorize it π
πΈ ARGUMENTS πΈ
pβ pointer to the current position in the XDR buffer. that's your little cursor bestie, she knows where we are πptrβ pointer to the data you wanna encode (orNULL, which is totally valid, we don't judge π)nbytesβ the size of the data. how many bytes we're working with, periodt π
π DESCRIPTION π
Returns the updated current XDR buffer position.
that's it. that's the whole vibe. it hands you back where you are now in the XDR buffer after the encode happens, so you can keep going and not lose your place π«Ά literally the main character of "where was I again" energy β¨
π SEE ALSO π
kernel file ./net/sunrpc/xdr.c β the source of truth, go read her π
and then the whole friend group, in order, because we don't leave anyone out:
xdr_encode_opaque_fixed(9)xdr_terminate_string(9)xdr_buf_to_bvec(9)xdr_buf_to_sg(9)xdr_buf_to_sg_alloc(9)xdr_inline_pages(9)_shift_data_left_pages(9)_shift_data_right_pages(9)_copy_to_pages(9)_copy_from_pages(9)xdr_buf_pages_zero(9)xdr_shrink_bufhead(9)xdr_shrink_pagelen(9)xdr_stream_pos(9)xdr_page_pos(9)xdr_init_encode(9)xdr_init_encode_pages(9)__xdr_commit_encode(9)xdr_reserve_space(9)xdr_reserve_space_vec(9)xdr_truncate_encode(9)xdr_truncate_decode(9)xdr_restrict_buflen(9)xdr_write_pages(9)xdr_init_decode(9)xdr_init_decode_pages(9)xdr_finish_decode(9)xdr_inline_decode(9)xdr_read_pages(9)xdr_set_pagelen(9)xdr_enter_page(9)xdr_buf_subsegment(9)xdr_stream_subsegment(9)xdr_stream_move_subsegment(9)xdr_stream_zero(9)xdr_buf_trim(9)xdr_stream_decode_string_dup(9)xdr_stream_decode_opaque_auth(9)xdr_stream_encode_opaque_auth(9)
like, that's the entire group chat. every single one. iykyk π π₯
ngl bestie, this page is short but she's iconic. small, powerful, and she returns your buffer position so you never get lost. ate and left no crumbs π
and that's the tea π§ source is ./net/sunrpc, version date October 2026, and this little manual page will be here whenever you need her. mwah ππ
π¦ 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