public inbox for linux-i2c@vger.kernel.org
 help / color / mirror / Atom feed
From: Conor Dooley <conor@kernel.org>
To: Guenter Roeck <linux@roeck-us.net>
Cc: Cedric Encarnacion <cedricjustine.encarnacion@analog.com>,
	devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-i2c@vger.kernel.org, linux-doc@vger.kernel.org,
	linux-hwmon@vger.kernel.org, Jean Delvare <jdelvare@suse.com>,
	Jonathan Corbet <corbet@lwn.net>,
	Delphine CC Chiu <Delphine_CC_Chiu@wiwynn.com>,
	Rob Herring <robh@kernel.org>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Conor Dooley <conor+dt@kernel.org>,
	Peter Yin <peteryin.openbmc@gmail.com>,
	Noah Wang <noahwang.wang@outlook.com>,
	Marek Vasut <marex@denx.de>, Lukas Wunner <lukas@wunner.de>
Subject: Re: [PATCH v2 1/2] dt-bindings: trivial-devices: add ltp8800
Date: Wed, 6 Nov 2024 18:38:26 +0000	[thread overview]
Message-ID: <20241106-crate-antihero-bc7b66037640@spud> (raw)
In-Reply-To: <f6e9cc1a-bdd7-4231-844e-2d8c5c3be50f@roeck-us.net>

[-- Attachment #1: Type: text/plain, Size: 3576 bytes --]

On Wed, Nov 06, 2024 at 10:19:19AM -0800, Guenter Roeck wrote:
> On 11/6/24 08:54, Conor Dooley wrote:
> > On Wed, Nov 06, 2024 at 08:43:54AM -0800, Guenter Roeck wrote:
> > > On 11/6/24 08:11, Conor Dooley wrote:
> > > > On Wed, Nov 06, 2024 at 04:06:02PM +0000, Conor Dooley wrote:
> > > > > On Tue, Nov 05, 2024 at 08:34:01PM -0800, Guenter Roeck wrote:
> > > > > > On 11/5/24 19:09, Cedric Encarnacion wrote:
> > > > > > > Add Analog Devices LTP8800-1A, LTP8800-2, and LTP8800-4A DC/DC μModule
> > > > > > > regulator.
> > > > > 
> > > > > A single compatible for 3 devices is highly suspect. What is
> > > > > different between these devices?
> > > > 
> > > > Additionally, looking at one of the datasheets, this has several inputs
> > > > that could be controlled by a GPIO, a clock input and several supply
> > > > inputs. It also has a regulator output. I don't think it is suitable for
> > > > trivial-devices.yaml.
> > > > 
> > > 
> > > All PMBus devices are by definition regulators with input and output voltages.
> > > After all, PMBus stands for "Power Management Bus". Some of them are listed
> > > in trivial devices, some are not. Is that a general guidance, or in other
> > > words should I (we) automatically reject patches adding PMBus devices
> > > to the trivial devices file ?
> > 
> > Personally I like what Jonathan does for iio devices, where he requires
> > input supplies to be documented, which in turns means they can't go into
> > trivial-devices.yaml. I wanted to add an input supply option to
> > trivial-devices.yaml but ?Rob? was not a fan.
> 
> I may be missing something, but doesn't every chip have an input supply ?
> granted, PMBus chips often have more than one, but still ...

Yeah, that's why I wanted to permit a supply in trivial-devices, because
I bet 99% of devices in there have a supply. IIRC the problem was that
there wasn't a good "generic" name for one. I don't think it was a "you
cannot do this" but a "you need to come up with a name for that supply
that works generically" and I couldn't.

> > In this case it would need a dedicated binding to document the regulator
> > child node and permit things like regulator-always-on or for any
> > consumers of the regulator to exist. I suppose that probably applies to
> > all pmbus bindings?
> 
> Yes. There may be a few exceptions, for example if a fan controller is
> modeled as PMBus device, but that is rare. From a driver perspective,
> exposing regulator nodes is optional, though.
> 
> > In this case, there seems to be an input "sync" clock that may need to
> > be enabled, which is another nail in the coffin for
> > trivial-devices.yaml.
> 
> I really don't know if it is a good idea to expose such data. That clock can
> be connected to ground. It is only necessary in power-sharing configurations,
> and requires all chips to use the same clock. I'd assume it to be a fixed clock
> in pretty much all circumstances. The frequency needs to be configured into
> the chip, but that needs to be done during board manufacturing because it
> determines the switching frequency. Writing wrong data into the chip may
> render the board unusable or even destroy it (I destroyed several PMBus chips
> myself while playing with such parameters on evaluation boards). Maybe there
> is some use case where changing the configuration is necessary, but I am not
> in favor of exposing it due to the risk involved.

I figured it'd be fixed, but that doesn't mean it can't have an enable
(or a supply of its own).

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

  reply	other threads:[~2024-11-06 18:38 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-11-06  3:09 [PATCH v2 0/2] Add driver for LTP8800-1A, LTP8800-2 and LTP8800-4A Cedric Encarnacion
2024-11-06  3:09 ` [PATCH v2 1/2] dt-bindings: trivial-devices: add ltp8800 Cedric Encarnacion
2024-11-06  4:34   ` Guenter Roeck
2024-11-06 16:06     ` Conor Dooley
2024-11-06 16:11       ` Conor Dooley
2024-11-06 16:43         ` Guenter Roeck
2024-11-06 16:54           ` Conor Dooley
2024-11-06 18:19             ` Guenter Roeck
2024-11-06 18:38               ` Conor Dooley [this message]
2024-11-06 16:35       ` Guenter Roeck
2024-11-06 16:46         ` Conor Dooley
2024-11-06 18:23           ` Guenter Roeck
2024-11-06  3:09 ` [PATCH v2 2/2] hwmon: pmbus: add driver for ltp8800-1a, ltp8800-4a, and ltp8800-2 Cedric Encarnacion
2024-11-06  4:31   ` Guenter Roeck
2024-11-06 18:45   ` kernel test robot
2024-11-06 19:17   ` kernel test robot
2024-11-07  1:45   ` Guenter Roeck
2024-11-08  7:44     ` Encarnacion, Cedric justine
2024-11-08 14:31       ` Guenter Roeck
2024-11-13  5:45         ` Encarnacion, Cedric justine

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=20241106-crate-antihero-bc7b66037640@spud \
    --to=conor@kernel.org \
    --cc=Delphine_CC_Chiu@wiwynn.com \
    --cc=cedricjustine.encarnacion@analog.com \
    --cc=conor+dt@kernel.org \
    --cc=corbet@lwn.net \
    --cc=devicetree@vger.kernel.org \
    --cc=jdelvare@suse.com \
    --cc=krzk+dt@kernel.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-hwmon@vger.kernel.org \
    --cc=linux-i2c@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@roeck-us.net \
    --cc=lukas@wunner.de \
    --cc=marex@denx.de \
    --cc=noahwang.wang@outlook.com \
    --cc=peteryin.openbmc@gmail.com \
    --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