AUDIT_NAME_TO_FSTYPE(3)
π AUDIT_NAME_TO_FSTYPE π
ok so this is a page from the Linux Audit API (that's the manual section 3 situation, bestie) and it's all about turning a filesystem type name into the actual number behind it. tiny function, huge glow-up energy. let's get into it π¦
β¨ NAME β¨
audit_name_to_fstype β convert the fstype name to the numeric fstype value
like. the whole job. the entire assignment. she does one thing and she does it flawlessly. π
πΈ SYNOPSIS πΈ
#include <libaudit.h>
int audit_name_to_fstype(const char *name);
yeah that's it. one include, one function, one const char *. minimalism ate. π
π DESCRIPTION π
audit_name_to_fstype() takes a fstype name and hands you back the numeric fstype value. and listen, there are exactly two names on the menu, no secret third thing:
"debugfs"β0x64626720"tracefs"β0x74726163
name is the fstype name. that's the whole input. she's not complicated, she's just precise. β¨
ngl the mapping here is a little love letter: those hex values are literally the ASCII of the strings, and honestly? iconic. but fr fr, the only thing this page promises you is: name in, number out.
π RETURN VALUE π
Returns -1 if an name occurs π otherwise, the return value is the numeric fstype value.
so like β you get your number back when everything's chill, and you get -1 when an name happens. check your return value, bestie, don't just vibe past it. π«Ά
π§ SEE ALSO π§
the reverse-direction queen. go say hi. π
π AUTHOR π
Steve Grubb
ok that's the page!! every flag-free, option-free, environment-variable-free inch of it. no cap. π
this lil' page comes to you from Red Hat, dated Mar 2022 β so when you're out here converting fstypes, just know a whole audit API is cheering you on. bye bestie, go log something π
π¦ where this page comes from
- alpine 3.22: audit-doc 4.0.3-r0 Β· LGPL-2.1-or-later
- alpine 3.23: audit-doc 4.1.2-r2 Β· LGPL-2.1-or-later
- alpine 3.24: audit-doc 4.1.2-r6 Β· LGPL-2.1-or-later
- arch rolling: audit 4.2.1-1 Β· GPL-2.0-or-later AND LGPL-2.0-or-later
- centos-stream 10: audit-libs-devel 4.2.1-3.el10 Β· LGPL-2.0-or-later
- centos-stream 9: audit-libs-devel 3.1.5-9.el9 Β· LGPLv2+
- centos-stream 9: audit-libs-devel 3.1.5-9.el9 Β· LGPLv2+
- debian bookworm: libaudit-dev 1:3.0.9-1 Β· GPL-2.0-only
- debian trixie: libaudit-dev 1:4.0.2-2+deb13u1 Β· GPL-2.0-only
- fedora 43: audit-libs-devel 4.1.1-2.fc43 Β· LGPL-2.0-or-later
- fedora 43: audit-libs-devel 4.1.1-2.fc43 Β· LGPL-2.0-or-later
- fedora 43: audit-libs-devel 4.2.1-1.fc43 Β· LGPL-2.0-or-later
- fedora 43: audit-libs-devel 4.2.1-1.fc43 Β· LGPL-2.0-or-later
- fedora 44: audit-libs-devel 4.1.4-1.fc44 Β· LGPL-2.0-or-later
- fedora 44: audit-libs-devel 4.1.4-1.fc44 Β· LGPL-2.0-or-later
- fedora 44: audit-libs-devel 4.2.1-1.fc44 Β· LGPL-2.0-or-later
- fedora 44: audit-libs-devel 4.2.1-1.fc44 Β· LGPL-2.0-or-later
- nixpkgs unstable: audit 4.2.1
- opensuse-leap 16.0: audit-devel 4.0-160000.2.2 Β· LGPL-2.1-or-later
- opensuse-leap 16.0: audit-devel 4.0-160000.2.2 Β· LGPL-2.1-or-later
- opensuse-leap 16.0: audit-devel 4.0-160000.2.2 Β· LGPL-2.1-or-later
- opensuse-leap 16.0: audit-devel 4.0-160000.2.2 Β· LGPL-2.1-or-later
- ubuntu noble: libaudit-dev 1:3.1.2-2.1build1 Β· GPL-2.0-only
- ubuntu noble: libaudit-dev 1:3.1.2-2.1ubuntu0.1 Β· GPL-2.0-only
- ubuntu questing: libaudit-dev 1:4.0.5-1build1
- ubuntu resolute: libaudit-dev 1:4.1.2-1build1 Β· GPL-2.0-only
- ubuntu resolute: libaudit-dev 1:4.1.2-1ubuntu0.1 Β· GPL-2.0-only
- ubuntu stonking: libaudit-dev 1:4.1.2-1ubuntu1 Β· GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms