cros_ec_sen...til_not_busy(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– cros_ec_sen...til_not_busy(9) β€” a Kernel API Manual moment πŸ’–

okay so bestie, welcome to section 9 of the Kernel API Manual, where we talk about cros_ec_sen...til_not_busy (yes the title is doing the whole truncated-name thing, she's mysterious like that ✨). this one is a function page and it's lowkey iconic for how much it does with so little.


🌸 NAME 🌸

cros_ec_sensors_read_until_not_busy β€” literally just read until is not busy. that's it. that's the whole vibe. she reads, she waits, she stops when the busy-ness is over πŸŽ€


πŸ¦‹ SYNOPSIS πŸ¦‹

int cros_ec_sensors_read_until_not_busy (struct
cros_ec_sensors_core_state *st );

so she takes one argument, returns an int, and her whole personality is in that name fr fr πŸ’…


✨ ARGUMENTS ✨

  • st β€” pointer to state information for device. that's your state bestie, the struct cros_ec_sensors_core_state * of it all. she holds the info, you hold the pointer, everybody slays 🫢

πŸ’œ DESCRIPTION πŸ’œ

Read from EC status byte until it reads not busy. πŸ”₯

that's the whole bit β€” she keeps reading the status byte and reading the status byte and reading the status byte until the answer comes back not busy. no cap, that's the entire loop energy. she is patient. she is persistent. she is not leaving until that byte says what she needs to hear πŸ˜­πŸ’€


🌈 RETURN 🌈

  • 8-bit status if ok β€” a little status snack, 8 bits of success πŸ‘‘
  • -errno on failure β€” things went sideways, and the errno tells you how πŸ™ˆ

⭐ SEE ALSO ⭐

okay this section is a whole group chat, like she has so many friends, i'm obsessed:


ngl if you're calling this in a hot loop, may the busy bit clear fast and may your errno stay unset πŸ§šπŸ“

and that's the page!! this cutie lives over at ./drivers/iio/common/cros_ec_s..., the file date is October 2026, and she's still serving cros_ec_sen...til_not_busy(9) realness. mwah, that's a wrap πŸ’‹πŸ’–βœ¨

πŸ“¦ where this page comes from