xdr_enter_page(9)
π xdr_enter_page β NAME
okay so this is xdr_enter_page from the Kernel API Manual (section 9, bestie, kernel-land), and what it does is decode data from the XDR page. that's the whole vibe. π¦
β¨ SYNOPSIS β¨
void xdr_enter_page (struct xdr_stream *xdr , unsigned int len );
like, it returns void, it takes two things, and yes the spacing in that signature is exactly that. no notes. π
πΈ ARGUMENTS πΈ
xdrβ pointer toxdr_streamstruct. your stream, your main character. πlenβ number of bytes of page data. the count. the amount. thelen. β¨
π DESCRIPTION π
okay so here's the tea π β this function moves data beyond the current pointer position from the XDR head[] buffer into the page list. the way that works is genuinely iconic.
any data that lies beyond current position + len bytes gets moved into the XDR tail[]. that's the overflow, that's the leftovers, and it's handled. π«Ά
and then, after all that shuffling, the current pointer is repositioned at the beginning of the first XDR page. tadah. slay. π
fr fr this is all about the pointer going from the head buffer to the pages, with the tail catching whatever doesn't fit before position + len. no cap. π₯
π¦ SEE ALSO π¦
the whole friend group, iykyk π β and yes, the kernel file itself lives at ./net/sunrpc/xdr.c:
xdr_encode_opaque_fixed(9)xdr_encode_opaque(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_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)
and that's the page!! π§ mwah π β this one ships out of ./net/sunrpc and it's dated October 2026, so like, future-coded but make it kernel. βπ
π¦ 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