[PATCH v4 03/10] clk: renesas: add R906G032 driver

Ralph Siemsen ralph.siemsen at linaro.org
Mon Apr 17 20:29:02 CEST 2023


On Mon, Apr 17, 2023 at 07:07:57PM +0200, Marek Vasut wrote:
>
>R-Car , not RCAR .

Ack, will fix in next version (including in some commit msg)

>>+static int r9a06g032_clk_probe(struct udevice *dev)
>>+{
>>+	struct r9a06g032_priv *priv = dev_get_priv(dev);
>>+	int err;
>>+
>>+	priv->regmap = syscon_regmap_lookup_by_phandle(dev, "regmap");
>>+	if (IS_ERR(priv->regmap)) {
>>+		dev_dbg(dev, "unable to find regmap\n");
>>+		return PTR_ERR(priv->regmap);
>>+	}
>>+
>>+	/* Enable S/W reset */
>>+	regmap_write(priv->regmap, 0x120, 0x41);
>>+
>>+	/* Get master clock */
>>+	err = clk_get_by_name(dev, "mclk", &priv->mclk);
>>+	if (err)
>>+		return err;
>>+
>>+	return 0;
>
>You can use 'return clk_get_by_name(...)' here directly instead of the

Will do.

Ralph


More information about the U-Boot mailing list