diff options
author | Pratik Prajapati <pratikkumar.v.prajapati@intel.com> | 2017-07-24 13:53:26 -0700 |
---|---|---|
committer | Martin Roth <martinroth@google.com> | 2017-07-28 16:21:32 +0000 |
commit | 91664d4d6fa42cb8606bae982805d9d0fb22c57a (patch) | |
tree | 83b6215fbf6155a9845846b2c2ae1419f786c2f8 /util/inteltool/inteltool.h | |
parent | a1af090002193ef5f202b605397af067ce15caa2 (diff) | |
download | coreboot-91664d4d6fa42cb8606bae982805d9d0fb22c57a.tar.xz |
util/inteltool: Add support for SGX status
Add support for dumping Intel Software Guard Extension (SGX)
status. --sgx or -x is the command line switch to get SGX status.
The code iterates through all cores and reads MSRs to check if SGX is
supported, enabled and the feature is locked.
Change-Id: I1f5046c1f6703f5429c8717053ffe9c981cedf6f
Signed-off-by: Pratik Prajapati <pratikkumar.v.prajapati@intel.com>
Reviewed-on: https://review.coreboot.org/20758
Reviewed-by: Philipp Deppenwiese <zaolin.daisuki@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Diffstat (limited to 'util/inteltool/inteltool.h')
-rw-r--r-- | util/inteltool/inteltool.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/util/inteltool/inteltool.h b/util/inteltool/inteltool.h index e463260a43..d4aa96fc60 100644 --- a/util/inteltool/inteltool.h +++ b/util/inteltool/inteltool.h @@ -224,6 +224,12 @@ msr_t freebsd_rdmsr(int addr); int freebsd_wrmsr(int addr, msr_t msr); #endif typedef struct { uint16_t addr; int size; char *name; } io_register_t; +typedef struct { + uint32_t eax; + uint32_t ebx; + uint32_t ecx; + uint32_t edx; +} cpuid_result_t; void *map_physical(uint64_t phys_addr, size_t len); void unmap_physical(void *virt_addr, size_t len); @@ -241,4 +247,5 @@ int print_ambs(struct pci_dev *nb, struct pci_access *pacc); int print_spi(struct pci_dev *sb); int print_gfx(struct pci_dev *gfx); int print_ahci(struct pci_dev *ahci); +int print_sgx(void); void ivybridge_dump_timings(const char *dump_spd_file); |