platform/x86/intel/tpmi: Add debugfs interface
authorSrinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
Wed, 12 Jul 2023 22:59:49 +0000 (15:59 -0700)
committerHans de Goede <hdegoede@redhat.com>
Fri, 14 Jul 2023 13:24:54 +0000 (15:24 +0200)
commitb326c1bbb146b9bae38cf53243c6d272aaa1c7e3
tree683c22d96406e718e13c1bc37797c7eb7ee6008c
parent61457949686fc4472e6136c72c255b4ad003e084
platform/x86/intel/tpmi: Add debugfs interface

Add debugfs interface for debugging TPMI configuration and register
contents. This shows PFS (PM Feature structure) for each TPMI device.

For each feature, show full register contents and allow to modify
register at an offset.

This debugfs interface is not present on locked down kernel with no
DEVMEM access and without CAP_SYS_RAWIO permission.

Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20230712225950.171326-3-srinivas.pandruvada@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
drivers/platform/x86/intel/tpmi.c