Skip to content

Commit 905885f

Browse files
sean-jchansendc
authored andcommitted
x86/sgx: Document structs and enums with '@', not '%'
Use '@' to document structure members and enum values in kernel-doc markup, as per Documentation/doc-guide/kernel-doc.rst and flagged by make htmldocs. WARNING: arch/x86/include/uapi/asm/sgx.h:17 Enum value 'SGX_PAGE_MEASURE' not described in enum 'sgx_page_flags' Opportunistically add a missing ':' for SGX_CHILD_PRESENT. Closes: https://lore.kernel.org/all/20251106145506.145fc620@canb.auug.org.au Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Sean Christopherson <seanjc@google.com> Signed-off-by: Dave Hansen <dave.hansen@linux.intel.com> Reviewed-by: Kai Huang <kai.huang@intel.com> Link: https://patch.msgid.link/20251112160708.1343355-4-seanjc%40google.com
1 parent 243ea51 commit 905885f

2 files changed

Lines changed: 31 additions & 31 deletions

File tree

arch/x86/include/asm/sgx.h

Lines changed: 30 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -66,19 +66,19 @@ enum sgx_encls_function {
6666

6767
/**
6868
* enum sgx_return_code - The return code type for ENCLS, ENCLU and ENCLV
69-
* %SGX_EPC_PAGE_CONFLICT: Page is being written by other ENCLS function.
70-
* %SGX_NOT_TRACKED: Previous ETRACK's shootdown sequence has not
69+
* @SGX_EPC_PAGE_CONFLICT: Page is being written by other ENCLS function.
70+
* @SGX_NOT_TRACKED: Previous ETRACK's shootdown sequence has not
7171
* been completed yet.
72-
* %SGX_CHILD_PRESENT SECS has child pages present in the EPC.
73-
* %SGX_INVALID_EINITTOKEN: EINITTOKEN is invalid and enclave signer's
72+
* @SGX_CHILD_PRESENT: SECS has child pages present in the EPC.
73+
* @SGX_INVALID_EINITTOKEN: EINITTOKEN is invalid and enclave signer's
7474
* public key does not match IA32_SGXLEPUBKEYHASH.
75-
* %SGX_PAGE_NOT_MODIFIABLE: The EPC page cannot be modified because it
75+
* @SGX_PAGE_NOT_MODIFIABLE: The EPC page cannot be modified because it
7676
* is in the PENDING or MODIFIED state.
77-
* %SGX_INSUFFICIENT_ENTROPY: Insufficient entropy in RNG.
78-
* %SGX_NO_UPDATE: EUPDATESVN could not update the CPUSVN because the
77+
* @SGX_INSUFFICIENT_ENTROPY: Insufficient entropy in RNG.
78+
* @SGX_NO_UPDATE: EUPDATESVN could not update the CPUSVN because the
7979
* current SVN was not newer than CPUSVN. This is the most
8080
* common error code returned by EUPDATESVN.
81-
* %SGX_UNMASKED_EVENT: An unmasked event, e.g. INTR, was received
81+
* @SGX_UNMASKED_EVENT: An unmasked event, e.g. INTR, was received
8282
*/
8383
enum sgx_return_code {
8484
SGX_EPC_PAGE_CONFLICT = 7,
@@ -96,7 +96,7 @@ enum sgx_return_code {
9696

9797
/**
9898
* enum sgx_miscselect - additional information to an SSA frame
99-
* %SGX_MISC_EXINFO: Report #PF or #GP to the SSA frame.
99+
* @SGX_MISC_EXINFO: Report #PF or #GP to the SSA frame.
100100
*
101101
* Save State Area (SSA) is a stack inside the enclave used to store processor
102102
* state when an exception or interrupt occurs. This enum defines additional
@@ -113,16 +113,16 @@ enum sgx_miscselect {
113113

114114
/**
115115
* enum sgx_attributes - the attributes field in &struct sgx_secs
116-
* %SGX_ATTR_INIT: Enclave can be entered (is initialized).
117-
* %SGX_ATTR_DEBUG: Allow ENCLS(EDBGRD) and ENCLS(EDBGWR).
118-
* %SGX_ATTR_MODE64BIT: Tell that this a 64-bit enclave.
119-
* %SGX_ATTR_PROVISIONKEY: Allow to use provisioning keys for remote
116+
* @SGX_ATTR_INIT: Enclave can be entered (is initialized).
117+
* @SGX_ATTR_DEBUG: Allow ENCLS(EDBGRD) and ENCLS(EDBGWR).
118+
* @SGX_ATTR_MODE64BIT: Tell that this a 64-bit enclave.
119+
* @SGX_ATTR_PROVISIONKEY: Allow to use provisioning keys for remote
120120
* attestation.
121-
* %SGX_ATTR_KSS: Allow to use key separation and sharing (KSS).
122-
* %SGX_ATTR_EINITTOKENKEY: Allow to use token signing key that is used to
121+
* @SGX_ATTR_KSS: Allow to use key separation and sharing (KSS).
122+
* @SGX_ATTR_EINITTOKENKEY: Allow to use token signing key that is used to
123123
* sign cryptographic tokens that can be passed to
124124
* EINIT as an authorization to run an enclave.
125-
* %SGX_ATTR_ASYNC_EXIT_NOTIFY: Allow enclaves to be notified after an
125+
* @SGX_ATTR_ASYNC_EXIT_NOTIFY: Allow enclaves to be notified after an
126126
* asynchronous exit has occurred.
127127
*/
128128
enum sgx_attribute {
@@ -195,7 +195,7 @@ struct sgx_secs {
195195

196196
/**
197197
* enum sgx_tcs_flags - execution flags for TCS
198-
* %SGX_TCS_DBGOPTIN: If enabled allows single-stepping and breakpoints
198+
* @SGX_TCS_DBGOPTIN: If enabled allows single-stepping and breakpoints
199199
* inside an enclave. It is cleared by EADD but can
200200
* be set later with EDBGWR.
201201
*/
@@ -260,11 +260,11 @@ struct sgx_pageinfo {
260260

261261
/**
262262
* enum sgx_page_type - bits in the SECINFO flags defining the page type
263-
* %SGX_PAGE_TYPE_SECS: a SECS page
264-
* %SGX_PAGE_TYPE_TCS: a TCS page
265-
* %SGX_PAGE_TYPE_REG: a regular page
266-
* %SGX_PAGE_TYPE_VA: a VA page
267-
* %SGX_PAGE_TYPE_TRIM: a page in trimmed state
263+
* @SGX_PAGE_TYPE_SECS: a SECS page
264+
* @SGX_PAGE_TYPE_TCS: a TCS page
265+
* @SGX_PAGE_TYPE_REG: a regular page
266+
* @SGX_PAGE_TYPE_VA: a VA page
267+
* @SGX_PAGE_TYPE_TRIM: a page in trimmed state
268268
*
269269
* Make sure when making changes to this enum that its values can still fit
270270
* in the bitfield within &struct sgx_encl_page
@@ -282,14 +282,14 @@ enum sgx_page_type {
282282

283283
/**
284284
* enum sgx_secinfo_flags - the flags field in &struct sgx_secinfo
285-
* %SGX_SECINFO_R: allow read
286-
* %SGX_SECINFO_W: allow write
287-
* %SGX_SECINFO_X: allow execution
288-
* %SGX_SECINFO_SECS: a SECS page
289-
* %SGX_SECINFO_TCS: a TCS page
290-
* %SGX_SECINFO_REG: a regular page
291-
* %SGX_SECINFO_VA: a VA page
292-
* %SGX_SECINFO_TRIM: a page in trimmed state
285+
* @SGX_SECINFO_R: allow read
286+
* @SGX_SECINFO_W: allow write
287+
* @SGX_SECINFO_X: allow execution
288+
* @SGX_SECINFO_SECS: a SECS page
289+
* @SGX_SECINFO_TCS: a TCS page
290+
* @SGX_SECINFO_REG: a regular page
291+
* @SGX_SECINFO_VA: a VA page
292+
* @SGX_SECINFO_TRIM: a page in trimmed state
293293
*/
294294
enum sgx_secinfo_flags {
295295
SGX_SECINFO_R = BIT(0),

arch/x86/include/uapi/asm/sgx.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
/**
1212
* enum sgx_page_flags - page control flags
13-
* %SGX_PAGE_MEASURE: Measure the page contents with a sequence of
13+
* @SGX_PAGE_MEASURE: Measure the page contents with a sequence of
1414
* ENCLS[EEXTEND] operations.
1515
*/
1616
enum sgx_page_flags {

0 commit comments

Comments
 (0)