adxl313_core_probe(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– NAME πŸ’–

adxl313_core_probe β€” probe and setup for adxl313 accelerometer ✨

okay so real talk, bestie, this page lives in the Kernel API Manual (that's the manual name, keep it in your notes πŸ“), and it's all about getting the adxl313 accelerometer probed and set up. that's the whole vibe. πŸŽ€


🌸 SYNOPSIS 🌸

int adxl313_core_probe (struct device *dev , struct regmap *regmap ,
       const struct adxl313_chip_info *chip_info , int (*setup)(struct device
       *, struct regmap *) );

it's giving "returns an int", it's giving "takes four things". slay. πŸ’…


πŸ¦‹ ARGUMENTS πŸ¦‹

four arguments, no more no less, and we're gonna go through every single one because that's the whole point 🫢

  • dev β€” the driver model representation of the device. like, this is the device's whole identity in the driver model. main character energy fr. πŸ‘‘
  • regmap β€” the register map of the device. this is how you actually talk to the registers, iykyk. 🌈
  • chip_info β€” a structure containing device specific data. that's where the per-chip lore lives. πŸ’œ
  • setup β€” the setup routine to be executed right before the standard device setup. and here's the iconic part: it can also be set to NULL if it's not required. no setup needed? no problem. ✨

⭐ RETURN ⭐

  • 0 on success πŸŽ‰
  • negative errno on error cases 😭

that's it, that's the return contract. zero means we ate, negative means something went sideways. πŸ’€


πŸ”₯ SEE ALSO πŸ”₯

go read those too, bestie, they're literally right there. 🧚


ngl, this page is short but every line is carrying its weight. don't skip the setup argument note about NULL β€” that's the sneaky-but-important detail. πŸ“

okay and finally, the cute little sign-off bit: this whole thing comes to you from ./drivers/iio/accel, dated October 2026, and yes β€” bestie β€” it is adxl313_core_probe(9) all the way down. πŸ¦‹πŸ’– periodt.

πŸ“¦ where this page comes from