__nbcon_atom..._pending_con(9)
π NAME π
okay so bestie, this is the Kernel API Manual page __nbcon_atom..._pending_con(9), and the actual function name is __nbcon_atomic_flush_pending_con. It does one thing: flush the specified nbcon console using its write_atomic() callback. That's the whole vibe.
β¨ SYNOPSIS β¨
Here's the signature, no cap:
int __nbcon_atomic_flush_pending_con (struct console *con , u64 stop_seq
);
π ARGUMENTS π
conβ the nbcon console to flush. The console in question, bestie.stop_seqβ flush up until this record. Like, stop at this sequence, okay?
π RETURN π
It returns 0 if con was flushed up to stop_seq. Otherwise, you get an error code on failure. That's the tea. π«
πΈ DESCRIPTION πΈ
So this function flushes the specified nbcon console using its write_atomic() callback, and if it can't get all the way to stop_seq, it hands you back an error code. Simple enough. But the errors have lore, so listen up:
π Errors π
-EPERM: Unable to acquire console ownership.-EAGAIN: Another context took over ownership while printing.-ENOENT: A record beforestop_seqis not available.
If flushing up to stop_seq was not successful, it only makes sense for the caller to try again when -EAGAIN was returned. When -EPERM is returned, this context is not allowed to acquire the console. When -ENOENT is returned, it cannot be expected that the unfinalized record will become available.
no cap, those three error codes are doing different jobs. don't mix them up. π
π¦ SEE ALSO π¦
Kernel file ./kernel/printk/nbcon.c and the whole nbcon friend group:
nbcon_state_set(9)nbcon_state_read(9)nbcon_state_try_cmpxchg(9)nbcon_seq_read(9)nbcon_seq_force(9)nbcon_seq_try_update(9)nbcon_context_try_acquire_direct(9)nbcon_context_try_acquire_requested(9)nbcon_context_try_acquire_handover(9)nbcon_context_try_acquire_hostile(9)nbcon_context_try_acquire(9)nbcon_context_release(9)nbcon_context_can_proceed(9)nbcon_can_proceed(9)__nbcon_context_update_unsafe(9)nbcon_enter_unsafe(9)nbcon_exit_unsafe(9)nbcon_reacquire_nobuf(9)nbcon_emit_next_record(9)nbcon_kthread_should_wakeup(9)nbcon_kthread_func(9)nbcon_irq_work(9)nbcon_kthreads_wake(9)nbcon_kthread_create(9)nbcon_get_cpu_emergency_nesting(9)nbcon_get_default_prio(9)nbcon_allow_unsafe_takeover(9)nbcon_legacy_emit_next_record(9)nbcon_atomic_flush_pending_con(9)__nbcon_atomic_flush_pending(9)nbcon_atomic_flush_pending(9)nbcon_atomic_flush_unsafe(9)nbcon_cpu_emergency_enter(9)nbcon_cpu_emergency_exit(9)nbcon_alloc(9)nbcon_free(9)nbcon_device_try_acquire(9)nbcon_device_release(9)nbcon_kdb_try_acquire(9)nbcon_kdb_release(9)nbcon_write_context_is_braille(9)nbcon_braille_try_acquire(9)nbcon_braille_release(9)
xoxo, your ./kernel/printk bestie, dated October 2026 πβ¨
π¦ 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