__ssp_receive_char(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– __ssp_receive_char (9) β€” the Kernel API Manual, bestie edition πŸ’–

okay so you found your way into the kernel API manual, section 9, and the star of the show today is __ssp_receive_char πŸ’… this is a page from the Kernel API Manual, and honestly? she's a little one-byte girlboss and we're obsessed.


✨ NAME ✨

__ssp_receive_char β€” receive a byte from the UART πŸŽ€

like, one (1) single byte. she's not greedy. she's not doing the whole buffer. that's somebody else's job (see: SEE ALSO, where the whole friend group lives).


🌸 SYNOPSIS 🌸

char __ssp_receive_char (struct sifive_serial_port *ssp , char *is_empty
);

that's the whole vibe check right there. she takes two things and hands you back a char. periodt.


πŸ¦‹ ARGUMENTS πŸ¦‹

  • ssp β€” pointer to a struct sifive_serial_port 🫢 this is your little handle on the SiFive serial port, she's the plug, she's the connect.
  • is_empty β€” char pointer to return whether the RX FIFO is empty ⭐ it's an out-param, so you pass the address and let her write the answer in for you. no cap, you don't get to know from the return value alone.

πŸ’œ DESCRIPTION πŸ’œ

So here's the whole thing, bestie: she tries to read a byte from the SiFive UART RX FIFO, the one referenced by ssp, and she returns that byte. main character behavior honestly.

She also returns the RX FIFO empty bit in the char pointed to by ch β€” and yeah, ngl, the page says ch here even though the argument is named is_empty up in ARGUMENTS 😭 the docs are being a little quirky, we love her anyway, don't @ me.

🚨 important one, don't skip it: the caller must pass the byte back to the Linux serial layer if needed. she hands you the byte, but she does not file the paperwork. that's on you. iykyk.

πŸ”₯ RETURN πŸ”₯

the byte read from the UART RX FIFO. ✨ that's it, that's the return value. one byte, served fresh, no drama. πŸ’…


🌈 SEE ALSO 🌈

okay this is the whole group chat, and yes we're tagging everyone πŸ’–


πŸŽ€ tiny reminder before you go: everything above is literally straight from the page, so if you're holding the byte, you're holding the responsibility. slay responsibly. 🫢

k bye, go read your UART πŸ’œ


✿ that's the whole page, bestie ✿ straight from ./drivers/tty/serial, stamped October 2026, and yeah β€” __ssp_receive_char(9) is the one and only. mwah πŸ’‹πŸŽ€πŸ’–

πŸ“¦ where this page comes from