STRUCT MXS_I2C_DEV(9)
π struct mxs_i2c_dev(9) π
okay bestie, so this is a page from the Kernel API Manual, and it's literally all about struct mxs_i2c_dev β the per-device, private MXS-I2C data. yes, private. it's giving main character energy but for one device only π
β¨ SYNOPSIS β¨
here's the whole struct, exactly as it lives, no cap:
struct mxs_i2c_dev {
struct device *dev;
enum mxs_i2c_devtype dev_type;
void __iomem *regs;
struct completion cmd_complete;
int cmd_err;
struct i2c_adapter adapter;
uint32_t timing0;
uint32_t timing1;
uint32_t timing2;
struct dma_chan *dmach;
uint32_t pio_data[2];
uint32_t addr_data;
struct scatterlist sg_io[2];
bool dma_read;
};
like, look at all those fields. she's structured. she's organized. i'm obsessed π
πΈ Members πΈ
okay so let's go through every single one, because we do NOT skip members in this house:
devβ the driver model device node. it's the device's official little ID card πͺͺdev_typeβ distinguishes i.MX23/i.MX28 features. iykyk which chip you're on β¨regsβ IO registers pointer. literally the pointer to where the registers live πcmd_completeβ completion object for transaction wait. it's the "hold on bestie, i'll let you know when it's done" object π«Άcmd_errβ error code for the last transaction. the receipts for what went wrong last time πadapterβ i2c subsystem adapter node. this is her i2c-subsystem-official era πtiming0β I2C TIMING0 register value. the timing register, but make it 0 β±οΈtiming1β I2C TIMING1 register value. yes, there's a 1, and yes, it also has a value πtiming2β I2C TIMING2 register value. the third one. the trilogy is complete π¬dmachβ DMA channel. the fast lane, channel edition π₯pio_dataβ PIO data for DMA. data for the DMA, via PIO, don't ask me to explain the crossover episode π¦addr_dataβ address data for DMA. address info, but for the DMA πsg_ioβ scatterlist for I/O. it's a scatterlist, and it's for I/O, periodt β¨dma_readβ flag indicating DMA read. a little bool that says "this one's a DMA read" π
ngl every field here is documented in exactly one line and that's the vibe. no extra lore, no invented backstory. we report, we don't speculate π
π SEE ALSO π
- Kernel file
./drivers/i2c/busses/i2c-mxs.cβ go read the actual source, bestie, that's where the plot happens π
and that's the whole page!! mwah π
sign-off time: this came from the Kernel API Manual, source path ./drivers/i2c/busses, dated October 2026, and it's filed under struct mxs_i2c_dev(9). stay slay, stay compiled, and may your transactions always complete πβ¨ππ¦πΈπ
π«Άππβπ
π¦ 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