All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andreas Kemnade <andreas@kemnade.info>
To: Alistair Francis <alistair23@gmail.com>
Cc: Alistair Francis <alistair@alistair23.me>,
	Lee Jones <lee.jones@linaro.org>, Mark Brown <broonie@kernel.org>,
	Sascha Hauer <kernel@pengutronix.de>,
	lgirdwood@gmail.com, Rob Herring <robh+dt@kernel.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	rui.zhang@intel.com, devicetree <devicetree@vger.kernel.org>,
	linux-arm-kernel <linux-arm-kernel@lists.infradead.org>,
	Sascha Hauer <s.hauer@pengutronix.de>,
	linux-hwmon@vger.kernel.org, amitk@kernel.org,
	linux-pm@vger.kernel.org, dl-linux-imx <linux-imx@nxp.com>,
	Shawn Guo <shawnguo@kernel.org>, Rob Herring <robh@kernel.org>
Subject: Re: [PATCH v15 1/8] dt-bindings: mfd: Initial commit of silergy,sy7636a.yaml
Date: Thu, 25 Nov 2021 23:59:35 +0100	[thread overview]
Message-ID: <20211125235935.5a1b7d33@aktux> (raw)
In-Reply-To: <CAKmqyKP_gQ1qSADMPwmyf-V0TqGOYf2GitzpDXsmBUO6_iqK7Q@mail.gmail.com>

On Tue, 23 Nov 2021 23:29:26 +1000
Alistair Francis <alistair23@gmail.com> wrote:

> On Thu, Nov 18, 2021 at 7:40 AM Andreas Kemnade <andreas@kemnade.info> wrote:
> >
> > On Wed, 10 Nov 2021 22:29:41 +1000
> > Alistair Francis <alistair@alistair23.me> wrote:
> >  
> > > Initial support for the Silergy SY7636A Power Management chip
> > > and regulator.
> > >
> > > Signed-off-by: Alistair Francis <alistair@alistair23.me>
> > > Reviewed-by: Rob Herring <robh@kernel.org>
> > > Acked-for-MFD-by: Lee Jones <lee.jones@linaro.org>
> > > ---
> > >  .../bindings/mfd/silergy,sy7636a.yaml         | 79 +++++++++++++++++++
> > >  1 file changed, 79 insertions(+)
> > >  create mode 100644 Documentation/devicetree/bindings/mfd/silergy,sy7636a.yaml
> > >
> > > diff --git a/Documentation/devicetree/bindings/mfd/silergy,sy7636a.yaml b/Documentation/devicetree/bindings/mfd/silergy,sy7636a.yaml
> > > new file mode 100644
> > > index 000000000000..0566f9498e2f
> > > --- /dev/null
> > > +++ b/Documentation/devicetree/bindings/mfd/silergy,sy7636a.yaml  
> > [...]  
> > > +  regulators:
> > > +    type: object
> > > +
> > > +    properties:
> > > +      compatible:
> > > +        const: silergy,sy7636a-regulator
> > > +
> > > +      vcom:
> > > +        type: object
> > > +        $ref: /schemas/regulator/regulator.yaml#
> > > +        properties:
> > > +          regulator-name:
> > > +            const: vcom
> > > +  
> > hmm, this is what? If I understand it correctly, vcom means some
> > voltage for compensation. On other comparable pmics (e.g. TPS65185
> > which has also a sane public datasheet, MAX17135) I have seen some
> > methods to measure a voltage while the display is doing something
> > defined and then program this voltage non-volatile for compensation
> > during manufacturing.
> >
> > If I understand the code correctly all the bunch of voltages are
> > powered up if this one is enabled.
> > So at least a description should be suitable.
> >
> > The other comparable PMICs have at least regulators named VCOM, DISPLAY
> > (controls several regulators, started with delays configured via
> > registers) and V3P3. MAX17135 source can be found in NXP kernels,
> > TPS65185 in Kobo vendor kernels.
> >
> > So I would expect to see something similar here and a description or at
> > least not such a misleading name as vcom if it is for some reason not
> > feasible to separate the regulators.  
> 
> This is a vcom in the sense of voltage for compensation. We just
> currently don't support setting the vcom.
> 
> I had a look at the Kobo code and this is similar to
> https://github.com/akemnade/linux/blob/kobo/epdc-pmic-5.15/drivers/regulator/sy7636-regulator.c#L614
> 
> So I think that vcom is still the appropriate name for this.
> 
seems that you did not get me. If I understand the code behind it
correctly, it turns on all power rails (the +-15V stuff, VEE and so on)
with the defined delays, not just vcom because it sets
SY7636A_OPERATION_MODE_CRL_ONOFF. Controlling VCOM separately is possible
by using SY7636A_OPERATION_MODE_CRL_VCOMCTL in combintion with a
vcom_en gpio.

