tty_ldisc_flush(9)
π tty_ldisc_flush(9) β like, the Kernel API Manual bestie β¨
okay so welcome to the Kernel API Manual, bestie π today's main character is tty_ldisc_flush(9) and honestly? she's short, she's sweet, she does exactly one (1) thing and she does it flawlessly. no cap.
β¨ NAME β¨
tty_ldisc_flush β flush the line discipline queue π¦
β¨ SYNOPSIS β¨
void tty_ldisc_flush (struct tty_struct *tty );
like yes that's the whole thing. that's her. π
β¨ ARGUMENTS β¨
ttyβ the tty you wanna flush the ldisc for π«Ά that's it, that's the whole argument, she's lowkey low-maintenance.
β¨ DESCRIPTION β¨
okay so picture this: you've got a tty, right? and you want it cleansed. this function flushes the line discipline queue (if any β if any, mind you, we're not assuming π) for this tty, and it also flushes the tty flip buffers for it too. two-for-one. ate and left no crumbs π₯
so yeah: line discipline queue gone, flip buffers gone, tty fresh as a daisy πΈ
β¨ SEE ALSO β¨
the kernel file lives at ./drivers/tty/tty_ldisc.c β go read it, iykyk π and here's the whole friend group, all of them, no one left behind:
tty_register_ldisc(9)tty_unregister_ldisc(9)tty_ldisc_get(9)tty_ldisc_put(9)tty_ldisc_ref_wait(9)tty_ldisc_ref(9)tty_ldisc_deref(9)tty_set_termios_ldisc(9)tty_ldisc_open(9)tty_ldisc_close(9)tty_ldisc_failto(9)tty_ldisc_restore(9)tty_set_ldisc(9)tty_ldisc_kill(9)tty_reset_termios(9)tty_ldisc_reinit(9)tty_ldisc_hangup(9)tty_ldisc_setup(9)tty_ldisc_release(9)tty_ldisc_init(9)tty_ldisc_deinit(9)
ngl bestie, this one's a short read β no warnings, no bugs section, no drama π just a lil flush and she's out. slay.
mwah π this has been tty_ldisc_flush(9), brought to you from ./drivers/tty, dated October 2026 β periodt, that's the whole page, love u, bye π§β¨
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms