devm_cxl_add_region(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ NAME ✨

okay so bestie, welcome to devm_cxl_add_region(9) from the Kernel API Manual πŸ’… this one adds a region to a decoder, and it's giving important kernel-core energy πŸŽ€


🌸 SYNOPSIS 🌸

struct cxl_region * devm_cxl_add_region (struct cxl_root_decoder *cxlrd
, int id , enum cxl_partition_mode mode , enum cxl_decoder_type type );

πŸ¦‹ ARGUMENTS πŸ¦‹

  • cxlrd β€” the root decoder πŸ‘‘ no cap, that's the whole vibe.
  • id β€” the memregion id to create, or memregion_free on failure 🫢
  • mode β€” the mode for the endpoint decoders of this region ✨
  • type β€” select whether this is an expander or accelerator (type-2 or type-3) πŸ’–

πŸŽ€ DESCRIPTION πŸŽ€

This is the second step of region initialization, bestie. Regions exist within an address space which is mapped by a cxlrd 🌈 that's the whole setup, and this function is here to add one to the decoder.


πŸ”₯ RETURN πŸ”₯

Returns 0 if the region was added to the cxlrd, else returns a negative error code 😭

The region will be named "regionZ" where Z is the unique region number β€” yes, literally "regionZ", iconic naming fr fr ⭐


πŸ’œ SEE ALSO πŸ’œ


made with πŸ’– from ./drivers/cxl/core, October 2026 β€” devm_cxl_add_region(9) 🧚✨

πŸ“¦ where this page comes from