diff options
author | Tom Rini <trini@konsulko.com> | 2016-06-20 05:14:01 -0400 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2016-06-20 05:14:01 -0400 |
commit | 09849f4a7779a247be8af5cfae44f7aad30e1222 (patch) | |
tree | 50891a9305714eff354702443555f52f1a65463c /drivers/spi/rk_spi.c | |
parent | 7c8ef0feb97586d35b0296b48903daef8c06ab21 (diff) | |
parent | 135aa95002646c46e89de93fa36adad1b010548f (diff) | |
download | u-boot-imx-09849f4a7779a247be8af5cfae44f7aad30e1222.zip u-boot-imx-09849f4a7779a247be8af5cfae44f7aad30e1222.tar.gz u-boot-imx-09849f4a7779a247be8af5cfae44f7aad30e1222.tar.bz2 |
Merge git://git.denx.de/u-boot-dm
Diffstat (limited to 'drivers/spi/rk_spi.c')
-rw-r--r-- | drivers/spi/rk_spi.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/spi/rk_spi.c b/drivers/spi/rk_spi.c index 9eff423..bc6dfd8 100644 --- a/drivers/spi/rk_spi.c +++ b/drivers/spi/rk_spi.c @@ -35,8 +35,7 @@ struct rockchip_spi_platdata { struct rockchip_spi_priv { struct rockchip_spi *regs; - struct udevice *clk; - int clk_id; + struct clk clk; unsigned int max_freq; unsigned int mode; ulong last_transaction_us; /* Time of last transaction end */ @@ -144,7 +143,6 @@ static int rockchip_spi_ofdata_to_platdata(struct udevice *bus) bus->name, ret); return ret; } - priv->clk_id = ret; plat->frequency = fdtdec_get_int(blob, node, "spi-max-frequency", 50000000); @@ -175,7 +173,7 @@ static int rockchip_spi_probe(struct udevice *bus) * Use 99 MHz as our clock since it divides nicely into 594 MHz which * is the assumed speed for CLK_GENERAL. */ - ret = clk_set_periph_rate(priv->clk, priv->clk_id, 99000000); + ret = clk_set_rate(&priv->clk, 99000000); if (ret < 0) { debug("%s: Failed to set clock: %d\n", __func__, ret); return ret; |