STRUCT GPIO_EXTCON_DATA(9)
π struct gpio_extcon_data(9) β like, the whole vibe
okay bestie, welcome to the Kernel API Manual entry for struct gpio_extcon_data β no cap, it's just a lil container that holds the state for a super simple, GPIO-controlled extcon device. that's it. that's the whole thing. slay. β¨
π NAME
struct gpio_extcon_data β a simple GPIO-controlled extcon device state container. literally just a struct whose whole job is holding onto the state of a GPIO-driven external connector. lowkey iconic of it. π
β¨ SYNOPSIS
struct gpio_extcon_data {
struct extcon_dev *edev;
struct delayed_work work;
unsigned long debounce_jiffies;
struct gpio_desc *gpiod;
unsigned int extcon_id;
unsigned long debounce;
bool check_on_resume;
};
yes the indentation in the original is like that, we don't gatekeep. copy it exactly, bestie. π«Ά
πΈ Members
edevβ the extcon device. you know, the actual extcon thang this whole struct is being the state container for. main character energy. πworkβ the work that gets fired by the interrupt. when the IRQ goes off, this is the delayed work that actually does the doing. π₯debounce_jiffiesβ the number of jiffies to wait for the GPIO to stabilize. where does the number come from? thedebouncevalue, obviously. iykyk. β³gpiodβ the GPIO descriptor for this external connector. the actual pin, described. π¦extcon_idβ the unique id of the specific external connector. unique! specific! that's the whole point! πdebounceβ debounce time for the GPIO IRQ, measured in ms. milliseconds, not jiffies, don't mix them up bestie, that's how you get a vibe check failure. πcheck_on_resumeβ a boolean describing whether to check the state of the gpio while resuming from sleep. true = yes check it, false = don't. that's it. π
π SEE ALSO
- Kernel file
./drivers/extcon/extcon-gpio.cβ go read it, it's right there, it's giving source code realness. π
k bye ily π this page came out of ./drivers/extcon, dated October 2026, straight from the Kernel API Manual β and honestly? she ate. βπ§π
π¦ 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