relay_alloc_buf(9)
π relay_alloc_buf(9) π
okay so welcome to the Kernel API Manual, bestie β this is the relay_alloc_buf(9) entry, and itβs giving βtiny but important allocation moment.β β¨
πΈ NAME πΈ
relay_alloc_buf β allocate a channel buffer. thatβs the whole vibe π
β¨ SYNOPSIS β¨
void * relay_alloc_buf (struct rchan_buf *buf , size_t *size );
π ARGUMENTS π
bufβ the buffer struct. the struct weβre working with, periodt πsizeβ total size of the buffer. total total, not βishβ π
π DESCRIPTION π
Returns a pointer to the resulting buffer, and NULL if unsuccessful. no cap, NULL is the βit didnβt workβ signal π
The passed in size will get page aligned, if it isnβt already. so if itβs already page aligned, iconic; if not, it gets page aligned. thatβs the rule β¨
lowkey important: unsuccessful means you get NULL back β thatβs the failure state, bestie π
π¦ SEE ALSO π¦
Kernel file ./kernel/relay.c β go look at the source, you gorgeous nerd π
relay_mmap_prepare_buf(9)relay_create_buf(9)relay_destroy_channel(9)relay_destroy_buf(9)relay_remove_buf(9)relay_buf_empty(9)relay_buf_full(9)wakeup_readers(9)__relay_reset(9)relay_reset(9)relay_close_buf(9)relay_open(9)relay_switch_subbuf(9)relay_subbufs_consumed(9)relay_close(9)relay_flush(9)relay_stats(9)relay_file_open(9)relay_file_mmap_prepare(9)relay_file_poll(9)relay_file_release(9)relay_file_read_subbuf_avail(9)relay_file_read_start_pos(9)relay_file_read_end_pos(9)
mwah π this page is from ./kernel, dated October 2026, and itβs the relay_alloc_buf(9) manual. bye bestie, go be iconic with your buffers π«Άπ
π¦ 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