STRUCT SCAN_DATA(9)
β¨ NAME β¨
struct scan_data β the little data bundle that gets handed off to scan callback functions π«Ά
okay so this page is from the Kernel API Manual, and it's a struct page, so it's all about a kernel data structure. reading it, bestie β it's short, it's sweet, it's giving "supporting cast member that makes the whole plot work" π
πΈ SYNOPSIS πΈ
struct scan_data {
int min_space;
int pick_free;
int lnum;
int exclude_index;
};
that's the whole thing. four ints. no cap, that's it β¨
π Members π
min_spaceβ the smallest number of bytes you want to bother scanning for. like a little filter: below this, don't even look πpick_freeβ a lil yes/no situation: is it OK to scan for, and pick up, empty LEBs? that's the whole question this field answers πlnumβ wherever the scan finds an LEB number, it gets returned right here. it's the output slot πexclude_indexβ again a yes/no vibe: should index LEBs be excluded? set it accordingly π
π¦ SEE ALSO π¦
this is where it gets iconique β the entire UBIFS finder-functions friend group, all living in the kernel file ./fs/ubifs/find.c π
valuable(9)scan_for_dirty_cb(9)scan_for_dirty(9)ubifs_find_dirty_leb(9)scan_for_free_cb(9)do_find_free_space(9)ubifs_find_free_space(9)scan_for_idx_cb(9)scan_for_leb_for_idx(9)ubifs_find_free_leb_for_idx(9)ubifs_save_dirty_idx_lnums(9)scan_dirty_idx_cb(9)find_dirty_idx_leb(9)get_idx_gc_leb(9)find_dirtiest_idx_leb(9)ubifs_find_dirty_idx_leb(9)
like, that's a whole group chat right there β go read them all if you want the full lore π§π
ngl, if you're here you're probably writing or reading a scan callback. say hi to min_space for me π
that's the page, bestie! π this one ships out of ./fs/ubifs and it's dated October 2026 β mark your calendars, mwah ππβ
π¦ 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