read_fifo(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… read_fifo(9) β€” Kernel API Manual, but make it make sense 🫢

okay bestie, so this is read_fifo, a kernel API manual page (9 is the kernel section, iykyk), and it's genuinely so good at what it does. sit down, hydrate, let's go ✨


🌸 NAME 🌸

read_fifo β€” Transfer packets from OUT endpoint into usb request πŸ’Œ

(like, it's giving "move the packets out of the fifo and into the request", and that's the whole vibe fr fr)


πŸ¦‹ SYNOPSIS πŸ¦‹

int read_fifo (struct pxa_ep *ep , struct pxa27x_request *req );

πŸŽ€ ARGUMENTS πŸŽ€

  • ep β€” pxa physical endpoint. she's the ✨physical✨ one, not the logical one, okay πŸ‘‘
  • req β€” usb request. this is the little container the packets are gonna live in afterward πŸ’–

πŸ”₯ CONTEXT πŸ”₯

interrupt handler 🫢 β€” yes, you're in interrupt context, not me being dramatic for once. keep it snappy, bestie.


⭐ DESCRIPTION ⭐

okay so the whole point: unload as many packets as possible from the fifo we use for usb OUT transfers and put them into the request πŸ’… that's it, that's the function. she's a mover, an icon, a packet relocation specialist.

the caller should have made sure there's at least one packet ready β€” like, that's on you, not on her πŸ™ˆ so do your little vibe check before calling, mmkay?

⚠️ also important: it doesn't complete the request, that's the caller's job. do not expect her to finish that for you, she will not, no cap πŸ’€

and the return values, because we love a clear answer:

  • returns 1 if the request completed βœ…
  • returns 0 otherwise πŸ«₯

periodt.


🌈 SEE ALSO 🌈

the kernel file is ./drivers/usb/gadget/udc/pxa27x_udc.c and honestly the whole friend group lives there together. here's everyone, no one left out, we don't do that πŸ’œ


and that's the page, bestie 🧚 source is ./drivers/usb/gadget/udc, dated October 2026, section read_fifo(9) β€” mwah, go read the fifo, slay πŸ’…πŸ’–

πŸ“¦ where this page comes from