I do not see a reason to turn on vcom only without the other higher
voltage rails, so the behaviour is not necessarily wrong but if I read
the binding documentation I would expect that just vcom is turned on.
That is the mismatch I am talking about.

If we agree on this idea that one regulator is enabling everything, I
would adapt my EPDC drm driver and tps65185 driver (which are both in
my clean up to be upstreamable-queue). 

Just another thing to compare with:
https://github.com/Freescale/linux-fslc/blob/4.1-2.0.x-imx/drivers/regulator/max17135-regulator.c
that seems to be the starting point for kobo vendor kernel epd pmics.
They seem to have taken the source and modified things. There we have
regulators with empty ops for that step-up converted stuff, a separate
vcom and a display regulator which really controls all of these step-up
things.

Regards,
Andreas

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

WARNING: multiple messages have this Message-ID (diff)
From: Andreas Kemnade <andreas@kemnade.info>
To: Alistair Francis <alistair23@gmail.com>
Cc: Alistair Francis <alistair@alistair23.me>,
	Lee Jones <lee.jones@linaro.org>, Mark Brown <broonie@kernel.org>,
	Sascha Hauer <kernel@pengutronix.de>,
	lgirdwood@gmail.com, Rob Herring <robh+dt@kernel.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	rui.zhang@intel.com, devicetree <devicetree@vger.kernel.org>,
	linux-arm-kernel <linux-arm-kernel@lists.infradead.org>,
	Sascha Hauer <s.hauer@pengutronix.de>,
	linux-hwmon@vger.kernel.org, amitk@kernel.org,
	linux-pm@vger.kernel.org, dl-linux-imx <linux-imx@nxp.com>,
	Shawn Guo <shawnguo@kernel.org>, Rob Herring <robh@kernel.org>
Subject: Re: [PATCH v15 1/8] dt-bindings: mfd: Initial commit of silergy,sy7636a.yaml
Date: Thu, 25 Nov 2021 23:59:35 +0100	[thread overview]
Message-ID: <20211125235935.5a1b7d33@aktux> (raw)
In-Reply-To: <CAKmqyKP_gQ1qSADMPwmyf-V0TqGOYf2GitzpDXsmBUO6_iqK7Q@mail.gmail.com>

On Tue, 23 Nov 2021 23:29:26 +1000
Alistair Francis <alistair23@gmail.com> wrote:

