Re: [PATCH v3 03/25] x86/sgx: Wipe out EREMOVE from sgx_free_epc_page()

From: Paolo Bonzini
Date: Wed Mar 24 2021 - 07:25:34 EST


On 24/03/21 11:48, Kai Huang wrote:
+/* Error message for EREMOVE failure, when kernel is about to leak EPC page */
+#define EREMOVE_ERROR_MESSAGE \
+ "EREMOVE returned %d (0x%x), kernel bug likely. EPC page leaked, SGX may become
unusuable. Please refer to Documentation/x86/sgx.rst for more information."
Rewritten:

EREMOVE returned %d and an EPC page was leaked; SGX may become unusable.
This is a kernel bug, refer to Documentation/x86/sgx.rst for more information.
Fine to me, although this would have %d (0x%x) -> %d change in the code.


Yeah you can of course keep the 0x%x part.

Paolo