read_seqlock_excl(9)
β¨ read_seqlock_excl β¨
okay so bestie, welcome to the Kernel API Manual entry for read_seqlock_excl(9) β yes that's the manual name, yes I'm folding it in here, we move π
πΈ NAME πΈ
read_seqlock_excl β like, it begins a seqlock_t locking reader section. that's the whole vibe π
π¦ SYNOPSIS π¦
void read_seqlock_excl (seqlock_t *sl );
literally copy that exactly, no cap β¨
π ARGUMENTS π
slβ pointer toseqlock_t. that's it. that's the argument. iconic minimalism π«Ά
π DESCRIPTION π
okay so read_seqlock_excl opens a seqlock_t locking reader critical section. a locking reader exclusively locks out both other writers and other locking readers β yes both, the way it's framed with asterisks and italics, take it seriously π β but here's the thing, it does not update the embedded sequence number.
locking readers act like a normal spin_lock/spin_unlock. simple as that, fr fr.
the opened read section must be closed with read_sequnlock_excl β do not leave it hanging, bestie, that's not the move π
π₯ CONTEXT π₯
if the seqlock_t write section, or other read sections, can be invoked from hardirq or softirq contexts, use the _irqsave or _bh variant of this function instead. like, genuinely, that's a real caveat, not a drill π
π SEE ALSO π
bestie, buckle up, this list is a whole main character moment π
kernel file ./include/linux/seqlock.h plus all of these:
seqcount_init(9)SEQCNT_ZERO(9)__read_seqcount_begin(9)raw_read_seqcount_begin(9)read_seqcount_begin(9)raw_read_seqcount(9)raw_seqcount_try_begin(9)raw_seqcount_begin(9)__read_seqcount_retry(9)read_seqcount_retry(9)raw_write_seqcount_begin(9)raw_write_seqcount_end(9)write_seqcount_begin_nested(9)write_seqcount_begin(9)write_seqcount_end(9)raw_write_seqcount_barrier(9)write_seqcount_invalidate(9)SEQCNT_LATCH_ZERO(9)seqcount_latch_init(9)raw_read_seqcount_latch(9)read_seqcount_latch(9)raw_read_seqcount_latch_retry(9)read_seqcount_latch_retry(9)raw_write_seqcount_latch(9)write_seqcount_latch_begin(9)write_seqcount_latch(9)write_seqcount_latch_end(9)seqlock_init(9)DEFINE_SEQLOCK(9)read_seqbegin(9)read_seqretry(9)write_seqlock(9)write_sequnlock(9)write_seqlock_bh(9)write_sequnlock_bh(9)write_seqlock_irq(9)write_sequnlock_irq(9)write_seqlock_irqsave(9)write_sequnlock_irqrestore(9)read_sequnlock_excl(9)read_seqlock_excl_bh(9)read_sequnlock_excl_bh(9)read_seqlock_excl_irq(9)read_sequnlock_excl_irq(9)read_seqlock_excl_irqsave(9)read_sequnlock_excl_irqrestore(9)read_seqbegin_or_lock(9)need_seqretry(9)done_seqretry(9)read_seqbegin_or_lock_irqsave(9)done_seqretry_irqrestore(9)scoped_seqlock_read(9)
like, obsessed with the sheer length of this list ngl π§
cute little sign-off: this page lives in./include/linux, dated October 2026, and it's theread_seqlock_excl(9)entry of the Kernel API Manual. slay, go lock something responsibly π
π¦ 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