add_vol(9)
π¦ add_vol(9) β create and add a new volume π
okay so welcome to the add_vol(9) page in the Kernel API Manual, bestie. This is the little function that creates and adds a new volume to ubi_attach_info, and it's giving very "small but important" energy. β¨
πΈ NAME πΈ
add_vol β create and add a new volume to ubi_attach_info. That's the whole vibe.
β¨ SYNOPSIS β¨
struct ubi_ainf_volume * add_vol (struct ubi_attach_info *ai , int
vol_id , int used_ebs , int data_pad , u8 vol_type , int last_eb_bytes
);
π ARGUMENTS π
aiβ theubi_attach_infoobject. Main character of the attach-info situation.vol_idβ theVIDof the new volume.used_ebsβ number of used EBS. Yes, EBS. We keep it exactly as written.data_padβ data padding value of the new volume.vol_typeβ volume type.last_eb_bytesβ number of bytes in the last LEB.
π¦ DESCRIPTION π¦
On success, this returns the new struct ubi_ainf_volume. Slay.
And NULL? That indicates an error. No cap. π
π SEE ALSO π
This page points at the kernel file ./drivers/mtd/ubi/fastmap.c, and the whole friend group is: init_seen(9), free_seen(9), set_seen(9), self_check_seen(9), ubi_calc_fm_size(9), new_fm_vbuf(9), add_aeb(9), assign_aeb_to_av(9), update_vol(9), process_pool_aeb(9), unmap_peb(9), scan_pool(9), count_fastmap_pebs(9), ubi_attach_fastmap(9), find_fm_anchor(9), ubi_scan_fastmap(9), ubi_write_fastmap(9), invalidate_fastmap(9), return_fm_pebs(9), ubi_update_fastmap(9). iykyk β¨
mwah π source tree: ./drivers/mtd/ubi; date: October 2026; manual: add_vol(9). byeee π«Ά
π¦ 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