sgx_encl_remove_pages(9)
π sgx_encl_remove_pages β a Kernel API Manual moment (section 9, bestie)
okay so this is the sgx_encl_remove_pages(9) page, and yes we're reading kernel API docs for fun now, that's just who we are π
β¨ NAME β¨
sgx_encl_remove_pages β literally just Remove trimmed pages from SGX enclave. that's the whole vibe. trimmed pages? gone. removed. slay.
πΈ SYNOPSIS πΈ
long sgx_encl_remove_pages (struct sgx_encl *encl , struct
sgx_enclave_remove_pages *params );
like, copy that exactly bestie, every character matters, no cap π«Ά
π ARGUMENTS π
enclβ the enclave that these pages belong to. it's giving "whose pages are these" energy. the pages lowkey live here πparamsβ checked parameters from user, telling us which pages need to be removed. the word "checked" is doing so much work here and we love her for it β¨
π₯ RETURN π₯
0β Success. we ate. periodt π-errnoβ Otherwise. so like, anything else, and you're getting an errno back. not the win we wanted but honestly valid π
π¦ SEE ALSO π¦
the kernel file ./arch/x86/kernel/cpu/sgx/ioctl.c β go read her, she's iconic β plus the whole friend group:
sgx_ioc_enclave_create(9)sgx_ioc_enclave_add_pages(9)sgx_ioc_enclave_init(9)sgx_ioc_enclave_provision(9)sgx_enclave_restrict_permissions(9)sgx_ioc_enclave_restrict_permissions(9)sgx_enclave_modify_types(9)sgx_ioc_enclave_modify_types(9)sgx_ioc_enclave_remove_pages(9)
ngl that's a squad π every single one of them listed, we don't skip the group chat members π
fr fr reminder: params is described as checked parameters from user, and we're keeping that word because it's load-bearing. don't come for me about it π
and that's the page!! brought to you by the source path ./arch/x86/kernel/cpu/sgx, dated October 2026, filed under sgx_encl_remove_pages(9) β mwah, stan kernel docs, bye bestie π§ππ
π¦ 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