Use system api dev_read_addr_ptr to get cru reg base,
rather than rockchip private api rockchip_get_cru, which
will be cleanup later.

Signed-off-by: Andy Yan <andy....@rock-chips.com>
---

 drivers/sysreset/sysreset_rockchip.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/sysreset/sysreset_rockchip.c 
b/drivers/sysreset/sysreset_rockchip.c
index 894975f..6c584d0 100644
--- a/drivers/sysreset/sysreset_rockchip.c
+++ b/drivers/sysreset/sysreset_rockchip.c
@@ -10,14 +10,12 @@
 #include <sysreset.h>
 #include <asm/io.h>
 #include <asm/arch/clock.h>
-#include <asm/arch/cru_rk3328.h>
-#include <asm/arch/hardware.h>
 #include <linux/err.h>
 
 int rockchip_sysreset_request(struct udevice *dev, enum sysreset_t type)
 {
        struct sysreset_reg *offset = dev_get_priv(dev);
-       unsigned long cru_base = (unsigned long)rockchip_get_cru();
+       unsigned long cru_base = (unsigned long)dev_read_addr_ptr(dev->parent);
 
        if (IS_ERR_VALUE(cru_base))
                return (int)cru_base;
-- 
2.7.4


_______________________________________________
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot

Reply via email to