All of lore.kernel.org
 help / color / mirror / Atom feed
From: Qii Wang <qii.wang@mediatek.com>
To: Hsin-Yi Wang <hsinyi@chromium.org>
Cc: Wolfram Sang <wsa@kernel.org>,
	Matthias Brugger <matthias.bgg@gmail.com>,
	Rob Herring <robh+dt@kernel.org>,
	"Bartosz Golaszewski" <bgolaszewski@baylibre.com>,
	<linux-i2c@vger.kernel.org>, <devicetree@vger.kernel.org>,
	<linux-arm-kernel@lists.infradead.org>,
	<linux-mediatek@lists.infradead.org>,
	<linux-kernel@vger.kernel.org>,
	"Greg Kroah-Hartman" <gregkh@linuxfoundation.org>,
	Mark Brown <broonie@kernel.org>,
	Marek Szyprowski <m.szyprowski@samsung.com>,
	"Bibby Hsieh" <bibby.hsieh@mediatek.com>,
	Arnd Bergmann <arnd@arndb.de>
Subject: Re: [PATCH v21 3/5] i2c: mediatek: mt65xx: add optional vbus-supply
Date: Mon, 17 May 2021 16:06:53 +0800	[thread overview]
Message-ID: <1621238813.24305.5.camel@mhfsdcap03> (raw)
In-Reply-To: <20210507131406.2224177-4-hsinyi@chromium.org>

On Fri, 2021-05-07 at 21:14 +0800, Hsin-Yi Wang wrote:
> Add vbus-supply which provides power to SCL/SDA. Pass this regulator
> into core so it can be turned on/off for low power mode support.
> 
> Signed-off-by: Hsin-Yi Wang <hsinyi@chromium.org>

Reviewed-by: Qii Wang <qii.wang@mediatek.com>

> ---
>  drivers/i2c/busses/i2c-mt65xx.c | 7 +++++++
>  1 file changed, 7 insertions(+)
> 
> diff --git a/drivers/i2c/busses/i2c-mt65xx.c b/drivers/i2c/busses/i2c-mt65xx.c
> index 5ddfa4e56ee2..22d1d14b5de5 100644
> --- a/drivers/i2c/busses/i2c-mt65xx.c
> +++ b/drivers/i2c/busses/i2c-mt65xx.c
> @@ -1220,6 +1220,13 @@ static int mtk_i2c_probe(struct platform_device *pdev)
>  	i2c->adap.quirks = i2c->dev_comp->quirks;
>  	i2c->adap.timeout = 2 * HZ;
>  	i2c->adap.retries = 1;
> +	i2c->adap.bus_regulator = devm_regulator_get_optional(&pdev->dev, "vbus");
> +	if (IS_ERR(i2c->adap.bus_regulator)) {
> +		if (PTR_ERR(i2c->adap.bus_regulator) == -ENODEV)
> +			i2c->adap.bus_regulator = NULL;
> +		else
> +			return PTR_ERR(i2c->adap.bus_regulator);
> +	}
>  
>  	ret = mtk_i2c_parse_dt(pdev->dev.of_node, i2c);
>  	if (ret)


WARNING: multiple messages have this Message-ID (diff)
From: Qii Wang <qii.wang@mediatek.com>
To: Hsin-Yi Wang <hsinyi@chromium.org>
Cc: Wolfram Sang <wsa@kernel.org>,
	Matthias Brugger <matthias.bgg@gmail.com>,
	 Rob Herring <robh+dt@kernel.org>,
	Bartosz Golaszewski <bgolaszewski@baylibre.com>,
	<linux-i2c@vger.kernel.org>, <devicetree@vger.kernel.org>,
	<linux-arm-kernel@lists.infradead.org>,
	<linux-mediatek@lists.infradead.org>,
	<linux-kernel@vger.kernel.org>,
	"Greg Kroah-Hartman" <gregkh@linuxfoundation.org>,
	Mark Brown <broonie@kernel.org>,
	 Marek Szyprowski <m.szyprowski@samsung.com>,
	Bibby Hsieh <bibby.hsieh@mediatek.com>,
	Arnd Bergmann <arnd@arndb.de>
Subject: Re: [PATCH v21 3/5] i2c: mediatek: mt65xx: add optional vbus-supply
Date: Mon, 17 May 2021 16:06:53 +0800	[thread overview]
Message-ID: <1621238813.24305.5.camel@mhfsdcap03> (raw)
In-Reply-To: <20210507131406.2224177-4-hsinyi@chromium.org>

On Fri, 2021-05-07 at 21:14 +0800, Hsin-Yi Wang wrote:
> Add vbus-supply which provides power to SCL/SDA. Pass this regulator
> into core so it can be turned on/off for low power mode support.
> 
> Signed-off-by: Hsin-Yi Wang <hsinyi@chromium.org>

Reviewed-by: Qii Wang <qii.wang@mediatek.com>

> ---
>  drivers/i2c/busses/i2c-mt65xx.c | 7 +++++++
>  1 file changed, 7 insertions(+)
> 
> diff --git a/drivers/i2c/busses/i2c-mt65xx.c b/drivers/i2c/busses/i2c-mt65xx.c
> index 5ddfa4e56ee2..22d1d14b5de5 100644
> --- a/drivers/i2c/busses/i2c-mt65xx.c
> +++ b/drivers/i2c/busses/i2c-mt65xx.c
> @@ -1220,6 +1220,13 @@ static int mtk_i2c_probe(struct platform_device *pdev)
>  	i2c->adap.quirks = i2c->dev_comp->quirks;
>  	i2c->adap.timeout = 2 * HZ;
>  	i2c->adap.retries = 1;
> +	i2c->adap.bus_regulator = devm_regulator_get_optional(&pdev->dev, "vbus");
> +	if (IS_ERR(i2c->adap.bus_regulator)) {
> +		if (PTR_ERR(i2c->adap.bus_regulator) == -ENODEV)
> +			i2c->adap.bus_regulator = NULL;
> +		else
> +			return PTR_ERR(i2c->adap.bus_regulator);
> +	}
>  
>  	ret = mtk_i2c_parse_dt(pdev->dev.of_node, i2c);
>  	if (ret)

_______________________________________________
Linux-mediatek mailing list
Linux-mediatek@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-mediatek

WARNING: multiple messages have this Message-ID (diff)
From: Qii Wang <qii.wang@mediatek.com>
To: Hsin-Yi Wang <hsinyi@chromium.org>
Cc: Wolfram Sang <wsa@kernel.org>,
	Matthias Brugger <matthias.bgg@gmail.com>,
	 Rob Herring <robh+dt@kernel.org>,
	Bartosz Golaszewski <bgolaszewski@baylibre.com>,
	<linux-i2c@vger.kernel.org>, <devicetree@vger.kernel.org>,
	<linux-arm-kernel@lists.infradead.org>,
	<linux-mediatek@lists.infradead.org>,
	<linux-kernel@vger.kernel.org>,
	"Greg Kroah-Hartman" <gregkh@linuxfoundation.org>,
	Mark Brown <broonie@kernel.org>,
	 Marek Szyprowski <m.szyprowski@samsung.com>,
	Bibby Hsieh <bibby.hsieh@mediatek.com>,
	Arnd Bergmann <arnd@arndb.de>
Subject: Re: [PATCH v21 3/5] i2c: mediatek: mt65xx: add optional vbus-supply
Date: Mon, 17 May 2021 16:06:53 +0800	[thread overview]
Message-ID: <1621238813.24305.5.camel@mhfsdcap03> (raw)
In-Reply-To: <20210507131406.2224177-4-hsinyi@chromium.org>

On Fri, 2021-05-07 at 21:14 +0800, Hsin-Yi Wang wrote:
> Add vbus-supply which provides power to SCL/SDA. Pass this regulator
> into core so it can be turned on/off for low power mode support.
> 
> Signed-off-by: Hsin-Yi Wang <hsinyi@chromium.org>

Reviewed-by: Qii Wang <qii.wang@mediatek.com>

