BUF_LOCKFREE(9)
π BUF_LOCKFREE(9) β bestie edition
okay so you found your way into the Kernel Developer's Manual and you wanna know about BUF_LOCKFREE β the macro that yeets a buffer lock into the void. no cap, that's literally the whole vibe. let's get into it β¨
πΈ NAME πΈ
BUF_LOCKFREE β destroys a buffer's lock π«Ά
β¨ SYNOPSIS β¨
bestie you gotta bring the right headers to the function. don't show up empty-handed π
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/uio.h>
#include <sys/bio.h>
#include <sys/buf.h>
void
BUF_LOCKFREE(struct buf *bp);
π¦ DESCRIPTION π¦
The BUF_LOCKFREE() macro destroys the buffer lock. that's it. that's the job. it's giving "demolition crew but for locks" π
β οΈ THE LOCK MUST NOT BE HELD WHEN THIS MACRO IS CALLED β or a panic will result. and not the fun kind of panic. the kernel kind. π like, do NOT call this while you're still holding the lock, fr fr. that's the whole boundary and you must respect it.
Its argument is:
bpβ the buffer whose lock is to be destroyed. yes queen, hand over the buffer, we're taking its lock out back π
π SEE ALSO π
the whole squad, all linked up π«Ά
π AUTHORS π
This manual page was written by Chad David <davidc@acns.ab.ca>. iconic behavior honestly, thank you for your service π«‘β¨
and that's the whole page bestie, you ate it π πΈ
Debian Β· July 9, 2001 Β· BUF_LOCKFREE(9) β periodt, no notes, go free those locks (safely!!) π¦π
π¦ where this page comes from
- debian bookworm: freebsd-manpages 12.2-1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- debian trixie: freebsd-manpages 12.2-2 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu jammy: freebsd-manpages 12.2-1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu noble: freebsd-manpages 12.2-1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu questing: freebsd-manpages 12.2-2
- ubuntu resolute: freebsd-manpages 12.2-2build1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu stonking: freebsd-manpages 12.2-2build1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- Copyright (C) 2001 Chad David <davidc@acns.ab.ca>. All rights reserved
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms