ubifs_scan(9)
π ubifs_scan(9) β like, the Kernel API Manual page, bestie
Okay so this is ubifs_scan, straight out of the Kernel API Manual, and I'm gonna walk you through it like we're texting at 2am. Stay with me, it's actually not that deep π«Ά
β¨ NAME β¨
ubifs_scan β scan a logical eraseblock. That's it. That's the whole vibe check. π
πΈ SYNOPSIS πΈ
struct ubifs_scan_leb * ubifs_scan (const struct ubifs_info *c , int lnum , int offs , void *sbuf , int quiet );
Not me copying this character for character because you need it exactly like this ππ
π¦ ARGUMENTS π¦
cβ the UBIFS file-system description object. Your main character struct, lowkey.lnumβ logical eraseblock number. Which LEB we're looking at πoffsβ offset to start at (usually zero, fr fr).sbufβ the scan buffer. Heads up bestie: it must be ofc->leb_sizebytes in size. No exceptions, no cap πquietβ print no messages. Shhh. π
π§ DESCRIPTION π§
So what does this bad boy do? It scans LEB number lnum and returns complete information about its contents. Iconic behavior, honestly. β¨
It returns the scanned information in case of success. And if the LEB neads recovery, it hands you back -EUCLEAN. Any other failure? You get other negative error codes. Slay, but make it errors. π
And about quiet β if it's non-zero, this function does not print large and scary error messages and flash dumps when errors happen. So if you're not in the mood for the dramatic flash dump monologue, just set that flag and move on. π«Ά
π₯ SEE ALSO π₯
Kernel file ./fs/ubifs/scan.c, plus the whole friend group: scan_padding_bytes(9), ubifs_scan_a_node(9), ubifs_start_scan(9), ubifs_end_scan(9), ubifs_add_snod(9), ubifs_scanned_corruption(9), ubifs_scan_destroy(9). Go read them, iykyk π
π the little sign-off π
This page lives in ./fs/ubifs, and it's dated October 2026, filed under ubifs_scan(9). Periodt. βππ
π¦ 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