[PATCH 0/2] soc: qcom: socinfo: Add fields in sysfs custom attributes

From: Naman Jain
Date: Wed Jan 11 2023 - 03:22:25 EST


This series adds support to have SoC info fields available in sysfs
to enable the use of these nodes in userland scripts and test scripts.
This is to provide the interface to these scripts to find the details of
parts present in the SoC and decide to execute a set of shell commands,
that are supported/required for these parts. The decision to extend sysfs
interface is taken as debugfs is not mounted by default and the use cases
for this information are not essentially for debug.

The patches add the following changes:
1. Restructure the code to make the scope of socinfo variable, from
function to file. Also, make the socinfo variable name more descriptive.
2. Extend the sysfs custom attributes to incorporate fields introduced in
socinfo format version 2 to 6. Add name mappings for hw_platform field
to make the sysfs information more descriptive.

Support for versions 7 and above will be added in future patchsets.

Also, patch 2 depends on patch 1 in the series.

Naman Jain (2):
soc: qcom: socinfo: Change socinfo variable name and scope
soc: qcom: socinfo: Add sysfs attributes for fields in v2-v6

drivers/soc/qcom/socinfo.c | 261 +++++++++++++++++++++++++++++++------
1 file changed, 223 insertions(+), 38 deletions(-)

--
2.17.1