diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/clk/renesas/Kconfig | 1 | ||||
-rw-r--r-- | drivers/mmc/renesas-sdhi.c | 30 | ||||
-rw-r--r-- | drivers/pinctrl/renesas/sh_pfc.h | 15 | ||||
-rw-r--r-- | drivers/sysinfo/rcar3.c | 19 |
4 files changed, 41 insertions, 24 deletions
diff --git a/drivers/clk/renesas/Kconfig b/drivers/clk/renesas/Kconfig index 1686410d6d3..d58e897ca1b 100644 --- a/drivers/clk/renesas/Kconfig +++ b/drivers/clk/renesas/Kconfig @@ -49,6 +49,7 @@ config CLK_RCAR_GEN3 def_bool y if RCAR_GEN3 depends on CLK_RENESAS select CLK_RCAR_CPG_LIB + select DM_RESET help Enable this to support the clocks on Renesas RCar Gen3 SoC. diff --git a/drivers/mmc/renesas-sdhi.c b/drivers/mmc/renesas-sdhi.c index 4a1accebfcb..34119f949aa 100644 --- a/drivers/mmc/renesas-sdhi.c +++ b/drivers/mmc/renesas-sdhi.c @@ -977,34 +977,50 @@ static int renesas_sdhi_probe(struct udevice *dev) /* optional SDnH clock */ ret = clk_get_by_name(dev, "clkh", &priv->clkh); - if (ret < 0) + if (ret < 0) { dev_dbg(dev, "failed to get clkh\n"); + } else { + ret = clk_set_rate(&priv->clkh, 800000000); + if (ret < 0) { + dev_err(dev, "failed to set rate for SDnH clock (%d)\n", ret); + goto err_clk; + } + } /* set to max rate */ ret = clk_set_rate(&priv->clk, 200000000); if (ret < 0) { - dev_err(dev, "failed to set rate for host clock\n"); - clk_free(&priv->clk); - return ret; + dev_err(dev, "failed to set rate for SDn clock (%d)\n", ret); + goto err_clkh; } ret = clk_enable(&priv->clk); if (ret) { - dev_err(dev, "failed to enable host clock\n"); - return ret; + dev_err(dev, "failed to enable SDn clock (%d)\n", ret); + goto err_clkh; } priv->quirks = quirks; ret = tmio_sd_probe(dev, quirks); + if (ret) + goto err_tmio_probe; renesas_sdhi_filter_caps(dev); #if CONFIG_IS_ENABLED(MMC_UHS_SUPPORT) || \ CONFIG_IS_ENABLED(MMC_HS200_SUPPORT) || \ CONFIG_IS_ENABLED(MMC_HS400_SUPPORT) - if (!ret && (priv->caps & TMIO_SD_CAP_RCAR_UHS)) + if (priv->caps & TMIO_SD_CAP_RCAR_UHS) renesas_sdhi_reset_tuning(priv); #endif + return 0; + +err_tmio_probe: + clk_disable(&priv->clk); +err_clkh: + clk_free(&priv->clkh); +err_clk: + clk_free(&priv->clk); return ret; } diff --git a/drivers/pinctrl/renesas/sh_pfc.h b/drivers/pinctrl/renesas/sh_pfc.h index 59d447ead5c..0ab743e80d5 100644 --- a/drivers/pinctrl/renesas/sh_pfc.h +++ b/drivers/pinctrl/renesas/sh_pfc.h @@ -309,21 +309,6 @@ extern const struct sh_pfc_soc_info r8a77980_pinmux_info; extern const struct sh_pfc_soc_info r8a77990_pinmux_info; extern const struct sh_pfc_soc_info r8a77995_pinmux_info; extern const struct sh_pfc_soc_info r8a779a0_pinmux_info; -extern const struct sh_pfc_soc_info r8a779f0_pinmux_info; -extern const struct sh_pfc_soc_info r8a779g0_pinmux_info; -extern const struct sh_pfc_soc_info sh7203_pinmux_info; -extern const struct sh_pfc_soc_info sh7264_pinmux_info; -extern const struct sh_pfc_soc_info sh7269_pinmux_info; -extern const struct sh_pfc_soc_info sh73a0_pinmux_info; -extern const struct sh_pfc_soc_info sh7720_pinmux_info; -extern const struct sh_pfc_soc_info sh7722_pinmux_info; -extern const struct sh_pfc_soc_info sh7723_pinmux_info; -extern const struct sh_pfc_soc_info sh7724_pinmux_info; -extern const struct sh_pfc_soc_info sh7734_pinmux_info; -extern const struct sh_pfc_soc_info sh7757_pinmux_info; -extern const struct sh_pfc_soc_info sh7785_pinmux_info; -extern const struct sh_pfc_soc_info sh7786_pinmux_info; -extern const struct sh_pfc_soc_info shx3_pinmux_info; /* ----------------------------------------------------------------------------- * Helper macros to create pin and port lists diff --git a/drivers/sysinfo/rcar3.c b/drivers/sysinfo/rcar3.c index c2f4ddfbbe3..7b127986da7 100644 --- a/drivers/sysinfo/rcar3.c +++ b/drivers/sysinfo/rcar3.c @@ -16,12 +16,14 @@ #define BOARD_SALVATOR_X 0x0 #define BOARD_KRIEK 0x1 #define BOARD_STARTER_KIT 0x2 +#define BOARD_EAGLE 0x3 #define BOARD_SALVATOR_XS 0x4 +#define BOARD_CONDOR 0x6 +#define BOARD_DRAAK 0x7 #define BOARD_EBISU 0x8 #define BOARD_STARTER_KIT_PRE 0xB #define BOARD_EBISU_4D 0xD -#define BOARD_DRAAK 0xE -#define BOARD_EAGLE 0xF +#define BOARD_CONDOR_I 0x10 /** * struct sysinfo_rcar_priv - sysinfo private data @@ -65,6 +67,7 @@ static void sysinfo_rcar_parse(struct sysinfo_rcar_priv *priv) const u8 board_rev = priv->val & BOARD_REV_MASK; bool salvator_xs = false; bool ebisu_4d = false; + bool condor_i = false; char rev_major = '?'; char rev_minor = '?'; @@ -138,6 +141,18 @@ static void sysinfo_rcar_parse(struct sysinfo_rcar_priv *priv) "Renesas Kriek board rev %c.%c", rev_major, rev_minor); return; + case BOARD_CONDOR_I: + condor_i = true; + fallthrough; + case BOARD_CONDOR: + if (!board_rev) { /* Only rev 0 is valid */ + rev_major = '1'; + rev_minor = '0'; + } + snprintf(priv->boardmodel, sizeof(priv->boardmodel), + "Renesas Condor%s board rev %c.%c", + condor_i ? "-I" : "", rev_major, rev_minor); + return; default: snprintf(priv->boardmodel, sizeof(priv->boardmodel), "Renesas -Unknown- board rev ?.?"); |