regmap_noinc_read(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… regmap_noinc_read(9) β€” the "read but don't increment, bestie" situation

okay so real talk, this one lives in the Kernel API Manual and it is genuinely niche but SO useful, iykyk πŸ¦‹


✨ NAME ✨

regmap_noinc_read β€” read data from a register without incrementing the register number, no cap πŸ’…


🌸 SYNOPSIS 🌸

int regmap_noinc_read (struct regmap *map , unsigned int reg , void *val
, size_t val_len );

like yes girl, that's the whole signature, copy it exactly please πŸŽ€


πŸŽ€ ARGUMENTS πŸŽ€

  • map β€” the register map you're reading from. your little regmap boy πŸ’–
  • reg β€” the register to read from. the specific one. not the next one. we're not incrementing, remember 😌
  • val β€” pointer to your data buffer. where the good stuff lands ✨
  • val_len β€” length of that output buffer, in bytes. fr fr, in bytes 🌈

πŸ¦‹ DESCRIPTION πŸ¦‹

okay so here's the lore. the regmap API usually assumes that bulk read operations read a range of registers β€” like, read one, next one, next one, weeeee. standard behaviour πŸ’«

but some devices have certain registers where a read operation will read from an internal FIFO instead. the way that changes everything 😭 so this function is for those iconique weirdo registers.

the target register must be volatile β€” that's non-negotiable, bestie. but here's the slay part: registers after it can be completely unrelated cacheable registers. they don't have to match, they don't have to follow. no strings attached 🫢

this will attempt multiple reads as required to read val_len bytes. so you ask for a length, it keeps going till it's done πŸ‘‘

returns a value of zero on success, and a negative errno in error cases. periodt πŸ’€


🌟 SEE ALSO 🌟

also the kernel file lives at ./drivers/base/regmap/regmap.c β€” go look if you're curious 🧚


and that's the whole page, bestie 🫢 this one's from the kernel file <code>./drivers/base/regmap</code>, dated <strong>October 2026</strong> β€” go off, read your FIFO, don't increment anything πŸ’œβœ¨

πŸ“¦ where this page comes from