diff options
author | Tom Rini <trini@konsulko.com> | 2016-11-02 09:41:20 -0400 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2016-11-02 09:41:20 -0400 |
commit | 7fd117389ec7bbd0ce2fbb98ce47c20f5b8a0cfb (patch) | |
tree | e3cac6c8365b63bfa1e5251eebec7f1bf68ac098 /arch/arm/mach-rockchip/rk3288/clk_rk3288.c | |
parent | d8bdfc80da39211d95f10d24e79f2e867305f71b (diff) | |
parent | 4594ac07847f5c7fe7294ce6c71849fea0a431e0 (diff) | |
download | u-boot-imx-7fd117389ec7bbd0ce2fbb98ce47c20f5b8a0cfb.zip u-boot-imx-7fd117389ec7bbd0ce2fbb98ce47c20f5b8a0cfb.tar.gz u-boot-imx-7fd117389ec7bbd0ce2fbb98ce47c20f5b8a0cfb.tar.bz2 |
Merge git://git.denx.de/u-boot-rockchip
Diffstat (limited to 'arch/arm/mach-rockchip/rk3288/clk_rk3288.c')
-rw-r--r-- | arch/arm/mach-rockchip/rk3288/clk_rk3288.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/arch/arm/mach-rockchip/rk3288/clk_rk3288.c b/arch/arm/mach-rockchip/rk3288/clk_rk3288.c index 2099e34..a45b923 100644 --- a/arch/arm/mach-rockchip/rk3288/clk_rk3288.c +++ b/arch/arm/mach-rockchip/rk3288/clk_rk3288.c @@ -9,9 +9,25 @@ #include <dm.h> #include <syscon.h> #include <asm/arch/clock.h> +#include <asm/arch/cru_rk3288.h> int rockchip_get_clk(struct udevice **devp) { return uclass_get_device_by_driver(UCLASS_CLK, DM_GET_DRIVER(rockchip_rk3288_cru), devp); } + +void *rockchip_get_cru(void) +{ + struct rk3288_clk_priv *priv; + struct udevice *dev; + int ret; + + ret = rockchip_get_clk(&dev); + if (ret) + return ERR_PTR(ret); + + priv = dev_get_priv(dev); + + return priv->cru; +} |