> On Thu, Nov 18, 2021 at 7:40 AM Andreas Kemnade <andreas@kemnade.info> wrote:
> >
> > On Wed, 10 Nov 2021 22:29:41 +1000
> > Alistair Francis <alistair@alistair23.me> wrote:
> >  
> > > Initial support for the Silergy SY7636A Power Management chip
> > > and regulator.
> > >
> > > Signed-off-by: Alistair Francis <alistair@alistair23.me>
> > > Reviewed-by: Rob Herring <robh@kernel.org>
> > > Acked-for-MFD-by: Lee Jones <lee.jones@linaro.org>
> > > ---
> > >  .../bindings/mfd/silergy,sy7636a.yaml         | 79 +++++++++++++++++++
> > >  1 file changed, 79 insertions(+)
> > >  create mode 100644 Documentation/devicetree/bindings/mfd/silergy,sy7636a.yaml
> > >
> > > diff --git a/Documentation/devicetree/bindings/mfd/silergy,sy7636a.yaml b/Documentation/devicetree/bindings/mfd/silergy,sy7636a.yaml
> > > new file mode 100644
> > > index 000000000000..0566f9498e2f
> > > --- /dev/null
> > > +++ b/Documentation/devicetree/bindings/mfd/silergy,sy7636a.yaml  
> > [...]  
> > > +  regulators:
> > > +    type: object
> > > +
> > > +    properties:
> > > +      compatible:
> > > +        const: silergy,sy7636a-regulator
> > > +
> > > +      vcom:
> > > +        type: object
> > > +        $ref: /schemas/regulator/regulator.yaml#
> > > +        properties:
> > > +          regulator-name:
> > > +            const: vcom
> > > +  
> > hmm, this is what? If I understand it correctly, vcom means some
> > voltage for compensation. On other comparable pmics (e.g. TPS65185
> > which has also a sane public datasheet, MAX17135) I have seen some
> > methods to measure a voltage while the display is doing something
> > defined and then program this voltage non-volatile for compensation
> > during manufacturing.
> >
> > If I understand the code correctly all the bunch of voltages are
> > powered up if this one is enabled.
> > So at least a description should be suitable.
> >
> > The other comparable PMICs have at least regulators named VCOM, DISPLAY
> > (controls several regulators, started with delays configured via
> > registers) and V3P3. MAX17135 source can be found in NXP kernels,
> > TPS65185 in Kobo vendor kernels.
> >
> > So I would expect to see something similar here and a description or at
> > least not such a misleading name as vcom if it is for some reason not
> > feasible to separate the regulators.  
> 
> This is a vcom in the sense of voltage for compensation. We just
> currently don't support setting the vcom.
> 
> I had a look at the Kobo code and this is similar to
> https://github.com/akemnade/linux/blob/kobo/epdc-pmic-5.15/drivers/regulator/sy7636-regulator.c#L614
> 
> So I think that vcom is still the appropriate name for this.
> 
seems that you did not get me. If I understand the code behind it
correctly, it turns on all power rails (the +-15V stuff, VEE and so on)
with the defined delays, not just vcom because it sets
SY7636A_OPERATION_MODE_CRL_ONOFF. Controlling VCOM separately is possible
by using SY7636A_OPERATION_MODE_CRL_VCOMCTL in combintion with a
vcom_en gpio.

I do not see a reason to turn on vcom only without the other higher
voltage rails, so the behaviour is not necessarily wrong but if I read
the binding documentation I would expect that just vcom is turned on.
That is the mismatch I am talking about.

If we agree on this idea that one regulator is enabling everything, I
would adapt my EPDC drm driver and tps65185 driver (which are both in
my clean up to be upstreamable-queue). 

Just another thing to compare with:
https://github.com/Freescale/linux-fslc/blob/4.1-2.0.x-imx/drivers/regulator/max17135-regulator.c
that seems to be the starting point for kobo vendor kernel epd pmics.
They seem to have taken the source and modified things. There we have
regulators with empty ops for that step-up converted stuff, a separate
vcom and a display regulator which really controls all of these step-up
things.

Regards,
Andreas

  reply	other threads:[~2021-11-25 23:01 UTC|newest]

