mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Guenter Roeck <linux@roeck-us.net>
To: Antoniu Miclaus <antoniu.miclaus@analog.com>,
	Jean Delvare <jdelvare@suse.com>, Rob Herring <robh@kernel.org>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Conor Dooley <conor+dt@kernel.org>,
	linux-hwmon@vger.kernel.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org
Cc: Oleksij Rempel <o.rempel@pengutronix.de>,
	Kory Maincent <kory.maincent@bootlin.com>,
	Network Development <netdev@vger.kernel.org>
Subject: Re: [PATCH 2/2] hwmon: ltc4296-1: add driver support
Date: Fri, 25 Oct 2024 07:22:08 -0700	[thread overview]
Message-ID: <6955c8b6-58df-4b1a-bdd6-759de3d3c46b@roeck-us.net> (raw)
In-Reply-To: <20241025115624.21835-3-antoniu.miclaus@analog.com>

Hi,

On 10/25/24 04:56, Antoniu Miclaus wrote:
> Add support for LTC4296-1 is an IEEE 802.3cg-compliant,
> five port, single-pair power over Ethernet (SPoE), power
> sourcing equipment (PSE) controller.
> 
> Signed-off-by: Antoniu Miclaus <antoniu.miclaus@analog.com>
> ---

...

> +	hwmon_dev = devm_hwmon_device_register_with_groups(&spi->dev,
> +							   spi->modalias,
> +							   st, ltc4296_1_groups);

New drivers must use the the with_info() hardware monitoring API.

The API use is inappropriate: _enable attributes are supposed to enable
monitoring, not a power source. The hardware monitoring subsystem is
responsible for hardware _monitoring_, not control. It can be tied to
the regulator subsystem, but even that seems to be be inappropriate here.
I think the driver should probably reside in drivers/net/pse-pd/.
That doesn't mean it can not support hardware monitoring, but that
isn't really the chip's primary functionality.

Yes, I see that we already have ti,tps23861 in the hardware monitoring
subsystem, but that may be just as wrong.

I am copying the PSE subsystem maintainers and mailing list for advice.

Thanks,
Guenter


  reply	other threads:[~2024-10-25 14:22 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-25 11:56 [PATCH 0/2] Add Support for LTC4296-1 Antoniu Miclaus
2024-10-25 11:56 ` [PATCH 1/2] dt-bindings: hwmon: add ltc4296-1 support Antoniu Miclaus
2024-10-28  7:42   ` Krzysztof Kozlowski
2024-10-25 11:56 ` [PATCH 2/2] hwmon: ltc4296-1: add driver support Antoniu Miclaus
2024-10-25 14:22   ` Guenter Roeck [this message]
2024-10-25 15:01     ` Oleksij Rempel

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=6955c8b6-58df-4b1a-bdd6-759de3d3c46b@roeck-us.net \
    --to=linux@roeck-us.net \
    --cc=antoniu.miclaus@analog.com \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=jdelvare@suse.com \
    --cc=kory.maincent@bootlin.com \
    --cc=krzk+dt@kernel.org \
    --cc=linux-hwmon@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=o.rempel@pengutronix.de \
    --cc=robh@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®