mbox series

[0/1,RFC] x86: Export information about hardware memory encryption to sysfs

Message ID 20210910213337.48017-1-martin.fernandez@eclypsium.com
Headers show
Series x86: Export information about hardware memory encryption to sysfs | expand

Message

Martin Fernandez Sept. 10, 2021, 9:33 p.m. UTC
Show the value of EFI_MEMORY_CPU_CRYPTO of the system memory as a whole
on each memory node in sysfs.

This is a first step in a serie of patches for exporting the needed
information to userspace to determine if a machine is doing using
Intel's TME or MKTME.

In a next patch I'm going to export if TME/MKTME is activated by the
BIOS to sysfs, since right now for the user, this information is only
available in the kernel logs, and it's not appropiate for fwupd to scan
the boot logs just to parse an integer. I'm looking for suggestions
for where to store this value.

Martin Fernandez (1):
  x86: Export information about hardware memory encryption to sysfs

 Documentation/ABI/testing/sysfs-devices-node | 11 +++
 arch/x86/include/asm/numa.h                  |  2 +
 arch/x86/mm/numa.c                           |  5 ++
 arch/x86/mm/numa_emulation.c                 |  2 +-
 arch/x86/platform/efi/efi.c                  | 27 +++++++
 drivers/base/node.c                          | 80 +++++++++++++++++++-
 include/linux/efi.h                          |  7 ++
 include/linux/node.h                         |  5 ++
 8 files changed, 137 insertions(+), 2 deletions(-)
 create mode 100644 Documentation/ABI/testing/sysfs-devices-node


base-commit: 0bcfe68b876748762557797a940d0a82de700629
--
2.30.2