vdo_initialize_layout(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ vdo_initialize_layout β€” Kernel API Manual, bestie edition ✨

Okay so picture this: it's a vdo_initialize_layout(9) moment and you just need to lay out all the partitions of a vdo. That's it. That's the whole NAME section. Slay. πŸŽ€


πŸ’… SYNOPSIS

int vdo_initialize_layout (block_count_t size , physical_block_number_t
offset , block_count_t block_map_blocks , block_count_t journal_blocks ,
block_count_t summary_blocks , struct layout *layout );

Not me dropping the whole signature on you at once β€” but like, copy it exactly, don't freestyle it. ✨


🌸 ARGUMENTS

  • size β€” the entire size of the vdo. Like, the whole thing, no crumbs left over. πŸ’–
  • offset β€” where the layout starts on the underlying storage, measured in blocks. yes, in blocks, keep up bestie 🫢
  • block_map_blocks β€” the size of the block map partition. it's giving "block map partition, but make it size" πŸ”₯
  • journal_blocks β€” the size of the journal partition. the journal gets exactly this many blocks, periodt πŸ’€
  • summary_blocks β€” the size of the slab summary partition. slab summary partition size, that's her πŸ‘‘
  • layout β€” the layout to actually initialize. the main character struct, fr fr ⭐

πŸ¦‹ RETURN

VDO_SUCCESS or an error. That's it. Either it ate or it didn't, no in between. 😭


🌈 SEE ALSO

Kernel file ./drivers/md/dm-vdo/encodings.c, plus this whole friend group:

validate_version(9), vdo_validate_header(9), decode_volume_geometry(9), vdo_encode_volume_geometry(9), vdo_parse_geometry_block(9), vdo_compute_new_forest_pages(9), encode_recovery_journal_state_7_0(9), decode_recovery_journal_state_7_0(9), vdo_get_journal_operation_name(9), encode_slab_depot_state_2_0(9), decode_slab_depot_state_2_0(9), vdo_configure_slab_depot(9), vdo_configure_slab(9), vdo_decode_slab_journal_entry(9), allocate_partition(9), make_partition(9), vdo_uninitialize_layout(9), vdo_get_partition(9), vdo_get_known_partition(9), pack_vdo_config(9), pack_vdo_component(9), unpack_vdo_config(9), unpack_vdo_component_41_0(9), decode_vdo_component(9), vdo_validate_config(9), vdo_destroy_component_states(9), decode_components(9), vdo_decode_component_states(9), vdo_validate_component_states(9), vdo_encode_component_states(9), vdo_encode_super_block(9), vdo_decode_super_block(9), vdo_initialize_component_states(9), vdo_compute_index_blocks(9), vdo_initialize_volume_geometry(9)


ok that's literally everyone, go read them, iykyk πŸ’œ

β€” and that's the whole page diva 🧚 this came from ./drivers/md/dm-vdo, dated October 2026, version vdo_initialize_layout(9) β€” mwah, study it, love u bye πŸ’–

πŸ“¦ where this page comes from