]> git.baikalelectronics.ru Git - kernel.git/commit
topology/sysfs: Hide PPIN on systems that do not support it.
authorTony Luck <tony.luck@intel.com>
Wed, 6 Apr 2022 22:01:50 +0000 (15:01 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 20 Apr 2022 16:56:39 +0000 (18:56 +0200)
commita1904298a8f764b83c5b6e1641a867125c207da8
tree25f6eaeaf8e1493a5cf06969bfa3a4e249f54083
parentef8e7cd3bfb3e514a5772f2c5874cf0913238d68
topology/sysfs: Hide PPIN on systems that do not support it.

Systems that do not support a Protected Processor Identification Number
currently report:

# cat /sys/devices/system/cpu/cpu0/topology/ppin
0x0

which is confusing/wrong.

Add a ".is_visible" function to suppress inclusion of the ppin file.

Fixes: ef78f5d4dfe1 ("topology/sysfs: Add PPIN in sysfs under cpu topology")
Signed-off-by: Tony Luck <tony.luck@intel.com>
Link: https://lore.kernel.org/r/20220406220150.63855-1-tony.luck@intel.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/base/topology.c