qcom_smem_get(9)
π qcom_smem_get(9) π
okay bestie so this is a page from the Kernel API Manual and it's literally the whole tea on qcom_smem_get β a kernel function that hands you a pointer to a smem item. yes we're doing pointers today, hydrate first π«Ά
β¨ NAME β¨
qcom_smem_get β resolve ptr of size of a smem item
like, you give it the vibe (a host and an item handle) and it gives you back the pointer plus how big the thing actually is. iconic behaviour tbh π
πΈ SYNOPSIS πΈ
void * qcom_smem_get (unsigned int host , unsigned int item , size_t *size );
look at her. three args, one return, zero drama (unless there's an error, then there's a little drama β see RETURN, iykyk) π
π ARGUMENTS π
hostβ the remote processor, or-1. yes literally-1, she's valid, don't come for her πitemβ the smem item handle. this is your ticket to the thing you want π₯sizeβ pointer to be filled out with size of the item. you pass her in empty, she comes back with the size. glow-up β¨
π¦ DESCRIPTION π¦
okay so the whole thing: she looks up the smem item, and returns a pointer to it. that's the main character energy right there π
and the size of the smem item? it gets returned in size β the pointer you handed her. so you're not just getting a ptr, you're getting the measurements too. obsessed π
β RETURN β
a pointer to an SMEM item on success, ERR_PTR on failure π
so likeβ¦ check it. don't just rawdog the dereference, bestie, we've talked about this π
π SEE ALSO π
- Kernel file
./drivers/soc/qcom/smem.c struct smem_proc_comm(9)struct smem_global_entry(9)struct smem_header(9)struct smem_ptable_entry(9)struct smem_ptable(9)struct smem_partition_header(9)struct smem_partition(9)struct smem_private_entry(9)struct smem_info(9)struct smem_region(9)struct qcom_smem(9)qcom_smem_bust_hwspin_lock_by_host(9)qcom_smem_is_available(9)qcom_smem_alloc(9)qcom_smem_get_free_space(9)qcom_smem_virt_to_phys(9)qcom_smem_get_soc_id(9)qcom_smem_get_feature_code(9)
that's a whole friend group fr fr β go say hi to all of them π
no cap: read the RETURN section again. ERR_PTR is real and she will show up. π
k bye bestie, this one lives in ./drivers/soc/qcom and the version vibes are dated October 2026 β go forth and resolve those pointers responsibly π§ββοΈπβ¨
π¦ 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