public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Jaehoon Chung <jh80.chung@samsung.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 1/7] mmc: uniphier-sd: Use mmc_of_parse()
Date: Thu, 25 Jan 2018 10:01:11 +0900	[thread overview]
Message-ID: <3c282e46-8cd1-ff17-7a1d-e178cffd1d6e@samsung.com> (raw)
In-Reply-To: <20180116171703.14361-1-marek.vasut+renesas@gmail.com>

Hi,

On 01/17/2018 02:16 AM, Marek Vasut wrote:
> Drop the ad-hoc DT caps parsing in favor of common framework function.
> 
> Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
> Cc: Jaehoon Chung <jh80.chung@samsung.com>
> Cc: Masahiro Yamada <yamada.masahiro@socionext.com>

If Masahiro is ok, i will pick this patch and others to u-boot-mmc.

Best Regards,
Jaehoon Chung

> ---
>  drivers/mmc/uniphier-sd.c | 23 +++++++----------------
>  1 file changed, 7 insertions(+), 16 deletions(-)
> 
> diff --git a/drivers/mmc/uniphier-sd.c b/drivers/mmc/uniphier-sd.c
> index 741f9dfd9c..552e37d852 100644
> --- a/drivers/mmc/uniphier-sd.c
> +++ b/drivers/mmc/uniphier-sd.c
> @@ -799,24 +799,15 @@ static int uniphier_sd_probe(struct udevice *dev)
>  		return ret;
>  	}
>  
> -	plat->cfg.name = dev->name;
> -	plat->cfg.host_caps = MMC_MODE_HS_52MHz | MMC_MODE_HS;
> -
> -	switch (fdtdec_get_int(gd->fdt_blob, dev_of_offset(dev), "bus-width",
> -			       1)) {
> -	case 8:
> -		plat->cfg.host_caps |= MMC_MODE_8BIT;
> -		break;
> -	case 4:
> -		plat->cfg.host_caps |= MMC_MODE_4BIT;
> -		break;
> -	case 1:
> -		break;
> -	default:
> -		dev_err(dev, "Invalid \"bus-width\" value\n");
> -		return -EINVAL;
> +	ret = mmc_of_parse(dev, &plat->cfg);
> +	if (ret < 0) {
> +		dev_err(dev, "failed to parse host caps\n");
> +		return ret;
>  	}
>  
> +	plat->cfg.name = dev->name;
> +	plat->cfg.host_caps |= MMC_MODE_HS_52MHz | MMC_MODE_HS;
> +
>  	if (quirks) {
>  		priv->caps = quirks;
>  	} else {
> 

  parent reply	other threads:[~2018-01-25  1:01 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20180116171714epcas3p3db32fc8c4d3c5b3eafd906c509d8daf2@epcas3p3.samsung.com>
2018-01-16 17:16 ` [U-Boot] [PATCH 1/7] mmc: uniphier-sd: Use mmc_of_parse() Marek Vasut
2018-01-16 17:16   ` [U-Boot] [PATCH V2 2/7] mmc: uniphier-sd: Properly handle pin voltage configuration Marek Vasut
2018-01-25 10:23     ` Masahiro Yamada
2018-01-29 20:55       ` Marek Vasut
2018-01-16 17:16   ` [U-Boot] [PATCH 3/7] mmc: uniphier-sd: Add Renesas RCar quirks Marek Vasut
2018-01-25 10:24     ` Masahiro Yamada
2018-01-16 17:17   ` [U-Boot] [PATCH 4/7] mmc: uniphier-sd: Handle Renesas div-by-1 Marek Vasut
2018-01-25 10:31     ` Masahiro Yamada
2018-01-16 17:17   ` [U-Boot] [PATCH 5/7] mmc: uniphier-sd: Add Renesas SDR104/HS200 tuning support Marek Vasut
2018-01-25 10:42     ` Masahiro Yamada
2018-01-16 17:17   ` [U-Boot] [PATCH 6/7] mmc: uniphier-sd: Handle DMA completion flag differences Marek Vasut
2018-01-25 10:49     ` Masahiro Yamada
2018-01-16 17:17   ` [U-Boot] [PATCH 7/7] mmc: uniphier-sd: Always check controller version Marek Vasut
2018-01-25 10:49     ` Masahiro Yamada
2018-01-25  1:01   ` Jaehoon Chung [this message]
2018-01-25 10:22     ` [U-Boot] [PATCH 1/7] mmc: uniphier-sd: Use mmc_of_parse() Masahiro Yamada
2018-01-06 19:29 Marek Vasut
2018-01-06 19:39 ` Marek Vasut

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=3c282e46-8cd1-ff17-7a1d-e178cffd1d6e@samsung.com \
    --to=jh80.chung@samsung.com \
    --cc=u-boot@lists.denx.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