Thread overview: 52+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-10 12:29 [PATCH v15 0/8] Add support for the silergy,sy7636a Alistair Francis
2021-11-10 12:29 ` Alistair Francis
2021-11-10 12:29 ` [PATCH v15 1/8] dt-bindings: mfd: Initial commit of silergy,sy7636a.yaml Alistair Francis
2021-11-10 12:29   ` [PATCH v15 1/8] dt-bindings: mfd: Initial commit of silergy, sy7636a.yaml Alistair Francis
2021-11-17 21:39   ` [PATCH v15 1/8] dt-bindings: mfd: Initial commit of silergy,sy7636a.yaml Andreas Kemnade
2021-11-17 21:39     ` Andreas Kemnade
2021-11-23 13:29     ` Alistair Francis
2021-11-23 13:29       ` [PATCH v15 1/8] dt-bindings: mfd: Initial commit of silergy, sy7636a.yaml Alistair Francis
2021-11-25 22:59       ` Andreas Kemnade [this message]
2021-11-25 22:59         ` [PATCH v15 1/8] dt-bindings: mfd: Initial commit of silergy,sy7636a.yaml Andreas Kemnade
2021-11-29 11:41         ` [PATCH v15 1/8] dt-bindings: mfd: Initial commit of silergy, sy7636a.yaml Alistair Francis
2021-11-29 11:41           ` [PATCH v15 1/8] dt-bindings: mfd: Initial commit of silergy,sy7636a.yaml Alistair Francis
2021-12-01 22:35           ` Andreas Kemnade
2021-12-01 22:35             ` Andreas Kemnade
2021-12-02 11:45             ` Alistair Francis
2021-12-02 11:45               ` [PATCH v15 1/8] dt-bindings: mfd: Initial commit of silergy, sy7636a.yaml Alistair Francis
2021-11-10 12:29 ` [PATCH v15 2/8] mfd: simple-mfd-i2c: Add a Kconfig name Alistair Francis
2021-11-10 12:29   ` Alistair Francis
2021-11-10 12:29 ` [PATCH v15 3/8] mfd: simple-mfd-i2c: Enable support for the silergy,sy7636a Alistair Francis
2021-11-10 12:29   ` [PATCH v15 3/8] mfd: simple-mfd-i2c: Enable support for the silergy, sy7636a Alistair Francis
2021-11-15 23:10   ` [PATCH v15 3/8] mfd: simple-mfd-i2c: Enable support for the silergy,sy7636a Andreas Kemnade
2021-11-15 23:10     ` Andreas Kemnade
2021-11-23 12:14     ` Alistair Francis
2021-11-23 12:14       ` [PATCH v15 3/8] mfd: simple-mfd-i2c: Enable support for the silergy, sy7636a Alistair Francis
2021-11-23 15:39       ` [PATCH v15 3/8] mfd: simple-mfd-i2c: Enable support for the silergy,sy7636a Guenter Roeck
2021-11-23 15:39         ` Guenter Roeck
2021-11-24  8:11         ` Alistair Francis
2021-11-24  8:11           ` [PATCH v15 3/8] mfd: simple-mfd-i2c: Enable support for the silergy, sy7636a Alistair Francis
2021-11-24 19:35         ` [PATCH v15 3/8] mfd: simple-mfd-i2c: Enable support for the silergy,sy7636a Andreas Kemnade
2021-11-24 19:35           ` Andreas Kemnade
2021-11-24 20:09           ` Guenter Roeck
2021-11-24 20:09             ` Guenter Roeck
2021-11-24 22:50             ` Andreas Kemnade
2021-11-24 22:50               ` Andreas Kemnade
2021-11-24 22:56               ` Guenter Roeck
2021-11-24 22:56                 ` Guenter Roeck
2021-11-25  7:29                 ` Andreas Kemnade
2021-11-25  7:29                   ` Andreas Kemnade
2021-11-10 12:29 ` [PATCH v15 4/8] regulator: sy7636a: Remove requirement on sy7636a mfd Alistair Francis
2021-11-10 12:29   ` Alistair Francis
2021-11-10 14:39   ` Mark Brown
2021-11-10 14:39     ` Mark Brown
2021-11-10 12:29 ` [PATCH v15 5/8] hwmon: sy7636a: Add temperature driver for sy7636a Alistair Francis
2021-11-10 12:29   ` Alistair Francis
2021-11-10 15:55   ` Guenter Roeck
2021-11-10 15:55     ` Guenter Roeck
2021-11-10 12:29 ` [PATCH v15 6/8] ARM: imx_v6_v7_defconfig: Enable silergy,sy7636a Alistair Francis
2021-11-10 12:29   ` Alistair Francis
2021-11-10 12:29 ` [PATCH v15 7/8] ARM: dts: imx7d: remarkable2: " Alistair Francis
2021-11-10 12:29   ` Alistair Francis
2021-11-10 12:29 ` [PATCH v15 8/8] ARM: dts: imx7d: remarkable2: Enable lcdif Alistair Francis
2021-11-10 12:29   ` Alistair Francis

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=20211125235935.5a1b7d33@aktux \
    --to=andreas@kemnade.info \
    --cc=alistair23@gmail.com \
    --cc=alistair@alistair23.me \
    --cc=amitk@kernel.org \
    --cc=broonie@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=kernel@pengutronix.de \
    --cc=lee.jones@linaro.org \
    --cc=lgirdwood@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-hwmon@vger.kernel.org \
    --cc=linux-imx@nxp.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=robh+dt@kernel.org \
    --cc=robh@kernel.org \
    --cc=rui.zhang@intel.com \
    --cc=s.hauer@pengutronix.de \
    --cc=shawnguo@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.