STRUCT PM8XXX_CHAN_INFO(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ struct pm8xxx_chan_info(9) ✨

Hey bestie, welcome to the Kernel API Manual πŸ’– this one's about struct pm8xxx_chan_info, which is literally the ADC channel information glow-up you didn't know you needed. Sit down, grab a strawberry πŸ“, let's get into it.


🌸 NAME 🌸

struct pm8xxx_chan_info β€” ADC channel information πŸ’… that's it, that's the whole vibe.


πŸ¦‹ SYNOPSIS πŸ¦‹

struct pm8xxx_chan_info {
    const char *label;
    const struct xoadc_channel *hwchan;
    enum vadc_calibration calibration;
    u8 decimation:2;
    u8 amux_ip_rsv:3;
 };

okay so it's giving five fields, one struct, zero drama ✨ copy it exactly, no cap, don't be out here renaming stuff πŸ™ˆ


πŸŽ€ Members πŸŽ€

Here's the breakdown of every single member, because we do not skip details in this house πŸ‘‘

  • label β€” the label of this channel, straight from the device tree 🌳 and if you didn't specify one? it defaults to the datasheet name, bestie, it's got you covered 🫢
  • hwchan β€” a pointer to the hardware channel information, aka the muxing & scaling settings πŸ”₯ this is where the actual hardware tea lives
  • calibration β€” tells you whether to use absolute or ratiometric calibration ⭐ pick your fighter
  • decimation β€” the valid values are 0, 1, 2, 3 🎚️ literally just those four, iconic
  • amux_ip_rsv β€” the ratiometric scale value, but only if you're using ratiometric calibration πŸ’€ the values are 0, 1, 2, 4, 5 (yes, 3 is missing, don't come for me, that's just what it says πŸ™ˆ)

πŸ’œ SEE ALSO πŸ’œ

Go read these next, iykyk πŸ“š:

  • Kernel file ./drivers/iio/adc/qcom-pm8xxx-xoadc.c
  • struct xoadc_channel(9)
  • struct xoadc_variant(9)
  • struct pm8xxx_xoadc(9)

and that's the whole page, bestie πŸ¦‹ slay, you ate πŸ’…

sign-off vibes: this little masterpiece lives in ./drivers/iio/adc and it's dated October 2026 πŸŽ€ periodt ✨

πŸ“¦ where this page comes from