STRUCT MAX8998_DEV(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… NAME πŸ’…

struct max8998_dev β€” the max8998 master device for sub-drivers, aka the main character that all the little sub-drivers report back to 🫢


✨ SYNOPSIS ✨

struct max8998_dev {
    struct device *dev;
    struct max8998_platform_data *pdata;
    struct i2c_client *i2c;
    struct i2c_client *rtc;
    struct mutex iolock;
    struct mutex irqlock;
    unsigned int irq_base;
    struct irq_domain *irq_domain;
    int irq;
    int ono;
    u8 irq_masks_cur[MAX8998_NUM_IRQ_REGS];
    u8 irq_masks_cache[MAX8998_NUM_IRQ_REGS];
    unsigned long type;
    bool wakeup;
 };

okay bestie, that's the whole struct, copied exactly, no cap πŸ”₯


🌸 Members 🌸

  • dev β€” the master device of the chip, and yes you can use it to get at the platform data πŸ‘‘
  • pdata β€” platform data, shared by the driver and all its subdrivers fr fr
  • i2c β€” i2c client private data for the regulator
  • rtc β€” i2c client private data for the rtc
  • iolock β€” mutex for serializing io access, like a little velvet rope for io πŸŽ€
  • irqlock β€” mutex for the buslock
  • irq_base β€” base IRQ number for max8998, required for IRQs (it's giving mandatory πŸ’€)
  • irq β€” the generic IRQ number for max8998
  • ono β€” the power onoff IRQ number for max8998
  • irq_masks_cur β€” the currently active value
  • irq_masks_cache β€” the cached hardware value
  • type β€” indicates which max8998 "variant" is in use πŸ‘€
little heads up πŸ’–: irq_domain and wakeup are both chillin' in the struct up there in SYNOPSIS, but the Members list doesn't describe them, so we're not gonna make stuff up about them. iykyk.

πŸ¦‹ SEE ALSO πŸ¦‹

  • Kernel file ./include/linux/mfd/max8998-private.h β€” go read it, it's iconic ⭐

and that's the whole page bestie, slay πŸ’… β€” this was struct max8998_dev(9) from the Kernel API Manual, living in ./include/linux/mfd, dated October 2026. periodt πŸŒˆπŸ’œ

πŸ“¦ where this page comes from