Re: [RFC PATCH] platform/x86: Add sysfs interface for Intel TXT status

From: Greg KH
Date: Wed Mar 09 2022 - 05:48:38 EST


On Wed, Mar 09, 2022 at 10:40:03AM +0000, Jonathan McDowell wrote:
> (This is an RFC to see if the approach is generally acceptable; unlike
> the previous driver this exposes the information purely as read-only
> status information, so userspace can make an informed decision about the
> system state without having to poke about in /dev/mem. There are still a
> few extra registers I'm trying to dig up information for before a proper
> submission.)
>
> This module provides read-only access to the Intel TXT (Trusted
> Execution Technology) status registers, allowing userspace to determine
> the status of measured boot and whether the dynamic root of trust for
> measurement (DRTM) has been fully enabled.
>
> Tools such as txt-stat from tboot
> <https://sourceforge.net/projects/tboot/> can make use of this driver to
> display state rather than relying on access to /dev/mem.
>
> See Documentation/x86/intel_txt.rst for more information about Intel
> TXT.
>
> Signed-off-by: Jonathan McDowell <noodles@xxxxxx>
> ---
> arch/x86/include/asm/txt.h | 34 +++++
> drivers/platform/x86/intel/Kconfig | 14 ++
> drivers/platform/x86/intel/Makefile | 2 +
> drivers/platform/x86/intel/txt_sysfs.c | 185 +++++++++++++++++++++++++

No Documentation/ABI/ entry for your new sysfs entry? How can we
evaluate if this is a good api then?

Wait, I don't see any sysfs code in here, are you sure you sent a viable
patch?

confused,

greg k-h