[LTP] [PATCH v4 14/31] testcases: sysfs: sys_hwmon01

Petr Vorel pvorel@suse.cz
Thu Sep 3 18:21:51 CEST 2026


Hi Cyril,

...
> +++ b/testcases/kernel/sysfs/class/hwmon/sys_hwmon01.c
> @@ -0,0 +1,173 @@
> +// SPDX-License-Identifier: GPL-2.0-or-later
> +/*
> + * Copyright (c) 2026 Cyril Hrubis <chrubis@suse.cz>
> + */
> +
> +/*\
> + * Walks all hardware monitoring devices under /sys/class/hwmon/ and performs
> + * sanity and cross-checks on the sensor channels exported per the stable
> + * hwmon sysfs ABI (Documentation/hwmon/sysfs-interface.rst).

nit: FYI we have :kernel_doc: helper macro:

:kernel_doc:`hwmon/sysfs-interface`

linking to
https://docs.kernel.org/hwmon/sysfs-interface.html

(I haven't done any helper for ABI doc yet).

The code itself is really good, +1 for docs. Thanks!

Kind regards,
Petr


More information about the ltp mailing list