RPMA_MR_GET_DESCRIPTOR_SIZE(3)
π rpma_mr_get_descriptor_size(3) π
okay so bestie, welcome to the RPMA Programmer's Manual β¨ this one's a lil baby page but it's important, i promise. it's giving "short but essential" and honestly? we love that for us. π«Ά
πΈ NAME πΈ
rpma_mr_get_descriptor_size β get the size of the memory region descriptor, that's it, that's the whole job π
β¨ SYNOPSIS β¨
#include <librpma.h>
struct rpma_mr_local;
int rpma_mr_get_descriptor_size(const struct rpma_mr_local *mr, size_t *desc_size);
like yes, that's the whole thing. two lines of actual code. iconic behaviour, no notes. π
π¦ DESCRIPTION π¦
so rpma_mr_get_descriptor_size() does exactly one thing and it does it well: it gets the size of the memory region descriptor. that's the vibe. that's the assignment. it ate and left no crumbs. π
no cap, that's genuinely it β you hand it a memory region, it tells you how big the descriptor for that memory region is. main character energy for a function that literally just reports a number. β
π RETURN VALUE π
- on success?
rpma_mr_get_descriptor_size()returns0. slay. β - on failure? it returns a negative error code. π
- and this is the important part bestie, listen: on failure it does not set the
*desc_sizevalue. like, at all. so don't go reading that variable expecting truth, because you will get played. π
fr fr, if this function fails, *desc_size is not yours to trust. guard your heart (and your pointers).
π ERRORS π
rpma_mr_get_descriptor_size() can fail with the following error:
RPMA_E_INVALβmrordesc_sizeisNULL. yeah. you gotta actually give it real things to work with, bestie. passingNULLis not the moment. π
π SEE ALSO π
rpma_mr_get_descriptor(3)rpma_mr_reg(3)librpma(7)- and the whole lore lives at https://pmem.io/rpma/ π§
okay bye ily, this page is from the RPMA era, dated 01 April 2024 π go forth and get those descriptor sizes, bestie β you're gonna do amazing πβ¨πΈ
π¦ where this page comes from
- ubuntu noble: librpma-dev 1.3.0-2build2 Β· BSD-3
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms