From: Marek Vasut Date: Fri, 13 Oct 2017 13:40:59 +0200 Subject: [U-Boot] [PATCH 2/6] mmc: uniphier-sd: Use mmc_of_parse() In-Reply-To: References: <20171006120707.14385-1-marek.vasut+renesas@gmail.com> <20171006120707.14385-2-marek.vasut+renesas@gmail.com> Message-ID: List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On 10/13/2017 01:36 PM, Masahiro Yamada wrote: > Hi Marek, > > 2017-10-06 21:07 GMT+09:00 Marek Vasut : >> Drop the ad-hoc DT caps parsing in favor of common framework function. >> >> Signed-off-by: Marek Vasut >> Cc: Jaehoon Chung >> Cc: Masahiro Yamada > > > "git grep" could not find mmc_of_parse. > > > Are you waiting for this one? > > http://patchwork.ozlabs.org/patch/816911/ Yeah, I think Jaehoon is testing the patchset again . Hopefully this time there will be some result from the testing ... >> 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 784bb883ce..cf85ec23c7 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(gd->fdt_blob, dev_of_offset(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; >> >> -- >> 2.11.0 >> >> _______________________________________________ >> U-Boot mailing list >> U-Boot at lists.denx.de >> https://lists.denx.de/listinfo/u-boot > > > -- Best regards, Marek Vasut