__xa_store(9)
β¨ __xa_store(9) β the Kernel API Manual glow-up β¨
okay so bestie, welcome to the __xa_store(9) page from the Kernel API Manual π
this is the one that literally puts your entry into the XArray, and yes she has rules. buckle up π
πΈ NAME πΈ
__xa_store β Store this entry in the XArray. periodt β¨
π¦ SYNOPSIS π¦
void * __xa_store (struct xarray *xa , unsigned long index , void *entry
, gfp_t gfp );
π ARGUMENTS π
xaβ your XArray. the main character fr πindexβ the index into that array. like, where in the array, yk? πentryβ the new entry. the newbie. the fresh face β¨gfpβ memory allocation flags. lowkey important, don't skip her π
πΌ DESCRIPTION πΌ
okay so HARD REQUIREMENT first: you must already be holding the xa_lock when you call this function. no cap, that's the deal π
and then β plot twist β she will drop the lock if she needs to allocate memory, and then reacquire it afterwards. so yeah, she's a little dramatic, but she comes back π«Ά
π§ CONTEXT π§
Any context, bestie. any. π«
she expects xa_lock to be held on entry, and she may release and reacquire xa_lock if the gfp flags permit. that's the whole vibe check β
β RETURN β
she hands you back the old entry at this index, or xa_err if something went wrong π (so like, check for the error, bestie, please π)
π SEE ALSO π
all her friends, in the kernel file ./lib/xarray.c β icon behavior only π
xas_load(9)xas_nomem(9)xas_free_nodes(9)xas_create_range(9)xas_store(9)xas_get_mark(9)xas_set_mark(9)xas_clear_mark(9)xas_init_marks(9)xas_split_alloc(9)xas_split(9)xas_try_split_min_order(9)xas_try_split(9)xas_pause(9)xas_find(9)xas_find_marked(9)xas_find_conflict(9)xa_load(9)__xa_erase(9)xa_erase(9)xa_store(9)__xa_cmpxchg(9)__xa_insert(9)xa_store_range(9)xas_get_order(9)xa_get_order(9)__xa_alloc(9)__xa_alloc_cyclic(9)__xa_set_mark(9)__xa_clear_mark(9)xa_get_mark(9)xa_set_mark(9)xa_clear_mark(9)xa_find(9)xa_find_after(9)xa_extract(9)xa_delete_node(9)xa_destroy(9)
π reminder bestie: hold xa_lock before you call her, she's not doing the lock acquisition for you, and she might drop it and grab it again mid-call. plan accordingly π«Ά
and that's the whole page, slay π
this came out of ./lib and she's dated October 2026 β stay hydrated, lock your xarray, and go store some entries, bestie πβ¨π
π¦ 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