ne_set_user...region_ioctl(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ ne_set_user_memory_region_ioctl(9) ✨

okay so bestie, welcome to the Kernel API Manual πŸ’… this one's about ne_set_user_memory_region_ioctl β€” yes that's a mouthful, i know, but it's fine, we're gonna get through it together 🫢


🌸 NAME 🌸

ne_set_user_memory_region_ioctl β€” literally just adds a user space memory region to the slot that's associated with the current enclave. that's it. that's the whole vibe πŸŽ€


πŸ¦‹ SYNOPSIS πŸ¦‹

int ne_set_user_memory_region_ioctl (struct ne_enclave *ne_enclave ,
struct ne_user_memory_region mem_region );

πŸ’– ARGUMENTS πŸ’–

  • ne_enclave β€” the private data that's associated with the current enclave. yep, the enclave's personal little diary πŸŽ€
  • mem_region β€” the user space memory region that's gonna get associated with the given slot. it's giving "put this here" energy ✨

🧚 CONTEXT 🧚

Process context, bestie. and listen β€” this function is called with the ne_enclave mutex held πŸ”’ like, held held. no cap. so don't go doing anything weird in there πŸ’€


πŸ‘‘ RETURN πŸ‘‘

  • 0 on success. slay πŸ’…
  • Negative return value on failure. not slay 😭

🌈 SEE ALSO 🌈

  • Kernel file ./drivers/virt/nitro_enclaves/ne_misc_dev.c β€” Enclave lifetime management driver for Nitro Enclaves (NE).(9)
  • NE_CPUS_SIZE(9)
  • NE_EIF_LOAD_OFFSET(9)
  • NE_MIN_ENCLAVE_MEM_SIZE(9)
  • NE_MIN_MEM_REGION_SIZE(9)
  • NE_PARENT_VM_CID(9)
  • struct ne_cpu_pool(9)
  • struct ne_phys_contig_mem_regions(9)
  • ne_check_enclaves_created(9)
  • ne_setup_cpu_pool(9)
  • ne_teardown_cpu_pool(9)
  • ne_set_kernel_param(9)
  • ne_donated_cpu(9)
  • ne_get_unused_core_from_cpu_pool(9)
  • ne_set_enclave_threads_per_core(9)
  • ne_get_cpu_from_cpu_pool(9)
  • ne_get_vcpu_core_from_cpu_pool(9)
  • ne_check_cpu_in_cpu_pool(9)
  • ne_add_vcpu_ioctl(9)
  • ne_sanity_check_user_mem_region(9)
  • ne_sanity_check_user_mem_region_page(9)
  • ne_sanity_check_phys_mem_region(9)
  • ne_merge_phys_contig_memory_regions(9)
  • ne_start_enclave_ioctl(9)
  • ne_enclave_ioctl(9)
  • ne_enclave_remove_all_mem_region_entries(9)
  • ne_enclave_remove_all_vcpu_id_entries(9)
  • ne_pci_dev_remove_enclave_entry(9)
  • ne_enclave_release(9)
  • ne_enclave_poll(9)
  • ne_create_vm_ioctl(9)
  • ne_ioctl(9)

like, that's a lot of friends, but every single one of them gets a shoutout 🫢 iykyk.


lowkey reminder: this page lives under ./drivers/virt/nitro_enclaves, and it's dated October 2026, manual name ne_set_user...region_ioctl(9). that's the whole source/version/date situation, bestie β€” periodt πŸ’œ

go forth and set those memory regions, icon 🧚✨

πŸ“¦ where this page comes from