From: Bibby Hsieh <bibby.hsieh@mediatek.com>
To: Bartosz Golaszewski <bgolaszewski@baylibre.com>
Cc: Rob Herring <robh@kernel.org>, Tomasz Figa <tfiga@chromium.org>,
"Wolfram Sang" <wsa@the-dreams.de>,
linux-i2c <linux-i2c@vger.kernel.org>,
"Nicolas Boichat" <drinkcat@chromium.org>,
srv_heupstream <srv_heupstream@mediatek.com>,
Mark Rutland <mark.rutland@arm.com>,
linux-devicetree <devicetree@vger.kernel.org>
Subject: Re: [PATCH v2] dt-binding: eeprom: at24: add supply properties
Date: Mon, 28 Oct 2019 10:36:19 +0800 [thread overview]
Message-ID: <1572230179.9186.2.camel@mtksdaap41> (raw)
In-Reply-To: <CAMpxmJUygTr2b+q-skb8_m9TfOiEvqoOCSjDQEi+sf9iNN0=BQ@mail.gmail.com>
On Sat, 2019-10-26 at 14:05 +0200, Bartosz Golaszewski wrote:
> pt., 25 paź 2019 o 23:10 Rob Herring <robh@kernel.org> napisał(a):
> >
> > On Thu, Oct 24, 2019 at 06:32:38PM +0900, Tomasz Figa wrote:
> > > On Thu, Oct 24, 2019 at 5:40 PM Bartosz Golaszewski
> > > <bgolaszewski@baylibre.com> wrote:
> > > >
> > > > czw., 24 paź 2019 o 09:02 Tomasz Figa <tfiga@chromium.org> napisał(a):
> > > > >
> > > > > On Thu, Oct 24, 2019 at 3:22 PM Bartosz Golaszewski
> > > > > <bgolaszewski@baylibre.com> wrote:
> > > > > >
> > > > > > pt., 18 paź 2019 o 10:26 Bibby Hsieh <bibby.hsieh@mediatek.com> napisał(a):
> > > > > > >
> > > > > > > In some platforms, they disable the power-supply of eeprom and i2c due
> > > > > > > to power consumption reduction.
> > > > > > >
> > > > > > > This patch add two supply properties: vcc-supply, i2c-supply.
> > > > > > >
> > > > > > > Changes since v1:
> > > > > > > - change supply name
> > > > > > > - rebase to next
> > > > > > >
> > > > > > > Signed-off-by: Bibby Hsieh <bibby.hsieh@mediatek.com>
> > > > > > > ---
> > > > > > > Documentation/devicetree/bindings/eeprom/at24.yaml | 8 ++++++++
> > > > > > > 1 file changed, 8 insertions(+)
> > > > > > >
> > > > > > > diff --git a/Documentation/devicetree/bindings/eeprom/at24.yaml b/Documentation/devicetree/bindings/eeprom/at24.yaml
> > > > > > > index e8778560d966..578487a5d9b7 100644
> > > > > > > --- a/Documentation/devicetree/bindings/eeprom/at24.yaml
> > > > > > > +++ b/Documentation/devicetree/bindings/eeprom/at24.yaml
> > > > > > > @@ -167,6 +167,14 @@ properties:
> > > > > > > minimum: 1
> > > > > > > maximum: 8
> > > > > > >
> > > > > > > + vcc-supply:
> > > > > > > + description:
> > > > > > > + phandle of the regulator that provides the supply voltage.
> > > > > > > +
> > > > > > > + i2c-sypply:
> > > > > > > + description:
> > > > > > > + phandle to the regulator that provides power to i2c.
> > > > > > > +
> > > > > >
> > > > > > Something was bothering me about this patch so I came back to take a
> > > > > > look. Can you explain what i2c actually stands for in this doc? I hope
> > > > > > I'm misinterpreting something and it isn't that the driver disables
> > > > > > the regulator powering the i2c bus controller?
> > > > >
> > > > > In our case it's the regulator that the I2C bus is pulled up to.
> > > > >
> > > >
> > > > Then it has nothing to do with a generic EEPROM driver IMO. I think
> > > > you need to add the control for this regulator to your i2c controller
> > > > driver and create a power domain where the EEPROM would be lower in
> > > > hierarchy.
> > >
> > > While I agree that the generic EEPROM driver may not be the best place
> > > to do it, neither is a driver for a specific SoC i2c controller. The
> > > hardware design is not specific to any particular i2c controller.
> > >
> > > Perhaps we need the generic i2c core to take into account an
> > > i2c-supply? Wolfram, any thoughts on this?
> >
> > Sounds good to me. Maybe 'bus-supply' instead to indicate it's supposed
> > to be for the bus and not other things. It should reside in the I2C
> > controller's node (or mux ports) though.
> >
> > Rob
>
> Thanks,
>
> in that case Bibby: please just use a single regulator for vcc-supply in at24.
To my understanding, there are something I need to do.
1. remove i2c-supply property from DT.
2. just control vcc-supply in at24 driver.
3. add i2c-supply control in i2c and i2c-supply property in DT?
Is there any mistakes?
Bibby
>
> Thanks,
> Bartosz
next prev parent reply other threads:[~2019-10-28 2:36 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-10-18 8:25 [PATCH v4] misc: eeprom: at24: support pm_runtime control Bibby Hsieh
2019-10-18 8:25 ` [PATCH v2] dt-binding: eeprom: at24: add supply properties Bibby Hsieh
2019-10-18 10:07 ` Bartosz Golaszewski
2019-10-24 6:22 ` Bartosz Golaszewski
2019-10-24 7:01 ` Tomasz Figa
2019-10-24 8:40 ` Bartosz Golaszewski
2019-10-24 9:32 ` Tomasz Figa
2019-10-25 21:10 ` Rob Herring
2019-10-26 12:05 ` Bartosz Golaszewski
2019-10-28 2:36 ` Bibby Hsieh [this message]
2019-11-07 14:32 ` Tomasz Figa
2019-10-24 6:48 ` Peter Rosin
2019-10-18 9:24 ` [PATCH v4] misc: eeprom: at24: support pm_runtime control Tomasz Figa
2019-10-18 10:11 ` Bartosz Golaszewski
2019-10-22 2:25 ` Bibby Hsieh
2019-10-21 16:53 ` Bartosz Golaszewski
2019-10-22 2:23 ` Bibby Hsieh
2019-10-22 7:26 ` Tomasz Figa
2019-10-22 9:00 ` Bartosz Golaszewski
2019-10-22 10:33 ` Tomasz Figa
2019-10-22 11:19 ` Mark Brown
2019-10-22 12:13 ` Bartosz Golaszewski
2019-10-22 15:03 ` Mark Brown
2019-10-22 15:42 ` Bartosz Golaszewski
2019-10-22 16:33 ` Mark Brown
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=1572230179.9186.2.camel@mtksdaap41 \
--to=bibby.hsieh@mediatek.com \
--cc=bgolaszewski@baylibre.com \
--cc=devicetree@vger.kernel.org \
--cc=drinkcat@chromium.org \
--cc=linux-i2c@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=robh@kernel.org \
--cc=srv_heupstream@mediatek.com \
--cc=tfiga@chromium.org \
--cc=wsa@the-dreams.de \
/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;
as well as URLs for NNTP newsgroup(s).