ext4_has_free_clusters(9)
β¨ NAME β¨
okay so this is the ext4_has_free_clusters(9) page from the Kernel API Manual, bestie π«Ά. The NAME line is literally ext4_has_free_clusters - and then it just ends β no extra description after the dash, no cap ππ
.
π SYNOPSIS π
exact signature, character-for-character, because we respect the source:
int ext4_has_free_clusters (struct ext4_sb_info *sbi , s64 nclusters ,
unsigned int flags );
π ARGUMENTS π
sbiβ the in-core super block structure. main-character data situation, lowkey πnclustersβ number of needed blocks. yes bestie, the arg is named clusters but the description says blocks β we're just reporting the lore π«Άflagsβ flags fromext4_mb_new_blocks. periodt β¨
πΈ DESCRIPTION πΈ
Check if filesystem has nclusters free & available for allocation. that's the vibe check π₯.
On success return 1, return 0 on failure. so: success -> 1, failure -> 0 β that's the whole return-value saga πβ¨.
π¦ SEE ALSO π¦
the kernel file is ./fs/ext4/balloc.c, and the whole friend group is:
ext4_get_group_desc(9)ext4_read_block_bitmap_nowait(9)ext4_should_retry_alloc(9)ext4_count_free_clusters(9)ext4_bg_has_super(9)ext4_bg_num_gdb(9)ext4_inode_to_goal_block(9)
made with π from the ./fs/ext4 source tree, October 2026 vintage, and this manual page is ext4_has_free_clusters(9) β bye bestie, go check those free clusters π§π
π¦ 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