STRUCT I2C_MUX_GPIO_PLATFORM_DATA(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– struct i2c_mux_gpio_platform_data β€” NAME πŸ’–

okay so bestie, welcome to struct i2c_mux_gpio_platform_data in the Kernel API Manual (section 9, iykyk) β€” it's literally the platform-dependent data for i2c-mux-gpio. that's it, that's the whole vibe check. she's a carrier struct for the GPIO-driven i2c mux and she's serving ✨


🌸 SYNOPSIS 🌸

here's the whole struct, character for character, no cap:

struct i2c_mux_gpio_platform_data {
    int parent;
    int base_nr;
    const unsigned *values;
    int n_values;
    unsigned idle;
    u32 settle_time;
 };

πŸŽ€ Members πŸŽ€

every single field, explained with love:

  • parent β€” the parent I2C bus adapter number. like, which bus is the mux hanging off of. 🫢
  • base_nr β€” the base I2C bus number to number adapters from, or zero for dynamic. so if you want to decide the numbering yourself, drop it here; if you want the kernel to pick, just hand over a 0 and let her cook. πŸ’…
  • values β€” array of bitmasks of GPIO settings (low/high) for each position. one bitmask per mux position, each bit saying hi or low to a GPIO. obsessed. ✨
  • n_values β€” number of multiplexer positions (busses to instantiate). it's giving headcount for the busses. πŸ¦‹
  • idle β€” bitmask to write to the MUX when idle, or GPIO_I2CMUX_NO_IDLE if it's not used. yeah, that exact symbol, don't get creative with it. πŸ™ˆ
  • settle_time β€” delay to wait when a new bus is selected. muxes need a sec to settle in, same as the rest of us. 😭
ngl this struct is small but she's doing main character energy work β€” mux everything, slay.

πŸ¦‹ SEE ALSO πŸ¦‹

  • Kernel file ./include/linux/platform_data/i2c-mux-gpio.h β€” go read it bestie, it's right there πŸ”₯

this page came from the kernel source under ./include/linux/platform_data, dated October 2026 β€” thanks for coming to my ted talk, mwah πŸ’‹ periodt. πŸŒˆπŸ’œ

πŸ“¦ where this page comes from