STRUCT RMI_FUNCTION_HANDLER(9)
β¨ struct rmi_function_handler(9) β¨
okay so bestie, welcome to the struct rmi_function_handler glow-up π
this is a Kernel API Manual situation, and it's literally the driver routines for a particular RMI function β like, one function, one handler, main character energy only π
πΈ NAME πΈ
struct rmi_function_handler β driver routines for a particular RMI function, periodt.
π SYNOPSIS π
struct rmi_function_handler {
struct device_driver driver;
u8 func;
int (*probe)(struct rmi_function *fn);
void (*remove)(struct rmi_function *fn);
int (*config)(struct rmi_function *fn);
int (*reset)(struct rmi_function *fn);
irqreturn_t (*attention)(int irq, void *ctx);
int (*suspend)(struct rmi_function *fn);
int (*resume)(struct rmi_function *fn);
};
no cap, that's the whole struct, copy it exactly, don't get creative with it π
π¦ Members π¦
so here's the cast of callbacks, and honestly? every one of them ate:
funcβ the RMI function number. that's it, that's the whole vibe check πconfigβ gets called when the function container is first initialized, and again after a reset is detected. this routine should write any necessary configuration settings to the device. basically: set it up, then set it up again if the world ends πresetβ called when a reset of the touch sensor is detected. this routine should perform any out-of-the-ordinary reset handling that might be necessary. and lowkey important: restoring of touch sensor configuration registers should be handled in theconfigcallback, below. not here. iykyk π«Άattentionβ called when the IRQ(s) for the function are set by the touch sensor. she's the one who answers the phone βοΈβ¨suspendβ should perform any required operations to suspend the particular function π΄resumeβ should perform any required operations to resume the particular function π
ngl bestie,probeandremoveare right there in the struct too β they're part of the whole package even though this list doesn't give them their own lil paragraph π
β Description β
all callbacks are expected to return 0 on success, error code on failure. that's the rule, no exceptions, fr fr π₯
π SEE ALSO π
- Kernel file
./drivers/input/rmi4/rmi_bus.hstruct rmi_function(9) rmi_reset(9)rmi_read(9)rmi_read_block(9)rmi_write(9)rmi_write_block(9)
go read those, they're iconic π
and that's the page!! courtesy of ./drivers/input/rmi4, dated October 2026, and yes she's still signing off as struct rmi_function_handler(9) because consistency is a love language ππ·
π¦ 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