All of lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot] [PATCH] mmc: am654_sdhci: Drop a redundant power_domain_on in probe
@ 2019-09-24  7:47 Lokesh Vutla
  2019-09-25  1:34 ` Peng Fan
  2019-10-12 20:27 ` Tom Rini
  0 siblings, 2 replies; 3+ messages in thread
From: Lokesh Vutla @ 2019-09-24  7:47 UTC (permalink / raw)
  To: u-boot

Power-domain is enabled by default in device_probe. am654 mmc driver
is enabling power-domain again in probe. As the second call is
redundant, drop power_domain_on from probe.

Tested-by: Suman Anna <s-anna@ti.com>
Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
---
 drivers/mmc/am654_sdhci.c | 13 -------------
 1 file changed, 13 deletions(-)

diff --git a/drivers/mmc/am654_sdhci.c b/drivers/mmc/am654_sdhci.c
index 1793a3f99a..7cd5516197 100644
--- a/drivers/mmc/am654_sdhci.c
+++ b/drivers/mmc/am654_sdhci.c
@@ -219,23 +219,10 @@ static int am654_sdhci_probe(struct udevice *dev)
 	struct mmc_uclass_priv *upriv = dev_get_uclass_priv(dev);
 	struct sdhci_host *host = dev_get_priv(dev);
 	struct mmc_config *cfg = &plat->cfg;
-	struct power_domain sdhci_pwrdmn;
 	struct clk clk;
 	unsigned long clock;
 	int ret;
 
-	ret = power_domain_get_by_index(dev, &sdhci_pwrdmn, 0);
-	if (!ret) {
-		ret = power_domain_on(&sdhci_pwrdmn);
-		if (ret) {
-			dev_err(dev, "Power domain on failed (%d)\n", ret);
-			return ret;
-		}
-	} else if (ret != -ENOENT && ret != -ENODEV && ret != -ENOSYS) {
-		dev_err(dev, "failed to get power domain (%d)\n", ret);
-		return ret;
-	}
-
 	ret = clk_get_by_index(dev, 0, &clk);
 	if (ret) {
 		dev_err(dev, "failed to get clock\n");
-- 
2.22.0

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [U-Boot] [PATCH] mmc: am654_sdhci: Drop a redundant power_domain_on in probe
  2019-09-24  7:47 [U-Boot] [PATCH] mmc: am654_sdhci: Drop a redundant power_domain_on in probe Lokesh Vutla
@ 2019-09-25  1:34 ` Peng Fan
  2019-10-12 20:27 ` Tom Rini
  1 sibling, 0 replies; 3+ messages in thread
From: Peng Fan @ 2019-09-25  1:34 UTC (permalink / raw)
  To: u-boot

> Subject: [PATCH] mmc: am654_sdhci: Drop a redundant power_domain_on in
> probe
> 
> Power-domain is enabled by default in device_probe. am654 mmc driver is
> enabling power-domain again in probe. As the second call is redundant, drop
> power_domain_on from probe.
> 
> Tested-by: Suman Anna <s-anna@ti.com>
> Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
> ---
>  drivers/mmc/am654_sdhci.c | 13 -------------
>  1 file changed, 13 deletions(-)
> 
> diff --git a/drivers/mmc/am654_sdhci.c b/drivers/mmc/am654_sdhci.c index
> 1793a3f99a..7cd5516197 100644
> --- a/drivers/mmc/am654_sdhci.c
> +++ b/drivers/mmc/am654_sdhci.c
> @@ -219,23 +219,10 @@ static int am654_sdhci_probe(struct udevice *dev)
>  	struct mmc_uclass_priv *upriv = dev_get_uclass_priv(dev);
>  	struct sdhci_host *host = dev_get_priv(dev);
>  	struct mmc_config *cfg = &plat->cfg;
> -	struct power_domain sdhci_pwrdmn;
>  	struct clk clk;
>  	unsigned long clock;
>  	int ret;
> 
> -	ret = power_domain_get_by_index(dev, &sdhci_pwrdmn, 0);
> -	if (!ret) {
> -		ret = power_domain_on(&sdhci_pwrdmn);
> -		if (ret) {
> -			dev_err(dev, "Power domain on failed (%d)\n", ret);
> -			return ret;
> -		}
> -	} else if (ret != -ENOENT && ret != -ENODEV && ret != -ENOSYS) {
> -		dev_err(dev, "failed to get power domain (%d)\n", ret);
> -		return ret;
> -	}
> -
>  	ret = clk_get_by_index(dev, 0, &clk);
>  	if (ret) {
>  		dev_err(dev, "failed to get clock\n");

Reviewed-by: Peng Fan <peng.fan@nxp.com>

> --
> 2.22.0

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [U-Boot] [PATCH] mmc: am654_sdhci: Drop a redundant power_domain_on in probe
  2019-09-24  7:47 [U-Boot] [PATCH] mmc: am654_sdhci: Drop a redundant power_domain_on in probe Lokesh Vutla
  2019-09-25  1:34 ` Peng Fan
@ 2019-10-12 20:27 ` Tom Rini
  1 sibling, 0 replies; 3+ messages in thread
From: Tom Rini @ 2019-10-12 20:27 UTC (permalink / raw)
  To: u-boot

On Tue, Sep 24, 2019 at 01:17:16PM +0530, Lokesh Vutla wrote:

> Power-domain is enabled by default in device_probe. am654 mmc driver
> is enabling power-domain again in probe. As the second call is
> redundant, drop power_domain_on from probe.
> 
> Tested-by: Suman Anna <s-anna@ti.com>
> Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
> Reviewed-by: Peng Fan <peng.fan@nxp.com>

Applied to u-boot/master, thanks!

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20191012/a138f359/attachment.sig>

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2019-10-12 20:27 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-09-24  7:47 [U-Boot] [PATCH] mmc: am654_sdhci: Drop a redundant power_domain_on in probe Lokesh Vutla
2019-09-25  1:34 ` Peng Fan
2019-10-12 20:27 ` Tom Rini

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.