STRUCT SMP2P_ENTRY(9)
π NAME π
okay so this is struct smp2p_entry(9) from the Kernel API Manual, and it is literally about driver context matching one entry β one entry, one context, and we are obsessed π«Άβ¨
π SYNOPSIS π
here's the exact struct, bestie β no cap, character for character:
struct smp2p_entry {
struct list_head node;
struct qcom_smp2p *smp2p;
const char *name;
u32 *value;
u32 last_value;
struct irq_domain *domain;
unsigned long irq_enabled[BITS_TO_LONGS( 32)];
unsigned long irq_rising[BITS_TO_LONGS( 32)];
unsigned long irq_falling[BITS_TO_LONGS( 32)];
struct qcom_smem_state *state;
spinlock_t lock;
};
π Members π
nodeβ list entry to keep track of allocated entries. it's the list-link bestie that keeps tabs on what's been allocated πΈsmp2pβ reference to the device driver context. just a little reference back to the driver's whole situation, iykyk πnameβ name of the entry, to match againstsmp2p_smem_item. it's the name tag for the matching game, periodt β¨valueβ pointer tosmp2p_smem_itementry value. yes, literally that pointer πlast_valueβ last handled value. the previous value we already handled, got it.domainβirq_domainfor inbound entries. inbound IRQ business, slay βirq_enabledβ bitmap to track enabled irq bits. it's giving "who's enabled" energy πirq_risingβ bitmap to mark irq bits for rising detection. rising-edge detection bookkeeping, fr fr πirq_fallingβ bitmap to mark irq bits for falling detection. falling-edge detection bookkeeping, iconic π¦stateβ smem state handle. handle to the smem state, okay? πlockβ spinlock to protect read-modify-write of the value. this is the important one: lock it down while doing the read-modify-write dance π
π SEE ALSO π
Kernel file ./drivers/soc/qcom/smp2p.c struct smp2p_smem_item(9), struct qcom_smp2p(9), qcom_smp2p_intr(9) β go read those too, bestie π
this gem ships from ./drivers/soc/qcom, dated October 2026, and yes it's still struct smp2p_entry(9) at the bottom β mwah, periodt ππ
π¦ 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