gfs2_allocate_folio_backing(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– gfs2_allocate_folio_backing(9) πŸ’–

okay bestie so this one's a kernel API manual page from the gfs2_allocate_folio_backing(9) section, and it's literally all about making sure a write fault has actual blocks behind it. no cap, it's short but it ate.


✨ NAME ✨

gfs2_allocate_folio_backing β€” Allocate blocks for a write fault


πŸ¦‹ SYNOPSIS πŸ¦‹

int gfs2_allocate_folio_backing (struct folio *folio , size_t length );

πŸŽ€ ARGUMENTS πŸŽ€

  • folio β€” The (locked) folio to allocate backing for. yes bestie, it's locked, keep it that way πŸ’…
  • length β€” Size of the allocation

🌸 DESCRIPTION 🌸

So the vibe here is: we try to allocate all the blocks the folio needs in one single go. iconic, efficient, we love a one-shot attempt 🫢

But lowkey it might fail for various reasons, and that's fine, so we just keep trying until all the blocks backing this folio are allocated. persistence is main character energy fr fr.

And if some of the blocks are already allocated? that is ok too. no drama, no problem πŸ’–


🌈 SEE ALSO 🌈

Kernel file ./fs/gfs2/file.c

gfs2_llseek(9), gfs2_readdir(9), do_gfs2_set_flags(9), gfs2_size_hint(9), gfs2_page_mkwrite(9), gfs2_mmap(9), gfs2_open_common(9), gfs2_open(9), gfs2_release(9), gfs2_fsync(9), gfs2_file_write_iter(9), calc_max_reserv(9), gfs2_lock(9), gfs2_flock(9)


ngl the whole friend group is in that SEE ALSO list, go say hi to all of them 🧚

okay that's the whole page bestie, and for the cute sign-off: this one lives under ./fs/gfs2, dated October 2026, and it's the gfs2_allocate_folio_backing(9) page πŸ’œπŸŽ€βœ¨

πŸ“¦ where this page comes from