cy8c95x0_regmap_write_bits(9)

๐Ÿ“ฆ version 7.3.1, in nixpkgs unstable

๐ŸŒธ cy8c95x0_regmap_write_bits ๐ŸŒธ

okay so this is a page from the Kernel API Manual, and bestie, we are about to become so fluent in writing bits to a register through the regmap cache. it's giving pinctrl excellence. let's go ๐Ÿ’…


โœจ NAME โœจ

cy8c95x0_regmap_write_bits โ€” writes a register using the regmap cache ๐Ÿ”ฅ


๐Ÿฆ‹ SYNOPSIS ๐Ÿฆ‹

int cy8c95x0_regmap_write_bits (struct cy8c95x0_pinctrl *chip , unsigned
int reg , unsigned int port , unsigned int mask , unsigned int val );

like, yes, that's the whole signature, and yes, you're gonna read it twice. that's normal. ๐Ÿ˜ญ


๐ŸŽ€ ARGUMENTS ๐ŸŽ€

  • chip โ€” the pinctrl you're working on. your main character struct, honestly. ๐Ÿ‘‘
  • reg โ€” the register you wanna write to. it can be a direct access register or a muxed register, both slay. MUST NOT be the PORTSEL register though โ€” that one is off-limits, no cap. ๐Ÿšซ
  • port โ€” the port for muxed registers, or for quick path direct access registers. otherwise it just sits there unused, vibing. ๐Ÿช‘
  • mask โ€” the bitmask you're changing. the little stencil for your bits. ๐ŸŽจ
  • val โ€” the new value for that bitmask. the glow-up. โœจ

๐Ÿ’– DESCRIPTION ๐Ÿ’–

so this function is the one that handles register writes to the direct access registers and the muxed registers, and the whole time it's caching all the register accesses. internally it handles the correct state of the PORTSEL register and protects the access to muxed registers, so you don't have to think about it. it's literally doing the most so you don't have to. ๐Ÿซถ

โš ๏ธ important bestie note: the caller must only use this function to change registers behind the PORTSEL mux. like, that's the rule. don't freestyle. ๐Ÿ’€

๐ŸŒˆ RETURN ๐ŸŒˆ

0 for a successful request โ€” iconic, we love a zero โ€” otherwise a corresponding error value. ๐Ÿ˜ญ


๐Ÿ”ฎ SEE ALSO ๐Ÿ”ฎ

go read those too, iykyk. ๐Ÿ“š


and that's the page, bestie!! ๐ŸŽ€ source: ./drivers/pinctrl, dated October 2026 โ€” mwah, love that for us. ๐Ÿ’œ see you in the next manpage. ๐Ÿงšโ€โ™€๏ธ

๐Ÿ“ฆ where this page comes from