[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250220164201.469fdf6d@kernel.org>
Date: Thu, 20 Feb 2025 16:42:01 -0800
From: Jakub Kicinski <kuba@...nel.org>
To: Kory Maincent <kory.maincent@...tlin.com>
Cc: Andrew Lunn <andrew@...n.ch>, Oleksij Rempel <o.rempel@...gutronix.de>,
"David S. Miller" <davem@...emloft.net>, Eric Dumazet
<edumazet@...gle.com>, Paolo Abeni <pabeni@...hat.com>, Jonathan Corbet
<corbet@....net>, Donald Hunter <donald.hunter@...il.com>, Rob Herring
<robh@...nel.org>, Andrew Lunn <andrew+netdev@...n.ch>, Simon Horman
<horms@...nel.org>, Heiner Kallweit <hkallweit1@...il.com>, Russell King
<linux@...linux.org.uk>, Krzysztof Kozlowski <krzk+dt@...nel.org>, Conor
Dooley <conor+dt@...nel.org>, Thomas Petazzoni
<thomas.petazzoni@...tlin.com>, netdev@...r.kernel.org,
linux-doc@...r.kernel.org, Kyle Swenson <kyle.swenson@....tech>, Dent
Project <dentproject@...uxfoundation.org>, kernel@...gutronix.de, Maxime
Chevallier <maxime.chevallier@...tlin.com>, devicetree@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH net-next v5 02/12] net: pse-pd: Add support for
reporting events
On Tue, 18 Feb 2025 17:19:06 +0100 Kory Maincent wrote:
> From: Kory Maincent (Dent Project) <kory.maincent@...tlin.com>
>
> Add support for devm_pse_irq_helper() to register PSE interrupts. This aims
> to report events such as over-current or over-temperature conditions
> similarly to how the regulator API handles them but using a specific PSE
> ethtool netlink socket.
I think you should CC HWMON ML on this.
Avoid any surprises.
> diff --git a/Documentation/netlink/specs/ethtool.yaml b/Documentation/netlink/specs/ethtool.yaml
> index 655d8d10fe24..da78c5daf537 100644
> --- a/Documentation/netlink/specs/ethtool.yaml
> +++ b/Documentation/netlink/specs/ethtool.yaml
> @@ -1526,6 +1526,22 @@ attribute-sets:
> name: hwtstamp-flags
> type: nest
> nested-attributes: bitset
> + -
> + name: pse-ntf
> + attr-cnt-name: __ethtool-a-pse-ntf-cnt
> + attributes:
> + -
> + name: unspec
> + type: unused
> + value: 0
Please don't add the unused entries unless your code actually needs
them. YNL will id real ones from 1 anyway.
> + -
> + name: header
> + type: nest
> + nested-attributes: header
> + -
> + name: events
> + type: nest
> + nested-attributes: bitset
Do we really need a bitset here? Much more manual work to make a bitset
than just a uint + enum with the bits. enum is much easier to use with
YNL based user space, and it's more self-documenting than a list of bits
buried in the source of the kernel.
> operations:
> enum-model: directional
> @@ -2382,3 +2398,13 @@ operations:
> attributes: *tsconfig
> reply:
> attributes: *tsconfig
> + -
> + name: pse-ntf
> + doc: Notification for pse events.
s/pse/PSE/
> +
> + attribute-set: pse-ntf
> +
> + event:
> + attributes:
> + - header
> + - events
Powered by blists - more mailing lists