public inbox for cygwin-patches@cygwin.com
 help / color / mirror / Atom feed
* [PATCH] fhandler_proc.cc(format_proc_cpuinfo): report Intel SGX bits
@ 2020-12-17  7:11 Brian Inglis
  2020-12-17 15:04 ` Corinna Vinschen
  0 siblings, 1 reply; 2+ messages in thread
From: Brian Inglis @ 2020-12-17  7:11 UTC (permalink / raw)
  To: cygwin-patches

[-- Attachment #1: Type: text/plain, Size: 332 bytes --]

Update to Linux next 5.10 cpuinfo flags for Intel SDM 36.7.1 Software
Guard Extensions, and 38.1.4 SGX Launch Control Configuration.
Launch control restricts what software can run with enclave protections,
which helps protect the system from bad enclaves.
---
 winsup/cygwin/fhandler_proc.cc | 2 ++
 1 file changed, 2 insertions(+)

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-fhandler_proc.cc-format_proc_cpuinfo-add-Intel-SGX-h.patch --]
[-- Type: text/x-patch; name="0001-fhandler_proc.cc-format_proc_cpuinfo-add-Intel-SGX-h.patch", Size: 1097 bytes --]

diff --git a/winsup/cygwin/fhandler_proc.cc b/winsup/cygwin/fhandler_proc.cc
index 13397150ff53..8e23c0609485 100644
--- a/winsup/cygwin/fhandler_proc.cc
+++ b/winsup/cygwin/fhandler_proc.cc
@@ -1414,6 +1414,7 @@ format_proc_cpuinfo (void *, char *&destbuf)
 
 	  ftcprint (features1,  0, "fsgsbase");	    /* rd/wr fs/gs base */
 	  ftcprint (features1,  1, "tsc_adjust");   /* TSC adjustment MSR 0x3B */
+	  ftcprint (features1,  2, "sgx");	    /* software guard extensions */
 	  ftcprint (features1,  3, "bmi1");         /* bit manip ext group 1 */
 	  ftcprint (features1,  4, "hle");          /* hardware lock elision */
 	  ftcprint (features1,  5, "avx2");         /* AVX ext instructions */
@@ -1564,6 +1565,7 @@ format_proc_cpuinfo (void *, char *&destbuf)
 	  ftcprint (features1, 27, "movdiri");          /* movdiri instr */
 	  ftcprint (features1, 28, "movdir64b");        /* movdir64b instr */
 	  ftcprint (features1, 29, "enqcmd");		/* enqcmd/s instructions*/
+	  ftcprint (features1, 30, "sgx_lc");		/* sgx launch control */
         }
 
       /* AMD MCA cpuid 0x80000007 ebx */

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] fhandler_proc.cc(format_proc_cpuinfo): report Intel SGX bits
  2020-12-17  7:11 [PATCH] fhandler_proc.cc(format_proc_cpuinfo): report Intel SGX bits Brian Inglis
@ 2020-12-17 15:04 ` Corinna Vinschen
  0 siblings, 0 replies; 2+ messages in thread
From: Corinna Vinschen @ 2020-12-17 15:04 UTC (permalink / raw)
  To: cygwin-patches

On Dec 17 00:11, Brian Inglis wrote:
> Update to Linux next 5.10 cpuinfo flags for Intel SDM 36.7.1 Software
> Guard Extensions, and 38.1.4 SGX Launch Control Configuration.
> Launch control restricts what software can run with enclave protections,
> which helps protect the system from bad enclaves.
> ---
>  winsup/cygwin/fhandler_proc.cc | 2 ++
>  1 file changed, 2 insertions(+)

> diff --git a/winsup/cygwin/fhandler_proc.cc b/winsup/cygwin/fhandler_proc.cc
> index 13397150ff53..8e23c0609485 100644
> --- a/winsup/cygwin/fhandler_proc.cc
> +++ b/winsup/cygwin/fhandler_proc.cc
> @@ -1414,6 +1414,7 @@ format_proc_cpuinfo (void *, char *&destbuf)
>  
>  	  ftcprint (features1,  0, "fsgsbase");	    /* rd/wr fs/gs base */
>  	  ftcprint (features1,  1, "tsc_adjust");   /* TSC adjustment MSR 0x3B */
> +	  ftcprint (features1,  2, "sgx");	    /* software guard extensions */
>  	  ftcprint (features1,  3, "bmi1");         /* bit manip ext group 1 */
>  	  ftcprint (features1,  4, "hle");          /* hardware lock elision */
>  	  ftcprint (features1,  5, "avx2");         /* AVX ext instructions */
> @@ -1564,6 +1565,7 @@ format_proc_cpuinfo (void *, char *&destbuf)
>  	  ftcprint (features1, 27, "movdiri");          /* movdiri instr */
>  	  ftcprint (features1, 28, "movdir64b");        /* movdir64b instr */
>  	  ftcprint (features1, 29, "enqcmd");		/* enqcmd/s instructions*/
> +	  ftcprint (features1, 30, "sgx_lc");		/* sgx launch control */
>          }
>  
>        /* AMD MCA cpuid 0x80000007 ebx */


Pushed.

Thanks,
Corinna

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-12-17 15:04 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-17  7:11 [PATCH] fhandler_proc.cc(format_proc_cpuinfo): report Intel SGX bits Brian Inglis
2020-12-17 15:04 ` Corinna Vinschen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).