All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] mmc: omap_hsmmc: get capabilities from DT
@ 2013-08-14 20:40 ` Daniel Mack
  0 siblings, 0 replies; 4+ messages in thread
From: Daniel Mack @ 2013-08-14 20:40 UTC (permalink / raw)
  To: balajitk, linux-mmc; +Cc: cjb, linux-arm-kernel, Daniel Mack

When used in DT mode, the omap hsmmc driver has to take capabilites
given in DT by calling mmc_of_parse().

Signed-off-by: Daniel Mack <zonque@gmail.com>
---
 drivers/mmc/host/omap_hsmmc.c | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/drivers/mmc/host/omap_hsmmc.c b/drivers/mmc/host/omap_hsmmc.c
index 1865321..31337c1 100644
--- a/drivers/mmc/host/omap_hsmmc.c
+++ b/drivers/mmc/host/omap_hsmmc.c
@@ -1907,7 +1907,15 @@ static int omap_hsmmc_probe(struct platform_device *pdev)
 	if (mmc_slot(host).nonremovable)
 		mmc->caps |= MMC_CAP_NONREMOVABLE;
 
-	mmc->pm_caps = mmc_slot(host).pm_caps;
+	if (pdev->dev.of_node) {
+		ret = mmc_of_parse(mmc);
+		if (ret < 0) {
+			dev_err(&pdev->dev, "mmc_of_parse() failed: %d\n", ret);
+			goto err_irq;
+		}
+	} else {
+		mmc->pm_caps = mmc_slot(host).pm_caps;
+	}
 
 	omap_hsmmc_conf_bus_power(host);
 
-- 
1.8.3.1


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

* [PATCH] mmc: omap_hsmmc: get capabilities from DT
@ 2013-08-14 20:40 ` Daniel Mack
  0 siblings, 0 replies; 4+ messages in thread
From: Daniel Mack @ 2013-08-14 20:40 UTC (permalink / raw)
  To: linux-arm-kernel

When used in DT mode, the omap hsmmc driver has to take capabilites
given in DT by calling mmc_of_parse().

Signed-off-by: Daniel Mack <zonque@gmail.com>
---
 drivers/mmc/host/omap_hsmmc.c | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/drivers/mmc/host/omap_hsmmc.c b/drivers/mmc/host/omap_hsmmc.c
index 1865321..31337c1 100644
--- a/drivers/mmc/host/omap_hsmmc.c
+++ b/drivers/mmc/host/omap_hsmmc.c
@@ -1907,7 +1907,15 @@ static int omap_hsmmc_probe(struct platform_device *pdev)
 	if (mmc_slot(host).nonremovable)
 		mmc->caps |= MMC_CAP_NONREMOVABLE;
 
-	mmc->pm_caps = mmc_slot(host).pm_caps;
+	if (pdev->dev.of_node) {
+		ret = mmc_of_parse(mmc);
+		if (ret < 0) {
+			dev_err(&pdev->dev, "mmc_of_parse() failed: %d\n", ret);
+			goto err_irq;
+		}
+	} else {
+		mmc->pm_caps = mmc_slot(host).pm_caps;
+	}
 
 	omap_hsmmc_conf_bus_power(host);
 
-- 
1.8.3.1

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

* Re: [PATCH] mmc: omap_hsmmc: get capabilities from DT
  2013-08-14 20:40 ` Daniel Mack
@ 2013-08-25  4:23   ` Chris Ball
  -1 siblings, 0 replies; 4+ messages in thread
From: Chris Ball @ 2013-08-25  4:23 UTC (permalink / raw)
  To: Daniel Mack; +Cc: balajitk, linux-mmc, linux-arm-kernel

Hi,

On Wed, Aug 14 2013, Daniel Mack wrote:
> When used in DT mode, the omap hsmmc driver has to take capabilites
> given in DT by calling mmc_of_parse().
>
> Signed-off-by: Daniel Mack <zonque@gmail.com>
> ---
>  drivers/mmc/host/omap_hsmmc.c | 10 +++++++++-
>  1 file changed, 9 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/mmc/host/omap_hsmmc.c b/drivers/mmc/host/omap_hsmmc.c
> index 1865321..31337c1 100644
> --- a/drivers/mmc/host/omap_hsmmc.c
> +++ b/drivers/mmc/host/omap_hsmmc.c
> @@ -1907,7 +1907,15 @@ static int omap_hsmmc_probe(struct platform_device *pdev)
>  	if (mmc_slot(host).nonremovable)
>  		mmc->caps |= MMC_CAP_NONREMOVABLE;
>  
> -	mmc->pm_caps = mmc_slot(host).pm_caps;
> +	if (pdev->dev.of_node) {
> +		ret = mmc_of_parse(mmc);
> +		if (ret < 0) {
> +			dev_err(&pdev->dev, "mmc_of_parse() failed: %d\n", ret);
> +			goto err_irq;
> +		}
> +	} else {
> +		mmc->pm_caps = mmc_slot(host).pm_caps;
> +	}
>  
>  	omap_hsmmc_conf_bus_power(host);

Balaji, please can you review this patch?  Thanks,

- Chris.
-- 
Chris Ball   <cjb@laptop.org>   <http://printf.net/>

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

* [PATCH] mmc: omap_hsmmc: get capabilities from DT
@ 2013-08-25  4:23   ` Chris Ball
  0 siblings, 0 replies; 4+ messages in thread
From: Chris Ball @ 2013-08-25  4:23 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

On Wed, Aug 14 2013, Daniel Mack wrote:
> When used in DT mode, the omap hsmmc driver has to take capabilites
> given in DT by calling mmc_of_parse().
>
> Signed-off-by: Daniel Mack <zonque@gmail.com>
> ---
>  drivers/mmc/host/omap_hsmmc.c | 10 +++++++++-
>  1 file changed, 9 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/mmc/host/omap_hsmmc.c b/drivers/mmc/host/omap_hsmmc.c
> index 1865321..31337c1 100644
> --- a/drivers/mmc/host/omap_hsmmc.c
> +++ b/drivers/mmc/host/omap_hsmmc.c
> @@ -1907,7 +1907,15 @@ static int omap_hsmmc_probe(struct platform_device *pdev)
>  	if (mmc_slot(host).nonremovable)
>  		mmc->caps |= MMC_CAP_NONREMOVABLE;
>  
> -	mmc->pm_caps = mmc_slot(host).pm_caps;
> +	if (pdev->dev.of_node) {
> +		ret = mmc_of_parse(mmc);
> +		if (ret < 0) {
> +			dev_err(&pdev->dev, "mmc_of_parse() failed: %d\n", ret);
> +			goto err_irq;
> +		}
> +	} else {
> +		mmc->pm_caps = mmc_slot(host).pm_caps;
> +	}
>  
>  	omap_hsmmc_conf_bus_power(host);

Balaji, please can you review this patch?  Thanks,

- Chris.
-- 
Chris Ball   <cjb@laptop.org>   <http://printf.net/>

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

end of thread, other threads:[~2013-08-25  4:23 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-08-14 20:40 [PATCH] mmc: omap_hsmmc: get capabilities from DT Daniel Mack
2013-08-14 20:40 ` Daniel Mack
2013-08-25  4:23 ` Chris Ball
2013-08-25  4:23   ` Chris Ball

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.