Commit 71bb3160 authored by Alexander Duyck's avatar Alexander Duyck Committed by Jun Tian
Browse files

platform/x86: Intel PMT class driver

mainline inclusion
from mainline-v5.11-rc1
commit e2729113
category: feature
bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596K9


CVE: NA

Intel-SIG: commit e2729113 platform/x86: Intel PMT class driver.
Backport for intel PMT (Platform Monitoring Technology) support

--------------------------------

Intel Platform Monitoring Technology is meant to provide a common way to
access telemetry and system metrics.

Register mappings are not provided by the driver. Instead, a GUID is read
from a header for each endpoint. The GUID identifies the device and is to
be used with an XML, provided by the vendor, to discover the available set
of metrics and their register mapping.  This allows firmware updates to
modify the register space without needing to update the driver every time
with new mappings. Firmware writes a new GUID in this case to specify the
new mapping.  Software tools with access to the associated XML file can
then interpret the changes.

The module manages access to all Intel PMT endpoints on a system,
independent of the device exporting them. It creates an intel_pmt class
to manage the devices. For each telemetry endpoint, sysfs files provide
GUID and size information as well as a pointer to the parent device the
telemetry came from. Software may discover the association between
endpoints and devices by iterating through the list in sysfs, or by looking
for the existence of the class folder under the device of interest.  A
binary sysfs attribute of the same name allows software to then read or map
the telemetry space for direct access.

Signed-off-by: default avatarAlexander Duyck <alexander.h.duyck@linux.intel.com>
Signed-off-by: default avatarDavid E. Box <david.e.box@linux.intel.com>
Reviewed-by: default avatarHans de Goede <hdegoede@redhat.com>
Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
Signed-off-by: default avataryingbao jia <yingbao.jia@intel.com>
Signed-off-by: default avatarJun Tian <jun.j.tian@intel.com>
parent e615c710
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment