STRUCT MAX1363_STATE(9)
π struct max1363_state(9) π
okay bestie, welcome to the Kernel API Manual β¨ β we're looking at struct max1363_state, which is literally the driver instance specific data. no cap, this is the little state blob that holds everything the max1363 driver needs to remember about you (well, about your chip) π«Ά
πΈ NAME πΈ
struct max1363_state β driver instance specific data π
(that's the whole name section, she's short but she ate)
β¨ SYNOPSIS β¨
struct max1363_state {
struct i2c_client *client;
u8 setupbyte;
u8 configbyte;
const struct max1363_chip_info *chip_info;
const struct max1363_mode *current_mode;
struct mutex lock;
bool monitor_on;
unsigned int monitor_speed:3;
u8 mask_high;
u8 mask_low;
s16 thresh_high[8];
s16 thresh_low[8];
struct regulator *vref;
u32 vref_uv;
int (*send)(const struct i2c_client *client, const char *buf, int
count);
int (*recv)(const struct i2c_client *client, char *buf, int count);
struct {
u8 buf[MAX1363_MAX_CHANNELS * 2];
aligned_s64 ts;
} data;
};
like, look at her. she's giving struct. she's giving fields. main character energy fr fr π
π Members π
every single field, bestie, we are NOT skipping anyone π
clientβ thei2c_client, obviously πββοΈ that's the i2c side of the relationshipsetupbyteβ cache of current device setup byte (yes, we cache it, we're organized)configbyteβ cache of current device config byte (matching energy β¨)chip_infoβ chip model specific constants, available modes, etc. β basically the chip's whole personalitycurrent_modeβ the scan mode of this chip πlockβ the lock to ensure state is consistent. she's the bouncer at the club, nobody gets in without her πmonitor_onβ whether monitor mode is enabled π (true/false, iconic behaviour)monitor_speedβ parameter corresponding to device monitor speed setting ποΈmask_highβ bitmask for enabled high thresholdsmask_lowβ bitmask for enabled low thresholdsthresh_highβ high threshold values πthresh_lowβ low threshold values πvrefβ Reference voltage regulator β‘vref_uvβ Actual (external or internal) reference voltage β actual, not fake, no capsendβ function used to send data to the chip π€recvβ function used to receive data from the chip π₯dataβ buffer to store channel data and timestamp π (that's theu8 buf[MAX1363_MAX_CHANNELS * 2];plusaligned_s64 ts;combo, she's a nested struct and she's thriving)
not me listing every field with love and care π that's literally the whole point though. the vibes change, the facts do not. periodt π
π¦ SEE ALSO π¦
- Kernel file
./drivers/iio/adc/max1363.cβ the source of truth, go read her π struct max1363_mode(9)πΈstruct max1363_chip_info(9)β¨
go look at these, iykyk π
okay that's the whole page bestie, you're now officially educated πβ¨
this iconic little number came to you from ./drivers/iio/adc, dated October 2026 β mwah, take care, drink water, and go read max1363.c π«Άπ
π
π¦ 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