> ---
>  drivers/i2c/busses/i2c-mt65xx.c | 7 +++++++
>  1 file changed, 7 insertions(+)
> 
> diff --git a/drivers/i2c/busses/i2c-mt65xx.c b/drivers/i2c/busses/i2c-mt65xx.c
> index 5ddfa4e56ee2..22d1d14b5de5 100644
> --- a/drivers/i2c/busses/i2c-mt65xx.c
> +++ b/drivers/i2c/busses/i2c-mt65xx.c
> @@ -1220,6 +1220,13 @@ static int mtk_i2c_probe(struct platform_device *pdev)
>  	i2c->adap.quirks = i2c->dev_comp->quirks;
>  	i2c->adap.timeout = 2 * HZ;
>  	i2c->adap.retries = 1;
> +	i2c->adap.bus_regulator = devm_regulator_get_optional(&pdev->dev, "vbus");
> +	if (IS_ERR(i2c->adap.bus_regulator)) {
> +		if (PTR_ERR(i2c->adap.bus_regulator) == -ENODEV)
> +			i2c->adap.bus_regulator = NULL;
> +		else
> +			return PTR_ERR(i2c->adap.bus_regulator);
> +	}
>  
>  	ret = mtk_i2c_parse_dt(pdev->dev.of_node, i2c);
>  	if (ret)

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

  parent reply	other threads:[~2021-05-17  8:12 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-07 13:14 [PATCH v21 0/5] add power control in i2c Hsin-Yi Wang
2021-05-07 13:14 ` Hsin-Yi Wang
2021-05-07 13:14 ` Hsin-Yi Wang
2021-05-07 13:14 ` [PATCH v21 1/5] i2c: core: support bus regulator controlling in adapter Hsin-Yi Wang
2021-05-07 13:14   ` Hsin-Yi Wang
2021-05-07 13:14   ` Hsin-Yi Wang
2021-05-12 15:45   ` Matthias Brugger
2021-05-12 15:45     ` Matthias Brugger
2021-05-12 15:45     ` Matthias Brugger
2021-05-07 13:14 ` [PATCH v21 2/5] dt-binding: i2c: mt65xx: add vbus-supply property Hsin-Yi Wang
2021-05-07 13:14   ` Hsin-Yi Wang
2021-05-07 13:14   ` Hsin-Yi Wang
2021-05-07 13:14 ` [PATCH v21 3/5] i2c: mediatek: mt65xx: add optional vbus-supply Hsin-Yi Wang
2021-05-07 13:14   ` Hsin-Yi Wang
2021-05-07 13:14   ` Hsin-Yi Wang
2021-05-12 15:46   ` Matthias Brugger
2021-05-12 15:46     ` Matthias Brugger
2021-05-12 15:46     ` Matthias Brugger
2021-05-17  8:06   ` Qii Wang [this message]
2021-05-17  8:06     ` Qii Wang
2021-05-17  8:06     ` Qii Wang
2021-05-07 13:14 ` [PATCH v21 4/5] misc: eeprom: at24: check suspend status before disable regulator Hsin-Yi Wang
2021-05-07 13:14   ` Hsin-Yi Wang
2021-05-07 13:14   ` Hsin-Yi Wang
2021-05-07 13:14 ` [PATCH v21 5/5] arm64: dts: mt8183: add supply name for eeprom Hsin-Yi Wang
2021-05-07 13:14   ` Hsin-Yi Wang
2021-05-07 13:14   ` Hsin-Yi Wang
2021-05-20 10:56 ` [PATCH v21 0/5] add power control in i2c Hsin-Yi Wang
2021-05-20 10:56   ` Hsin-Yi Wang
2021-05-20 10:56   ` Hsin-Yi Wang

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=1621238813.24305.5.camel@mhfsdcap03 \
    --to=qii.wang@mediatek.com \
    --cc=arnd@arndb.de \
    --cc=bgolaszewski@baylibre.com \
    --cc=bibby.hsieh@mediatek.com \
    --cc=broonie@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=hsinyi@chromium.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-i2c@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mediatek@lists.infradead.org \
    --cc=m.szyprowski@samsung.com \
    --cc=matthias.bgg@gmail.com \
    --cc=robh+dt@kernel.org \
    --cc=wsa@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.