2021-09-14 14:38:29

by Mauro Carvalho Chehab

[permalink] [raw]
Subject: [PATCH v2 00/29] Change wildcards on ABI files

The ABI files are meant to be parsed via a script (scripts/get_abi.pl).

A new improvement on it will allow it to help to detect if an ABI description
is missing, or if the What: field won't match the actual location of the symbol.

In order for get_abi.pl to convert What: into regex, changes are needed on
existing ABI files, as the conversion should not be ambiguous.

One alternative would be to convert everything into regexes, but this
would generate a huge amount of patches/changes. So, instead, let's
touch only the ABI files that aren't following the de-facto wildcard
standards already found on most of the ABI files, e. g.:

/.../
*
<foo>
(option1|option2)
X
Y
Z
[0-9] (and variants)

A couple of the patches here came from v1, but most of the patches were
written to address things like rcN, where N is a wildcard.

We can't teach get_abi.pl to use an uppercase "N" letter to be a wildcard,
as the USB ABI already uses "N" inside some of their symbols, like
bNumEndpoints.

Mauro Carvalho Chehab (29):
ABI: sysfs-bus-usb: better document variable argument
ABI: sysfs-tty: better document module name parameter
ABI: sysfs-kernel-slab: use a wildcard for the cache name
ABI: security: fix location for evm and ima_policy
ABI: sysfs-class-tpm: use wildcards for pcr-* nodes
ABI: sysfs-bus-rapidio: use wildcards on What definitions
ABI: sysfs-class-cxl: place "not in a guest" at description
ABI: sysfs-class-devfreq-event: use the right wildcards on What
ABI: sysfs-class-mic: use the right wildcards on What definitions
ABI: pstore: Fix What field
ABI: sysfs-class-typec: fix a bad What field
ABI: sysfs-ata: use a proper wildcard for ata_*
ABI: sysfs-class-infiniband: use wildcards on What definitions
ABI: sysfs-bus-pci: use wildcards on What definitions
ABI: sysfs-bus-soundwire-master: use wildcards on What definitions
ABI: sysfs-bus-soundwire-slave: use wildcards on What definitions
ABI: sysfs-class-gnss: use wildcards on What definitions
ABI: sysfs-class-mei: use wildcards on What definitions
ABI: sysfs-class-mux: use wildcards on What definitions
ABI: sysfs-class-pwm: use wildcards on What definitions
ABI: sysfs-class-rc: use wildcards on What definitions
ABI: sysfs-class-rc-nuvoton: use wildcards on What definitions
ABI: sysfs-class-uwb_rc: use wildcards on What definitions
ABI: sysfs-class-uwb_rc-wusbhc: use wildcards on What definitions
ABI: sysfs-devices-platform-dock: use wildcards on What definitions
ABI: sysfs-devices-system-cpu: use wildcards on What definitions
ABI: sysfs-firmware-efi-esrt: use wildcards on What definitions
ABI: sysfs-platform-sst-atom: use wildcards on What definitions
ABI: sysfs-ptp: use wildcards on What definitions

.../ABI/stable/sysfs-class-infiniband | 64 ++++++-------
Documentation/ABI/stable/sysfs-class-tpm | 2 +-
Documentation/ABI/testing/evm | 4 +-
Documentation/ABI/testing/ima_policy | 2 +-
Documentation/ABI/testing/pstore | 3 +-
Documentation/ABI/testing/sysfs-ata | 2 +-
Documentation/ABI/testing/sysfs-bus-pci | 2 +-
Documentation/ABI/testing/sysfs-bus-rapidio | 32 +++----
.../ABI/testing/sysfs-bus-soundwire-master | 2 +-
.../ABI/testing/sysfs-bus-soundwire-slave | 2 +-
Documentation/ABI/testing/sysfs-bus-usb | 16 ++--
Documentation/ABI/testing/sysfs-class-cxl | 15 ++-
.../ABI/testing/sysfs-class-devfreq-event | 12 +--
Documentation/ABI/testing/sysfs-class-gnss | 2 +-
Documentation/ABI/testing/sysfs-class-mei | 18 ++--
Documentation/ABI/testing/sysfs-class-mic | 24 ++---
Documentation/ABI/testing/sysfs-class-mux | 2 +-
Documentation/ABI/testing/sysfs-class-pwm | 20 ++--
Documentation/ABI/testing/sysfs-class-rc | 14 +--
.../ABI/testing/sysfs-class-rc-nuvoton | 2 +-
Documentation/ABI/testing/sysfs-class-typec | 2 +-
Documentation/ABI/testing/sysfs-class-uwb_rc | 26 ++---
.../ABI/testing/sysfs-class-uwb_rc-wusbhc | 10 +-
.../ABI/testing/sysfs-devices-platform-dock | 10 +-
.../ABI/testing/sysfs-devices-system-cpu | 16 ++--
.../ABI/testing/sysfs-firmware-efi-esrt | 16 ++--
Documentation/ABI/testing/sysfs-kernel-slab | 94 +++++++++----------
.../ABI/testing/sysfs-platform-sst-atom | 2 +-
Documentation/ABI/testing/sysfs-ptp | 30 +++---
Documentation/ABI/testing/sysfs-tty | 32 +++----
30 files changed, 242 insertions(+), 236 deletions(-)

--
2.31.1



2021-09-14 14:39:06

by Mauro Carvalho Chehab

[permalink] [raw]
Subject: [PATCH v2 17/29] ABI: sysfs-class-gnss: use wildcards on What definitions

An "N" upper letter is not a wildcard, nor can easily be identified
by script, specially since the USB sysfs define things like.
bNumInterfaces. Use, instead, <N>, in order to let script/get_abi.pl
to convert it into a Regex.

Signed-off-by: Mauro Carvalho Chehab <[email protected]>
---
Documentation/ABI/testing/sysfs-class-gnss | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Documentation/ABI/testing/sysfs-class-gnss b/Documentation/ABI/testing/sysfs-class-gnss
index c8553d972edd..9650f3a7fc03 100644
--- a/Documentation/ABI/testing/sysfs-class-gnss
+++ b/Documentation/ABI/testing/sysfs-class-gnss
@@ -1,4 +1,4 @@
-What: /sys/class/gnss/gnssN/type
+What: /sys/class/gnss/gnss<N>/type
Date: May 2018
KernelVersion: 4.18
Contact: Johan Hovold <[email protected]>
--
2.31.1

2021-09-14 14:39:07

by Mauro Carvalho Chehab

[permalink] [raw]
Subject: [PATCH v2 06/29] ABI: sysfs-bus-rapidio: use wildcards on What definitions

While humans may be able to understand that something like:

/sys/bus/rapidio/devices/nn:d:iiii

could actually mean:

/sys/bus/rapidio/devices/00:e:0000

This is something that computers can't easily identify. As
get_abi.pl needs to convert it into a regex, change What: lines
to:

/sys/bus/rapidio/devices/<nn>:<d>:<iiii>

Which is the commonly-used pattern on ABI files for wildcards.

Signed-off-by: Mauro Carvalho Chehab <[email protected]>
---
Documentation/ABI/testing/sysfs-bus-rapidio | 32 ++++++++++-----------
1 file changed, 16 insertions(+), 16 deletions(-)

diff --git a/Documentation/ABI/testing/sysfs-bus-rapidio b/Documentation/ABI/testing/sysfs-bus-rapidio
index 634ea207a50a..f8b6728dac10 100644
--- a/Documentation/ABI/testing/sysfs-bus-rapidio
+++ b/Documentation/ABI/testing/sysfs-bus-rapidio
@@ -1,4 +1,4 @@
-What: /sys/bus/rapidio/devices/nn:d:iiii
+What: /sys/bus/rapidio/devices/<nn>:<d>:<iiii>
Description:
For each RapidIO device, the RapidIO subsystem creates files in
an individual subdirectory with the following name format of
@@ -29,7 +29,7 @@ Description:
Attributes Common for All RapidIO Devices
-----------------------------------------

-What: /sys/bus/rapidio/devices/nn:d:iiii/did
+What: /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/did
Date: Nov, 2005
KernelVersion: v2.6.15
Contact: Matt Porter <[email protected]>,
@@ -37,7 +37,7 @@ Contact: Matt Porter <[email protected]>,
Description:
(RO) returns the device identifier

-What: /sys/bus/rapidio/devices/nn:d:iiii/vid
+What: /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/vid
Date: Nov, 2005
KernelVersion: v2.6.15
Contact: Matt Porter <[email protected]>,
@@ -45,7 +45,7 @@ Contact: Matt Porter <[email protected]>,
Description:
(RO) returns the device vendor identifier

-What: /sys/bus/rapidio/devices/nn:d:iiii/device_rev
+What: /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/device_rev
Date: Nov, 2005
KernelVersion: v2.6.15
Contact: Matt Porter <[email protected]>,
@@ -53,7 +53,7 @@ Contact: Matt Porter <[email protected]>,
Description:
(RO) returns the device revision level

-What: /sys/bus/rapidio/devices/nn:d:iiii/asm_did
+What: /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/asm_did
Date: Nov, 2005
KernelVersion: v2.6.15
Contact: Matt Porter <[email protected]>,
@@ -61,7 +61,7 @@ Contact: Matt Porter <[email protected]>,
Description:
(RO) returns identifier for the assembly containing the device

-What: /sys/bus/rapidio/devices/nn:d:iiii/asm_rev
+What: /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/asm_rev
Date: Nov, 2005
KernelVersion: v2.6.15
Contact: Matt Porter <[email protected]>,
@@ -70,7 +70,7 @@ Description:
(RO) returns revision level of the assembly containing the
device

-What: /sys/bus/rapidio/devices/nn:d:iiii/asm_vid
+What: /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/asm_vid
Date: Nov, 2005
KernelVersion: v2.6.15
Contact: Matt Porter <[email protected]>,
@@ -79,7 +79,7 @@ Description:
(RO) returns vendor identifier of the assembly containing the
device

-What: /sys/bus/rapidio/devices/nn:d:iiii/destid
+What: /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/destid
Date: Mar, 2011
KernelVersion: v2.6.3
Contact: Matt Porter <[email protected]>,
@@ -88,7 +88,7 @@ Description:
(RO) returns device destination ID assigned by the enumeration
routine

-What: /sys/bus/rapidio/devices/nn:d:iiii/lprev
+What: /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/lprev
Date: Mar, 2011
KernelVersion: v2.6.39
Contact: Matt Porter <[email protected]>,
@@ -97,7 +97,7 @@ Description:
(RO) returns name of previous device (switch) on the path to the
device that that owns this attribute

-What: /sys/bus/rapidio/devices/nn:d:iiii/modalias
+What: /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/modalias
Date: Jul, 2013
KernelVersion: v3.11
Contact: Matt Porter <[email protected]>,
@@ -105,7 +105,7 @@ Contact: Matt Porter <[email protected]>,
Description:
(RO) returns the device modalias

-What: /sys/bus/rapidio/devices/nn:d:iiii/config
+What: /sys/bus/rapidio/devices/<nn>:<d>:<iiii>/config
Date: Nov, 2005
KernelVersion: v2.6.15
Contact: Matt Porter <[email protected]>,
@@ -128,7 +128,7 @@ device-specific sysfs attributes by specifying a callback function that may be
set by the switch initialization routine during enumeration or discovery
process.

-What: /sys/bus/rapidio/devices/nn:s:iiii/routes
+What: /sys/bus/rapidio/devices/<nn>:<s>:<iiii>/routes
Date: Nov, 2005
KernelVersion: v2.6.15
Contact: Matt Porter <[email protected]>,
@@ -138,7 +138,7 @@ Description:
This attribute reports only valid routing table entries, one
line for each entry.

-What: /sys/bus/rapidio/devices/nn:s:iiii/destid
+What: /sys/bus/rapidio/devices/<nn>:<s>:<iiii>/destid
Date: Mar, 2011
KernelVersion: v2.6.3
Contact: Matt Porter <[email protected]>,
@@ -147,7 +147,7 @@ Description:
(RO) device destination ID of the associated device that defines
a route to the switch

-What: /sys/bus/rapidio/devices/nn:s:iiii/hopcount
+What: /sys/bus/rapidio/devices/<nn>:<s>:<iiii>/hopcount
Date: Mar, 2011
KernelVersion: v2.6.39
Contact: Matt Porter <[email protected]>,
@@ -155,7 +155,7 @@ Contact: Matt Porter <[email protected]>,
Description:
(RO) number of hops on the path to the switch

-What: /sys/bus/rapidio/devices/nn:s:iiii/lnext
+What: /sys/bus/rapidio/devices/<nn>:<s>:<iiii>/lnext
Date: Mar, 2011
KernelVersion: v2.6.39
Contact: Matt Porter <[email protected]>,
@@ -172,7 +172,7 @@ Device-specific Switch Attributes

IDT_GEN2-

-What: /sys/bus/rapidio/devices/nn:s:iiii/errlog
+What: /sys/bus/rapidio/devices/<nn>:<s>:<iiii>/errlog
Date: Oct, 2010
KernelVersion: v2.6.37
Contact: Matt Porter <[email protected]>,
--
2.31.1

2021-09-14 14:39:15

by Mauro Carvalho Chehab

[permalink] [raw]
Subject: [PATCH v2 25/29] ABI: sysfs-devices-platform-dock: use wildcards on What definitions

An "N" upper letter is not a wildcard, nor can easily be identified
by script, specially since the USB sysfs define things like.
bNumInterfaces. Use, instead, <N>, in order to let script/get_abi.pl
to convert it into a Regex.

Signed-off-by: Mauro Carvalho Chehab <[email protected]>
---
Documentation/ABI/testing/sysfs-devices-platform-dock | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/Documentation/ABI/testing/sysfs-devices-platform-dock b/Documentation/ABI/testing/sysfs-devices-platform-dock
index 1d8c18f905c7..411c174de830 100644
--- a/Documentation/ABI/testing/sysfs-devices-platform-dock
+++ b/Documentation/ABI/testing/sysfs-devices-platform-dock
@@ -1,4 +1,4 @@
-What: /sys/devices/platform/dock.N/docked
+What: /sys/devices/platform/dock.<N>/docked
Date: Dec, 2006
KernelVersion: 2.6.19
Contact: [email protected]
@@ -6,7 +6,7 @@ Description:
(RO) Value 1 or 0 indicates whether the software believes the
laptop is docked in a docking station.

-What: /sys/devices/platform/dock.N/undock
+What: /sys/devices/platform/dock.<N>/undock
Date: Dec, 2006
KernelVersion: 2.6.19
Contact: [email protected]
@@ -14,14 +14,14 @@ Description:
(WO) Writing to this file causes the software to initiate an
undock request to the firmware.

-What: /sys/devices/platform/dock.N/uid
+What: /sys/devices/platform/dock.<N>/uid
Date: Feb, 2007
KernelVersion: v2.6.21
Contact: [email protected]
Description:
(RO) Displays the docking station the laptop is docked to.

-What: /sys/devices/platform/dock.N/flags
+What: /sys/devices/platform/dock.<N>/flags
Date: May, 2007
KernelVersion: v2.6.21
Contact: [email protected]
@@ -30,7 +30,7 @@ Description:
request has been made by the user (from the immediate_undock
option).

-What: /sys/devices/platform/dock.N/type
+What: /sys/devices/platform/dock.<N>/type
Date: Aug, 2008
KernelVersion: v2.6.27
Contact: [email protected]
--
2.31.1

2021-09-14 14:39:29

by Mauro Carvalho Chehab

[permalink] [raw]
Subject: [PATCH v2 03/29] ABI: sysfs-kernel-slab: use a wildcard for the cache name

the "cache" part of the description is actually a wildcard,
as, in practice, this will use per-subsystem names:

/sys/kernel/slab/Acpi-Namespace/align
/sys/kernel/slab/Acpi-Operand/align
/sys/kernel/slab/Acpi-Parse/align
...
/sys/kernel/slab/zswap_entry/align

Signed-off-by: Mauro Carvalho Chehab <[email protected]>
---
Documentation/ABI/testing/sysfs-kernel-slab | 94 ++++++++++-----------
1 file changed, 47 insertions(+), 47 deletions(-)

diff --git a/Documentation/ABI/testing/sysfs-kernel-slab b/Documentation/ABI/testing/sysfs-kernel-slab
index c9f12baf8baa..77e5840b00a5 100644
--- a/Documentation/ABI/testing/sysfs-kernel-slab
+++ b/Documentation/ABI/testing/sysfs-kernel-slab
@@ -10,7 +10,7 @@ Description:
any cache it aliases, if any).
Users: kernel memory tuning tools

-What: /sys/kernel/slab/cache/aliases
+What: /sys/kernel/slab/<cache>/aliases
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
@@ -19,7 +19,7 @@ Description:
The aliases file is read-only and specifies how many caches
have merged into this cache.

-What: /sys/kernel/slab/cache/align
+What: /sys/kernel/slab/<cache>/align
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
@@ -28,7 +28,7 @@ Description:
The align file is read-only and specifies the cache's object
alignment in bytes.

-What: /sys/kernel/slab/cache/alloc_calls
+What: /sys/kernel/slab/<cache>/alloc_calls
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
@@ -39,7 +39,7 @@ Description:
The alloc_calls file only contains information if debugging is
enabled for that cache (see Documentation/vm/slub.rst).

-What: /sys/kernel/slab/cache/alloc_fastpath
+What: /sys/kernel/slab/<cache>/alloc_fastpath
Date: February 2008
KernelVersion: 2.6.25
Contact: Pekka Enberg <[email protected]>,
@@ -50,7 +50,7 @@ Description:
current count.
Available when CONFIG_SLUB_STATS is enabled.

-What: /sys/kernel/slab/cache/alloc_from_partial
+What: /sys/kernel/slab/<cache>/alloc_from_partial
Date: February 2008
KernelVersion: 2.6.25
Contact: Pekka Enberg <[email protected]>,
@@ -62,7 +62,7 @@ Description:
count.
Available when CONFIG_SLUB_STATS is enabled.

-What: /sys/kernel/slab/cache/alloc_refill
+What: /sys/kernel/slab/<cache>/alloc_refill
Date: February 2008
KernelVersion: 2.6.25
Contact: Pekka Enberg <[email protected]>,
@@ -73,7 +73,7 @@ Description:
remote cpu frees. It can be written to clear the current count.
Available when CONFIG_SLUB_STATS is enabled.

-What: /sys/kernel/slab/cache/alloc_slab
+What: /sys/kernel/slab/<cache>/alloc_slab
Date: February 2008
KernelVersion: 2.6.25
Contact: Pekka Enberg <[email protected]>,
@@ -84,7 +84,7 @@ Description:
clear the current count.
Available when CONFIG_SLUB_STATS is enabled.

-What: /sys/kernel/slab/cache/alloc_slowpath
+What: /sys/kernel/slab/<cache>/alloc_slowpath
Date: February 2008
KernelVersion: 2.6.25
Contact: Pekka Enberg <[email protected]>,
@@ -96,7 +96,7 @@ Description:
clear the current count.
Available when CONFIG_SLUB_STATS is enabled.

-What: /sys/kernel/slab/cache/cache_dma
+What: /sys/kernel/slab/<cache>/cache_dma
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
@@ -106,7 +106,7 @@ Description:
are from ZONE_DMA.
Available when CONFIG_ZONE_DMA is enabled.

-What: /sys/kernel/slab/cache/cpu_slabs
+What: /sys/kernel/slab/<cache>/cpu_slabs
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
@@ -115,7 +115,7 @@ Description:
The cpu_slabs file is read-only and displays how many cpu slabs
are active and their NUMA locality.

-What: /sys/kernel/slab/cache/cpuslab_flush
+What: /sys/kernel/slab/<cache>/cpuslab_flush
Date: April 2009
KernelVersion: 2.6.31
Contact: Pekka Enberg <[email protected]>,
@@ -128,7 +128,7 @@ Description:
current count.
Available when CONFIG_SLUB_STATS is enabled.

-What: /sys/kernel/slab/cache/ctor
+What: /sys/kernel/slab/<cache>/ctor
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
@@ -138,7 +138,7 @@ Description:
constructor function, which is invoked for each object when a
new slab is allocated.

-What: /sys/kernel/slab/cache/deactivate_empty
+What: /sys/kernel/slab/<cache>/deactivate_empty
Date: February 2008
KernelVersion: 2.6.25
Contact: Pekka Enberg <[email protected]>,
@@ -148,7 +148,7 @@ Description:
was deactivated. It can be written to clear the current count.
Available when CONFIG_SLUB_STATS is enabled.

-What: /sys/kernel/slab/cache/deactivate_full
+What: /sys/kernel/slab/<cache>/deactivate_full
Date: February 2008
KernelVersion: 2.6.25
Contact: Pekka Enberg <[email protected]>,
@@ -158,7 +158,7 @@ Description:
was deactivated. It can be written to clear the current count.
Available when CONFIG_SLUB_STATS is enabled.

-What: /sys/kernel/slab/cache/deactivate_remote_frees
+What: /sys/kernel/slab/<cache>/deactivate_remote_frees
Date: February 2008
KernelVersion: 2.6.25
Contact: Pekka Enberg <[email protected]>,
@@ -169,7 +169,7 @@ Description:
remotely. It can be written to clear the current count.
Available when CONFIG_SLUB_STATS is enabled.

-What: /sys/kernel/slab/cache/deactivate_to_head
+What: /sys/kernel/slab/<cache>/deactivate_to_head
Date: February 2008
KernelVersion: 2.6.25
Contact: Pekka Enberg <[email protected]>,
@@ -180,7 +180,7 @@ Description:
list. It can be written to clear the current count.
Available when CONFIG_SLUB_STATS is enabled.

-What: /sys/kernel/slab/cache/deactivate_to_tail
+What: /sys/kernel/slab/<cache>/deactivate_to_tail
Date: February 2008
KernelVersion: 2.6.25
Contact: Pekka Enberg <[email protected]>,
@@ -191,7 +191,7 @@ Description:
list. It can be written to clear the current count.
Available when CONFIG_SLUB_STATS is enabled.

-What: /sys/kernel/slab/cache/destroy_by_rcu
+What: /sys/kernel/slab/<cache>/destroy_by_rcu
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
@@ -200,7 +200,7 @@ Description:
The destroy_by_rcu file is read-only and specifies whether
slabs (not objects) are freed by rcu.

-What: /sys/kernel/slab/cache/free_add_partial
+What: /sys/kernel/slab/<cache>/free_add_partial
Date: February 2008
KernelVersion: 2.6.25
Contact: Pekka Enberg <[email protected]>,
@@ -211,7 +211,7 @@ Description:
partial list. It can be written to clear the current count.
Available when CONFIG_SLUB_STATS is enabled.

-What: /sys/kernel/slab/cache/free_calls
+What: /sys/kernel/slab/<cache>/free_calls
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
@@ -221,7 +221,7 @@ Description:
object frees if slab debugging is enabled (see
Documentation/vm/slub.rst).

-What: /sys/kernel/slab/cache/free_fastpath
+What: /sys/kernel/slab/<cache>/free_fastpath
Date: February 2008
KernelVersion: 2.6.25
Contact: Pekka Enberg <[email protected]>,
@@ -232,7 +232,7 @@ Description:
It can be written to clear the current count.
Available when CONFIG_SLUB_STATS is enabled.

-What: /sys/kernel/slab/cache/free_frozen
+What: /sys/kernel/slab/<cache>/free_frozen
Date: February 2008
KernelVersion: 2.6.25
Contact: Pekka Enberg <[email protected]>,
@@ -243,7 +243,7 @@ Description:
clear the current count.
Available when CONFIG_SLUB_STATS is enabled.

-What: /sys/kernel/slab/cache/free_remove_partial
+What: /sys/kernel/slab/<cache>/free_remove_partial
Date: February 2008
KernelVersion: 2.6.25
Contact: Pekka Enberg <[email protected]>,
@@ -255,7 +255,7 @@ Description:
count.
Available when CONFIG_SLUB_STATS is enabled.

-What: /sys/kernel/slab/cache/free_slab
+What: /sys/kernel/slab/<cache>/free_slab
Date: February 2008
KernelVersion: 2.6.25
Contact: Pekka Enberg <[email protected]>,
@@ -266,7 +266,7 @@ Description:
the current count.
Available when CONFIG_SLUB_STATS is enabled.

-What: /sys/kernel/slab/cache/free_slowpath
+What: /sys/kernel/slab/<cache>/free_slowpath
Date: February 2008
KernelVersion: 2.6.25
Contact: Pekka Enberg <[email protected]>,
@@ -277,7 +277,7 @@ Description:
be written to clear the current count.
Available when CONFIG_SLUB_STATS is enabled.

-What: /sys/kernel/slab/cache/hwcache_align
+What: /sys/kernel/slab/<cache>/hwcache_align
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
@@ -286,7 +286,7 @@ Description:
The hwcache_align file is read-only and specifies whether
objects are aligned on cachelines.

-What: /sys/kernel/slab/cache/min_partial
+What: /sys/kernel/slab/<cache>/min_partial
Date: February 2009
KernelVersion: 2.6.30
Contact: Pekka Enberg <[email protected]>,
@@ -297,7 +297,7 @@ Description:
allocating new slabs. Such slabs may be reclaimed by utilizing
the shrink file.

-What: /sys/kernel/slab/cache/object_size
+What: /sys/kernel/slab/<cache>/object_size
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
@@ -306,7 +306,7 @@ Description:
The object_size file is read-only and specifies the cache's
object size.

-What: /sys/kernel/slab/cache/objects
+What: /sys/kernel/slab/<cache>/objects
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
@@ -315,7 +315,7 @@ Description:
The objects file is read-only and displays how many objects are
active and from which nodes they are from.

-What: /sys/kernel/slab/cache/objects_partial
+What: /sys/kernel/slab/<cache>/objects_partial
Date: April 2008
KernelVersion: 2.6.26
Contact: Pekka Enberg <[email protected]>,
@@ -325,7 +325,7 @@ Description:
objects are on partial slabs and from which nodes they are
from.

-What: /sys/kernel/slab/cache/objs_per_slab
+What: /sys/kernel/slab/<cache>/objs_per_slab
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
@@ -333,9 +333,9 @@ Contact: Pekka Enberg <[email protected]>,
Description:
The file objs_per_slab is read-only and specifies how many
objects may be allocated from a single slab of the order
- specified in /sys/kernel/slab/cache/order.
+ specified in /sys/kernel/slab/<cache>/order.

-What: /sys/kernel/slab/cache/order
+What: /sys/kernel/slab/<cache>/order
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
@@ -352,7 +352,7 @@ Description:
order is used and this sysfs entry can not be used to change
the order at run time.

-What: /sys/kernel/slab/cache/order_fallback
+What: /sys/kernel/slab/<cache>/order_fallback
Date: April 2008
KernelVersion: 2.6.26
Contact: Pekka Enberg <[email protected]>,
@@ -365,7 +365,7 @@ Description:

Available when CONFIG_SLUB_STATS is enabled.

-What: /sys/kernel/slab/cache/partial
+What: /sys/kernel/slab/<cache>/partial
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
@@ -374,7 +374,7 @@ Description:
The partial file is read-only and displays how long many
partial slabs there are and how long each node's list is.

-What: /sys/kernel/slab/cache/poison
+What: /sys/kernel/slab/<cache>/poison
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
@@ -383,7 +383,7 @@ Description:
The poison file specifies whether objects should be poisoned
when a new slab is allocated.

-What: /sys/kernel/slab/cache/reclaim_account
+What: /sys/kernel/slab/<cache>/reclaim_account
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
@@ -392,7 +392,7 @@ Description:
The reclaim_account file specifies whether the cache's objects
are reclaimable (and grouped by their mobility).

-What: /sys/kernel/slab/cache/red_zone
+What: /sys/kernel/slab/<cache>/red_zone
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
@@ -401,7 +401,7 @@ Description:
The red_zone file specifies whether the cache's objects are red
zoned.

-What: /sys/kernel/slab/cache/remote_node_defrag_ratio
+What: /sys/kernel/slab/<cache>/remote_node_defrag_ratio
Date: January 2008
KernelVersion: 2.6.25
Contact: Pekka Enberg <[email protected]>,
@@ -415,7 +415,7 @@ Description:

Available when CONFIG_NUMA is enabled.

-What: /sys/kernel/slab/cache/sanity_checks
+What: /sys/kernel/slab/<cache>/sanity_checks
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
@@ -426,7 +426,7 @@ Description:
checks. Caches that enable sanity_checks cannot be merged with
caches that do not.

-What: /sys/kernel/slab/cache/shrink
+What: /sys/kernel/slab/<cache>/shrink
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
@@ -442,7 +442,7 @@ Description:
adversely impact other running applications. So it
should be used with care.

-What: /sys/kernel/slab/cache/slab_size
+What: /sys/kernel/slab/<cache>/slab_size
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
@@ -451,7 +451,7 @@ Description:
The slab_size file is read-only and specifies the object size
with metadata (debugging information and alignment) in bytes.

-What: /sys/kernel/slab/cache/slabs
+What: /sys/kernel/slab/<cache>/slabs
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
@@ -461,7 +461,7 @@ Description:
there are (both cpu and partial) and from which nodes they are
from.

-What: /sys/kernel/slab/cache/store_user
+What: /sys/kernel/slab/<cache>/store_user
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
@@ -470,7 +470,7 @@ Description:
The store_user file specifies whether the location of
allocation or free should be tracked for a cache.

-What: /sys/kernel/slab/cache/total_objects
+What: /sys/kernel/slab/<cache>/total_objects
Date: April 2008
KernelVersion: 2.6.26
Contact: Pekka Enberg <[email protected]>,
@@ -479,7 +479,7 @@ Description:
The total_objects file is read-only and displays how many total
objects a cache has and from which nodes they are from.

-What: /sys/kernel/slab/cache/trace
+What: /sys/kernel/slab/<cache>/trace
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
@@ -488,7 +488,7 @@ Description:
The trace file specifies whether object allocations and frees
should be traced.

-What: /sys/kernel/slab/cache/validate
+What: /sys/kernel/slab/<cache>/validate
Date: May 2007
KernelVersion: 2.6.22
Contact: Pekka Enberg <[email protected]>,
--
2.31.1

2021-09-14 14:39:34

by Mauro Carvalho Chehab

[permalink] [raw]
Subject: [PATCH v2 02/29] ABI: sysfs-tty: better document module name parameter

On almost all ABI documents, variable arguments are declared
as <foo_bar>. Change it here too, in order to allow replacing
such wildcards by regexes on a scriptable way.

Signed-off-by: Mauro Carvalho Chehab <[email protected]>
---
Documentation/ABI/testing/sysfs-tty | 32 ++++++++++++++---------------
1 file changed, 16 insertions(+), 16 deletions(-)

diff --git a/Documentation/ABI/testing/sysfs-tty b/Documentation/ABI/testing/sysfs-tty
index e157130a6792..820e412d38a8 100644
--- a/Documentation/ABI/testing/sysfs-tty
+++ b/Documentation/ABI/testing/sysfs-tty
@@ -9,7 +9,7 @@ Description:
The file supports poll() to detect virtual
console switches.

-What: /sys/class/tty/tty0/active
+What: /sys/class/tty/tty<x>/active
Date: Nov 2010
Contact: Kay Sievers <[email protected]>
Description:
@@ -18,7 +18,7 @@ Description:
The file supports poll() to detect virtual
console switches.

-What: /sys/class/tty/ttyS0/uartclk
+What: /sys/class/tty/ttyS<x>/uartclk
Date: Sep 2012
Contact: Tomas Hlavacek <[email protected]>
Description:
@@ -29,7 +29,7 @@ Description:
These sysfs values expose the TIOCGSERIAL interface via
sysfs rather than via ioctls.

-What: /sys/class/tty/ttyS0/type
+What: /sys/class/tty/ttyS<x>/type
Date: October 2012
Contact: Alan Cox <[email protected]>
Description:
@@ -38,7 +38,7 @@ Description:
These sysfs values expose the TIOCGSERIAL interface via
sysfs rather than via ioctls.

-What: /sys/class/tty/ttyS0/line
+What: /sys/class/tty/ttyS<x>/line
Date: October 2012
Contact: Alan Cox <[email protected]>
Description:
@@ -47,7 +47,7 @@ Description:
These sysfs values expose the TIOCGSERIAL interface via
sysfs rather than via ioctls.

-What: /sys/class/tty/ttyS0/port
+What: /sys/class/tty/ttyS<x>/port
Date: October 2012
Contact: Alan Cox <[email protected]>
Description:
@@ -56,7 +56,7 @@ Description:
These sysfs values expose the TIOCGSERIAL interface via
sysfs rather than via ioctls.

-What: /sys/class/tty/ttyS0/irq
+What: /sys/class/tty/ttyS<x>/irq
Date: October 2012
Contact: Alan Cox <[email protected]>
Description:
@@ -65,7 +65,7 @@ Description:
These sysfs values expose the TIOCGSERIAL interface via
sysfs rather than via ioctls.

-What: /sys/class/tty/ttyS0/flags
+What: /sys/class/tty/ttyS<x>/flags
Date: October 2012
Contact: Alan Cox <[email protected]>
Description:
@@ -74,7 +74,7 @@ Description:
These sysfs values expose the TIOCGSERIAL interface via
sysfs rather than via ioctls.

-What: /sys/class/tty/ttyS0/xmit_fifo_size
+What: /sys/class/tty/ttyS<x>/xmit_fifo_size
Date: October 2012
Contact: Alan Cox <[email protected]>
Description:
@@ -83,7 +83,7 @@ Description:
These sysfs values expose the TIOCGSERIAL interface via
sysfs rather than via ioctls.

-What: /sys/class/tty/ttyS0/close_delay
+What: /sys/class/tty/ttyS<x>/close_delay
Date: October 2012
Contact: Alan Cox <[email protected]>
Description:
@@ -92,7 +92,7 @@ Description:
These sysfs values expose the TIOCGSERIAL interface via
sysfs rather than via ioctls.

-What: /sys/class/tty/ttyS0/closing_wait
+What: /sys/class/tty/ttyS<x>/closing_wait
Date: October 2012
Contact: Alan Cox <[email protected]>
Description:
@@ -101,7 +101,7 @@ Description:
These sysfs values expose the TIOCGSERIAL interface via
sysfs rather than via ioctls.

-What: /sys/class/tty/ttyS0/custom_divisor
+What: /sys/class/tty/ttyS<x>/custom_divisor
Date: October 2012
Contact: Alan Cox <[email protected]>
Description:
@@ -110,7 +110,7 @@ Description:
These sysfs values expose the TIOCGSERIAL interface via
sysfs rather than via ioctls.

-What: /sys/class/tty/ttyS0/io_type
+What: /sys/class/tty/ttyS<x>/io_type
Date: October 2012
Contact: Alan Cox <[email protected]>
Description:
@@ -120,7 +120,7 @@ Description:
These sysfs values expose the TIOCGSERIAL interface via
sysfs rather than via ioctls.

-What: /sys/class/tty/ttyS0/iomem_base
+What: /sys/class/tty/ttyS<x>/iomem_base
Date: October 2012
Contact: Alan Cox <[email protected]>
Description:
@@ -129,7 +129,7 @@ Description:
These sysfs values expose the TIOCGSERIAL interface via
sysfs rather than via ioctls.

-What: /sys/class/tty/ttyS0/iomem_reg_shift
+What: /sys/class/tty/ttyS<x>/iomem_reg_shift
Date: October 2012
Contact: Alan Cox <[email protected]>
Description:
@@ -139,7 +139,7 @@ Description:
These sysfs values expose the TIOCGSERIAL interface via
sysfs rather than via ioctls.

-What: /sys/class/tty/ttyS0/rx_trig_bytes
+What: /sys/class/tty/ttyS<x>/rx_trig_bytes
Date: May 2014
Contact: Yoshihiro YUNOMAE <[email protected]>
Description:
@@ -155,7 +155,7 @@ Description:
16550A, which has 1/4/8/14 bytes trigger, the RX trigger is
automatically changed to 4 bytes.

-What: /sys/class/tty/ttyS0/console
+What: /sys/class/tty/ttyS<x>/console
Date: February 2020
Contact: Andy Shevchenko <[email protected]>
Description:
--
2.31.1

2021-09-14 14:39:52

by Mauro Carvalho Chehab

[permalink] [raw]
Subject: [PATCH v2 10/29] ABI: pstore: Fix What field

If both /sys/fs/pstore/... and /dev/pstore/... are possible,
it should use, instead, two What: fields.

Signed-off-by: Mauro Carvalho Chehab <[email protected]>
---
Documentation/ABI/testing/pstore | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/Documentation/ABI/testing/pstore b/Documentation/ABI/testing/pstore
index 5b02540781a2..d3cff4a7ee10 100644
--- a/Documentation/ABI/testing/pstore
+++ b/Documentation/ABI/testing/pstore
@@ -1,4 +1,5 @@
-What: /sys/fs/pstore/... (or /dev/pstore/...)
+What: /sys/fs/pstore/...
+What: /dev/pstore/...
Date: March 2011
KernelVersion: 2.6.39
Contact: [email protected]
--
2.31.1

2021-09-14 14:40:28

by Mauro Carvalho Chehab

[permalink] [raw]
Subject: [PATCH v2 07/29] ABI: sysfs-class-cxl: place "not in a guest" at description

The What: field should have just the location of the ABI.
Anything else should be inside the description.

This fixes its parsing by get_abi.pl script.

Signed-off-by: Mauro Carvalho Chehab <[email protected]>
---
Documentation/ABI/testing/sysfs-class-cxl | 15 ++++++++++-----
1 file changed, 10 insertions(+), 5 deletions(-)

diff --git a/Documentation/ABI/testing/sysfs-class-cxl b/Documentation/ABI/testing/sysfs-class-cxl
index 818f55970efb..3c77677e0ca7 100644
--- a/Documentation/ABI/testing/sysfs-class-cxl
+++ b/Documentation/ABI/testing/sysfs-class-cxl
@@ -166,10 +166,11 @@ Description: read only
Decimal value of the Per Process MMIO space length.
Users: https://github.com/ibm-capi/libcxl

-What: /sys/class/cxl/<afu>m/pp_mmio_off (not in a guest)
+What: /sys/class/cxl/<afu>m/pp_mmio_off
Date: September 2014
Contact: [email protected]
Description: read only
+ (not in a guest)
Decimal value of the Per Process MMIO space offset.
Users: https://github.com/ibm-capi/libcxl

@@ -190,28 +191,31 @@ Description: read only
Identifies the revision level of the PSL.
Users: https://github.com/ibm-capi/libcxl

-What: /sys/class/cxl/<card>/base_image (not in a guest)
+What: /sys/class/cxl/<card>/base_image
Date: September 2014
Contact: [email protected]
Description: read only
+ (not in a guest)
Identifies the revision level of the base image for devices
that support loadable PSLs. For FPGAs this field identifies
the image contained in the on-adapter flash which is loaded
during the initial program load.
Users: https://github.com/ibm-capi/libcxl

-What: /sys/class/cxl/<card>/image_loaded (not in a guest)
+What: /sys/class/cxl/<card>/image_loaded
Date: September 2014
Contact: [email protected]
Description: read only
+ (not in a guest)
Will return "user" or "factory" depending on the image loaded
onto the card.
Users: https://github.com/ibm-capi/libcxl

-What: /sys/class/cxl/<card>/load_image_on_perst (not in a guest)
+What: /sys/class/cxl/<card>/load_image_on_perst
Date: December 2014
Contact: [email protected]
Description: read/write
+ (not in a guest)
Valid entries are "none", "user", and "factory".
"none" means PERST will not cause image to be loaded to the
card. A power cycle is required to load the image.
@@ -235,10 +239,11 @@ Description: write only
contexts on the card AFUs.
Users: https://github.com/ibm-capi/libcxl

-What: /sys/class/cxl/<card>/perst_reloads_same_image (not in a guest)
+What: /sys/class/cxl/<card>/perst_reloads_same_image
Date: July 2015
Contact: [email protected]
Description: read/write
+ (not in a guest)
Trust that when an image is reloaded via PERST, it will not
have changed.

--
2.31.1

2021-09-14 14:40:45

by Mauro Carvalho Chehab

[permalink] [raw]
Subject: [PATCH v2 20/29] ABI: sysfs-class-pwm: use wildcards on What definitions

An "N" upper letter is not a wildcard, nor can easily be identified
by script, specially since the USB sysfs define things like.
bNumInterfaces. Use, instead, <N>, in order to let script/get_abi.pl
to convert it into a Regex.

Signed-off-by: Mauro Carvalho Chehab <[email protected]>
---
Documentation/ABI/testing/sysfs-class-pwm | 20 ++++++++++----------
1 file changed, 10 insertions(+), 10 deletions(-)

diff --git a/Documentation/ABI/testing/sysfs-class-pwm b/Documentation/ABI/testing/sysfs-class-pwm
index c20e61354561..3d65285bcd5f 100644
--- a/Documentation/ABI/testing/sysfs-class-pwm
+++ b/Documentation/ABI/testing/sysfs-class-pwm
@@ -7,7 +7,7 @@ Description:
Framework and provides a sysfs interface for using PWM
channels.

-What: /sys/class/pwm/pwmchipN/
+What: /sys/class/pwm/pwmchip<N>/
Date: May 2013
KernelVersion: 3.11
Contact: H Hartley Sweeten <[email protected]>
@@ -16,14 +16,14 @@ Description:
probed PWM controller/chip where N is the base of the
PWM chip.

-What: /sys/class/pwm/pwmchipN/npwm
+What: /sys/class/pwm/pwmchip<N>/npwm
Date: May 2013
KernelVersion: 3.11
Contact: H Hartley Sweeten <[email protected]>
Description:
The number of PWM channels supported by the PWM chip.

-What: /sys/class/pwm/pwmchipN/export
+What: /sys/class/pwm/pwmchip<N>/export
Date: May 2013
KernelVersion: 3.11
Contact: H Hartley Sweeten <[email protected]>
@@ -31,14 +31,14 @@ Description:
Exports a PWM channel from the PWM chip for sysfs control.
Value is between 0 and /sys/class/pwm/pwmchipN/npwm - 1.

-What: /sys/class/pwm/pwmchipN/unexport
+What: /sys/class/pwm/pwmchip<N>/unexport
Date: May 2013
KernelVersion: 3.11
Contact: H Hartley Sweeten <[email protected]>
Description:
Unexports a PWM channel.

-What: /sys/class/pwm/pwmchipN/pwmX
+What: /sys/class/pwm/pwmchip<N>/pwmX
Date: May 2013
KernelVersion: 3.11
Contact: H Hartley Sweeten <[email protected]>
@@ -47,21 +47,21 @@ Description:
each exported PWM channel where X is the exported PWM
channel number.

-What: /sys/class/pwm/pwmchipN/pwmX/period
+What: /sys/class/pwm/pwmchip<N>/pwmX/period
Date: May 2013
KernelVersion: 3.11
Contact: H Hartley Sweeten <[email protected]>
Description:
Sets the PWM signal period in nanoseconds.

-What: /sys/class/pwm/pwmchipN/pwmX/duty_cycle
+What: /sys/class/pwm/pwmchip<N>/pwmX/duty_cycle
Date: May 2013
KernelVersion: 3.11
Contact: H Hartley Sweeten <[email protected]>
Description:
Sets the PWM signal duty cycle in nanoseconds.

-What: /sys/class/pwm/pwmchipN/pwmX/polarity
+What: /sys/class/pwm/pwmchip<N>/pwmX/polarity
Date: May 2013
KernelVersion: 3.11
Contact: H Hartley Sweeten <[email protected]>
@@ -69,7 +69,7 @@ Description:
Sets the output polarity of the PWM signal to "normal" or
"inversed".

-What: /sys/class/pwm/pwmchipN/pwmX/enable
+What: /sys/class/pwm/pwmchip<N>/pwmX/enable
Date: May 2013
KernelVersion: 3.11
Contact: H Hartley Sweeten <[email protected]>
@@ -78,7 +78,7 @@ Description:
0 is disabled
1 is enabled

-What: /sys/class/pwm/pwmchipN/pwmX/capture
+What: /sys/class/pwm/pwmchip<N>/pwmX/capture
Date: June 2016
KernelVersion: 4.8
Contact: Lee Jones <[email protected]>
--
2.31.1

2021-09-14 14:40:52

by Mauro Carvalho Chehab

[permalink] [raw]
Subject: [PATCH v2 05/29] ABI: sysfs-class-tpm: use wildcards for pcr-* nodes

Change how this expression is defined:

/sys/class/tpm/tpmX/pcr-H/N

in order to allow get_abi.pl to convert it into this regex:

/sys/class/tpm/tpmX/pcr-.*/.*

Signed-off-by: Mauro Carvalho Chehab <[email protected]>
---
Documentation/ABI/stable/sysfs-class-tpm | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Documentation/ABI/stable/sysfs-class-tpm b/Documentation/ABI/stable/sysfs-class-tpm
index d897ecb9615f..411d5895bed4 100644
--- a/Documentation/ABI/stable/sysfs-class-tpm
+++ b/Documentation/ABI/stable/sysfs-class-tpm
@@ -195,7 +195,7 @@ Description: The "tpm_version_major" property shows the TCG spec major version

2

-What: /sys/class/tpm/tpmX/pcr-H/N
+What: /sys/class/tpm/tpmX/pcr-<H>/<N>
Date: March 2021
KernelVersion: 5.12
Contact: [email protected]
--
2.31.1

2021-09-14 14:41:05

by Mauro Carvalho Chehab

[permalink] [raw]
Subject: [PATCH v2 23/29] ABI: sysfs-class-uwb_rc: use wildcards on What definitions

An "N" upper letter is not a wildcard, nor can easily be identified
by script, specially since the USB sysfs define things like.
bNumInterfaces. Use, instead, <N>, in order to let script/get_abi.pl
to convert it into a Regex.

Signed-off-by: Mauro Carvalho Chehab <[email protected]>
---
Documentation/ABI/testing/sysfs-class-uwb_rc | 26 ++++++++++----------
1 file changed, 13 insertions(+), 13 deletions(-)

diff --git a/Documentation/ABI/testing/sysfs-class-uwb_rc b/Documentation/ABI/testing/sysfs-class-uwb_rc
index 6c5dcad21e19..a7ea169dc4eb 100644
--- a/Documentation/ABI/testing/sysfs-class-uwb_rc
+++ b/Documentation/ABI/testing/sysfs-class-uwb_rc
@@ -18,14 +18,14 @@ Description:
and it will be removed. The default is 3 superframes
(~197 ms) as required by the specification.

-What: /sys/class/uwb_rc/uwbN/
+What: /sys/class/uwb_rc/uwb<N>/
Date: July 2008
KernelVersion: 2.6.27
Contact: [email protected]
Description:
An individual UWB radio controller.

-What: /sys/class/uwb_rc/uwbN/beacon
+What: /sys/class/uwb_rc/uwb<N>/beacon
Date: July 2008
KernelVersion: 2.6.27
Contact: [email protected]
@@ -43,7 +43,7 @@ Description:
Reading returns the currently active channel, or -1 if
the radio controller is not beaconing.

-What: /sys/class/uwb_rc/uwbN/ASIE
+What: /sys/class/uwb_rc/uwb<N>/ASIE
Date: August 2014
KernelVersion: 3.18
Contact: [email protected]
@@ -56,7 +56,7 @@ Description:
Reading returns the current ASIE. Writing replaces
the current ASIE with the one written.

-What: /sys/class/uwb_rc/uwbN/scan
+What: /sys/class/uwb_rc/uwb<N>/scan
Date: July 2008
KernelVersion: 2.6.27
Contact: [email protected]
@@ -75,7 +75,7 @@ Description:
4 scan (with start time of <bpst offset>)
== =======================================

-What: /sys/class/uwb_rc/uwbN/mac_address
+What: /sys/class/uwb_rc/uwb<N>/mac_address
Date: July 2008
KernelVersion: 2.6.27
Contact: [email protected]
@@ -85,7 +85,7 @@ Description:
controller's EUI-48 but only do so while the device is
not beaconing or scanning.

-What: /sys/class/uwb_rc/uwbN/wusbhc
+What: /sys/class/uwb_rc/uwb<N>/wusbhc
Date: July 2008
KernelVersion: 2.6.27
Contact: [email protected]
@@ -93,7 +93,7 @@ Description:
A symlink to the device (if any) of the WUSB Host
Controller PAL using this radio controller.

-What: /sys/class/uwb_rc/uwbN/<EUI-48>/
+What: /sys/class/uwb_rc/uwb<N>/<EUI-48>/
Date: July 2008
KernelVersion: 2.6.27
Contact: [email protected]
@@ -102,7 +102,7 @@ Description:
as part of a scan or is a member of the radio
controllers beacon group.

-What: /sys/class/uwb_rc/uwbN/<EUI-48>/BPST
+What: /sys/class/uwb_rc/uwb<N>/<EUI-48>/BPST
Date: July 2008
KernelVersion: 2.6.27
Contact: [email protected]
@@ -111,7 +111,7 @@ Description:
interval superframe timer) of the last beacon from
this device was received.

-What: /sys/class/uwb_rc/uwbN/<EUI-48>/DevAddr
+What: /sys/class/uwb_rc/uwb<N>/<EUI-48>/DevAddr
Date: July 2008
KernelVersion: 2.6.27
Contact: [email protected]
@@ -119,7 +119,7 @@ Description:
The current DevAddr of this device in colon separated
hex octets.

-What: /sys/class/uwb_rc/uwbN/<EUI-48>/EUI_48
+What: /sys/class/uwb_rc/uwb<N>/<EUI-48>/EUI_48
Date: July 2008
KernelVersion: 2.6.27
Contact: [email protected]
@@ -128,7 +128,7 @@ Description:
The EUI-48 of this device in colon separated hex
octets.

-What: /sys/class/uwb_rc/uwbN/<EUI-48>/IEs
+What: /sys/class/uwb_rc/uwb<N>/<EUI-48>/IEs
Date: July 2008
KernelVersion: 2.6.27
Contact: [email protected]
@@ -136,7 +136,7 @@ Description:
The latest IEs included in this device's beacon, in
space separated hex octets with one IE per line.

-What: /sys/class/uwb_rc/uwbN/<EUI-48>/LQE
+What: /sys/class/uwb_rc/uwb<N>/<EUI-48>/LQE
Date: July 2008
KernelVersion: 2.6.27
Contact: [email protected]
@@ -146,7 +146,7 @@ Description:
This gives an estimate on a suitable PHY rate. Refer
to [ECMA-368] section 13.3 for more details.

-What: /sys/class/uwb_rc/uwbN/<EUI-48>/RSSI
+What: /sys/class/uwb_rc/uwb<N>/<EUI-48>/RSSI
Date: July 2008
KernelVersion: 2.6.27
Contact: [email protected]
--
2.31.1

2021-09-14 14:41:06

by Mauro Carvalho Chehab

[permalink] [raw]
Subject: [PATCH v2 24/29] ABI: sysfs-class-uwb_rc-wusbhc: use wildcards on What definitions

An "N" upper letter is not a wildcard, nor can easily be identified
by script, specially since the USB sysfs define things like.
bNumInterfaces. Use, instead, <N>, in order to let script/get_abi.pl
to convert it into a Regex.

Signed-off-by: Mauro Carvalho Chehab <[email protected]>
---
Documentation/ABI/testing/sysfs-class-uwb_rc-wusbhc | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/Documentation/ABI/testing/sysfs-class-uwb_rc-wusbhc b/Documentation/ABI/testing/sysfs-class-uwb_rc-wusbhc
index 5977e2875325..55eb55cac92e 100644
--- a/Documentation/ABI/testing/sysfs-class-uwb_rc-wusbhc
+++ b/Documentation/ABI/testing/sysfs-class-uwb_rc-wusbhc
@@ -1,4 +1,4 @@
-What: /sys/class/uwb_rc/uwbN/wusbhc/wusb_chid
+What: /sys/class/uwb_rc/uwb<N>/wusbhc/wusb_chid
Date: July 2008
KernelVersion: 2.6.27
Contact: David Vrabel <[email protected]>
@@ -9,7 +9,7 @@ Description:

Set an all zero CHID to stop the host controller.

-What: /sys/class/uwb_rc/uwbN/wusbhc/wusb_trust_timeout
+What: /sys/class/uwb_rc/uwb<N>/wusbhc/wusb_trust_timeout
Date: July 2008
KernelVersion: 2.6.27
Contact: David Vrabel <[email protected]>
@@ -24,7 +24,7 @@ Description:
lifetime of PTKs and GTKs) it should not be changed
from the default.

-What: /sys/class/uwb_rc/uwbN/wusbhc/wusb_phy_rate
+What: /sys/class/uwb_rc/uwb<N>/wusbhc/wusb_phy_rate
Date: August 2009
KernelVersion: 2.6.32
Contact: David Vrabel <[email protected]>
@@ -37,7 +37,7 @@ Description:
Refer to [ECMA-368] section 10.3.1.1 for the value to
use.

-What: /sys/class/uwb_rc/uwbN/wusbhc/wusb_dnts
+What: /sys/class/uwb_rc/uwb<N>/wusbhc/wusb_dnts
Date: June 2013
KernelVersion: 3.11
Contact: Thomas Pugliese <[email protected]>
@@ -47,7 +47,7 @@ Description:
often the devices will have the opportunity to send
notifications to the host.

-What: /sys/class/uwb_rc/uwbN/wusbhc/wusb_retry_count
+What: /sys/class/uwb_rc/uwb<N>/wusbhc/wusb_retry_count
Date: June 2013
KernelVersion: 3.11
Contact: Thomas Pugliese <[email protected]>
--
2.31.1

2021-09-14 14:41:15

by Mauro Carvalho Chehab

[permalink] [raw]
Subject: [PATCH v2 16/29] ABI: sysfs-bus-soundwire-slave: use wildcards on What definitions

An "N" upper letter is not a wildcard, nor can easily be identified
by script, specially since the USB sysfs define things like.
bNumInterfaces. Use, instead, <N>, in order to let script/get_abi.pl
to convert it into a Regex.

Signed-off-by: Mauro Carvalho Chehab <[email protected]>
---
Documentation/ABI/testing/sysfs-bus-soundwire-slave | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Documentation/ABI/testing/sysfs-bus-soundwire-slave b/Documentation/ABI/testing/sysfs-bus-soundwire-slave
index d324aa0b678f..db6b8ffa753e 100644
--- a/Documentation/ABI/testing/sysfs-bus-soundwire-slave
+++ b/Documentation/ABI/testing/sysfs-bus-soundwire-slave
@@ -64,7 +64,7 @@ Description: SoundWire Slave Data Port-0 DisCo properties.
Data port 0 are used by the bus to configure the Data Port 0.


-What: /sys/bus/soundwire/devices/sdw:.../dpN_src/max_word
+What: /sys/bus/soundwire/devices/sdw:.../dp<N>_src/max_word
/sys/bus/soundwire/devices/sdw:.../dpN_src/min_word
/sys/bus/soundwire/devices/sdw:.../dpN_src/words
/sys/bus/soundwire/devices/sdw:.../dpN_src/type
--
2.31.1

2021-09-14 14:41:27

by Mauro Carvalho Chehab

[permalink] [raw]
Subject: [PATCH v2 26/29] ABI: sysfs-devices-system-cpu: use wildcards on What definitions

An "N" upper letter is not a wildcard, nor can easily be identified
by script, specially since the USB sysfs define things like.
bNumInterfaces. Use, instead, <N>, in order to let script/get_abi.pl
to convert it into a Regex.

Signed-off-by: Mauro Carvalho Chehab <[email protected]>
---
.../ABI/testing/sysfs-devices-system-cpu | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/Documentation/ABI/testing/sysfs-devices-system-cpu b/Documentation/ABI/testing/sysfs-devices-system-cpu
index b46ef147616a..4ffc7e6ef403 100644
--- a/Documentation/ABI/testing/sysfs-devices-system-cpu
+++ b/Documentation/ABI/testing/sysfs-devices-system-cpu
@@ -135,7 +135,7 @@ Description: Discover cpuidle policy and mechanism
Documentation/driver-api/pm/cpuidle.rst for more information.


-What: /sys/devices/system/cpu/cpuX/cpuidle/stateN/name
+What: /sys/devices/system/cpu/cpuX/cpuidle/state<N>/name
/sys/devices/system/cpu/cpuX/cpuidle/stateN/latency
/sys/devices/system/cpu/cpuX/cpuidle/stateN/power
/sys/devices/system/cpu/cpuX/cpuidle/stateN/time
@@ -174,7 +174,7 @@ Description:
(a count).
======== ==== =================================================

-What: /sys/devices/system/cpu/cpuX/cpuidle/stateN/desc
+What: /sys/devices/system/cpu/cpuX/cpuidle/state<N>/desc
Date: February 2008
KernelVersion: v2.6.25
Contact: Linux power management list <[email protected]>
@@ -182,7 +182,7 @@ Description:
(RO) A small description about the idle state (string).


-What: /sys/devices/system/cpu/cpuX/cpuidle/stateN/disable
+What: /sys/devices/system/cpu/cpuX/cpuidle/state<N>/disable
Date: March 2012
KernelVersion: v3.10
Contact: Linux power management list <[email protected]>
@@ -195,14 +195,14 @@ Description:
does not reflect it. Likewise, if one enables a deep state but a
lighter state still is disabled, then this has no effect.

-What: /sys/devices/system/cpu/cpuX/cpuidle/stateN/default_status
+What: /sys/devices/system/cpu/cpuX/cpuidle/state<N>/default_status
Date: December 2019
KernelVersion: v5.6
Contact: Linux power management list <[email protected]>
Description:
(RO) The default status of this state, "enabled" or "disabled".

-What: /sys/devices/system/cpu/cpuX/cpuidle/stateN/residency
+What: /sys/devices/system/cpu/cpuX/cpuidle/state<N>/residency
Date: March 2014
KernelVersion: v3.15
Contact: Linux power management list <[email protected]>
@@ -211,7 +211,7 @@ Description:
time (in microseconds) this cpu should spend in this idle state
to make the transition worth the effort.

-What: /sys/devices/system/cpu/cpuX/cpuidle/stateN/s2idle/
+What: /sys/devices/system/cpu/cpuX/cpuidle/state<N>/s2idle/
Date: March 2018
KernelVersion: v4.17
Contact: Linux power management list <[email protected]>
@@ -221,7 +221,7 @@ Description:
This attribute group is only present for states that can be
used in suspend-to-idle with suspended timekeeping.

-What: /sys/devices/system/cpu/cpuX/cpuidle/stateN/s2idle/time
+What: /sys/devices/system/cpu/cpuX/cpuidle/state<N>/s2idle/time
Date: March 2018
KernelVersion: v4.17
Contact: Linux power management list <[email protected]>
@@ -229,7 +229,7 @@ Description:
Total time spent by the CPU in suspend-to-idle (with scheduler
tick suspended) after requesting this state.

-What: /sys/devices/system/cpu/cpuX/cpuidle/stateN/s2idle/usage
+What: /sys/devices/system/cpu/cpuX/cpuidle/state<N>/s2idle/usage
Date: March 2018
KernelVersion: v4.17
Contact: Linux power management list <[email protected]>
--
2.31.1

2021-09-14 15:36:47

by Pierre-Louis Bossart

[permalink] [raw]
Subject: Re: [PATCH v2 16/29] ABI: sysfs-bus-soundwire-slave: use wildcards on What definitions



On 9/14/21 9:32 AM, Mauro Carvalho Chehab wrote:
> An "N" upper letter is not a wildcard, nor can easily be identified
> by script, specially since the USB sysfs define things like.
> bNumInterfaces. Use, instead, <N>, in order to let script/get_abi.pl
> to convert it into a Regex.

No objection on the convention but shouldn't that convention be applied
to all attributes?

>
> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
> ---
> Documentation/ABI/testing/sysfs-bus-soundwire-slave | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/Documentation/ABI/testing/sysfs-bus-soundwire-slave b/Documentation/ABI/testing/sysfs-bus-soundwire-slave
> index d324aa0b678f..db6b8ffa753e 100644
> --- a/Documentation/ABI/testing/sysfs-bus-soundwire-slave
> +++ b/Documentation/ABI/testing/sysfs-bus-soundwire-slave
> @@ -64,7 +64,7 @@ Description: SoundWire Slave Data Port-0 DisCo properties.
> Data port 0 are used by the bus to configure the Data Port 0.
>
>
> -What: /sys/bus/soundwire/devices/sdw:.../dpN_src/max_word
> +What: /sys/bus/soundwire/devices/sdw:.../dp<N>_src/max_word
> /sys/bus/soundwire/devices/sdw:.../dpN_src/min_word
> /sys/bus/soundwire/devices/sdw:.../dpN_src/words
> /sys/bus/soundwire/devices/sdw:.../dpN_src/type

if we change max_word, shouldn't we change all the others as well?

2021-09-14 17:37:32

by Kees Cook

[permalink] [raw]
Subject: Re: [PATCH v2 10/29] ABI: pstore: Fix What field

On Tue, Sep 14, 2021 at 04:32:25PM +0200, Mauro Carvalho Chehab wrote:
> If both /sys/fs/pstore/... and /dev/pstore/... are possible,
> it should use, instead, two What: fields.
>
> Signed-off-by: Mauro Carvalho Chehab <[email protected]>

Acked-by: Kees Cook <[email protected]>

--
Kees Cook

2021-09-15 03:35:58

by Andrew Donnellan

[permalink] [raw]
Subject: Re: [PATCH v2 07/29] ABI: sysfs-class-cxl: place "not in a guest" at description

On 15/9/21 12:32 am, Mauro Carvalho Chehab wrote:
> The What: field should have just the location of the ABI.
> Anything else should be inside the description.
>
> This fixes its parsing by get_abi.pl script.
>
> Signed-off-by: Mauro Carvalho Chehab <[email protected]>

Looks fine to me.

Acked-by: Andrew Donnellan <[email protected]>

> ---
> Documentation/ABI/testing/sysfs-class-cxl | 15 ++++++++++-----
> 1 file changed, 10 insertions(+), 5 deletions(-)
>
> diff --git a/Documentation/ABI/testing/sysfs-class-cxl b/Documentation/ABI/testing/sysfs-class-cxl
> index 818f55970efb..3c77677e0ca7 100644
> --- a/Documentation/ABI/testing/sysfs-class-cxl
> +++ b/Documentation/ABI/testing/sysfs-class-cxl
> @@ -166,10 +166,11 @@ Description: read only
> Decimal value of the Per Process MMIO space length.
> Users: https://github.com/ibm-capi/libcxl
>
> -What: /sys/class/cxl/<afu>m/pp_mmio_off (not in a guest)
> +What: /sys/class/cxl/<afu>m/pp_mmio_off
> Date: September 2014
> Contact: [email protected]
> Description: read only
> + (not in a guest)
> Decimal value of the Per Process MMIO space offset.
> Users: https://github.com/ibm-capi/libcxl
>
> @@ -190,28 +191,31 @@ Description: read only
> Identifies the revision level of the PSL.
> Users: https://github.com/ibm-capi/libcxl
>
> -What: /sys/class/cxl/<card>/base_image (not in a guest)
> +What: /sys/class/cxl/<card>/base_image
> Date: September 2014
> Contact: [email protected]
> Description: read only
> + (not in a guest)
> Identifies the revision level of the base image for devices
> that support loadable PSLs. For FPGAs this field identifies
> the image contained in the on-adapter flash which is loaded
> during the initial program load.
> Users: https://github.com/ibm-capi/libcxl
>
> -What: /sys/class/cxl/<card>/image_loaded (not in a guest)
> +What: /sys/class/cxl/<card>/image_loaded
> Date: September 2014
> Contact: [email protected]
> Description: read only
> + (not in a guest)
> Will return "user" or "factory" depending on the image loaded
> onto the card.
> Users: https://github.com/ibm-capi/libcxl
>
> -What: /sys/class/cxl/<card>/load_image_on_perst (not in a guest)
> +What: /sys/class/cxl/<card>/load_image_on_perst
> Date: December 2014
> Contact: [email protected]
> Description: read/write
> + (not in a guest)
> Valid entries are "none", "user", and "factory".
> "none" means PERST will not cause image to be loaded to the
> card. A power cycle is required to load the image.
> @@ -235,10 +239,11 @@ Description: write only
> contexts on the card AFUs.
> Users: https://github.com/ibm-capi/libcxl
>
> -What: /sys/class/cxl/<card>/perst_reloads_same_image (not in a guest)
> +What: /sys/class/cxl/<card>/perst_reloads_same_image
> Date: July 2015
> Contact: [email protected]
> Description: read/write
> + (not in a guest)
> Trust that when an image is reloaded via PERST, it will not
> have changed.
>
>

--
Andrew Donnellan OzLabs, ADL Canberra
[email protected] IBM Australia Limited