[U-Boot] [PATCH 0/7] Enable MIPI dsi display for rk3399

From: "eric.gao" eric.gao@rock-chips.com
This serial patchs enable mipi dsi display for rk3399,and let the system log print to lcd. The function of each patch is decribe in the following.Thank you. Patch 1: Fix system halt when we enable bucks of PMIC rk808. Patch 2: Enable i2c for rk3399. Patch 3: Enable PMIC rk808 for display system using. Patch 4: Enable rkclk init,prepare aclk dclk for vop. Patch 5: Add mipi display,panel driver and so on. Patch 6: Enable print log to lcd. Patch 7: Fix crash when scrolling screen.
eric.gao (7): system halt when we enable bucks of PMIC rk808 Enable i2c for rk3399 Enable RK808 for rk3399 evb Enable rkclk init function Add mipi display support for rk3399 && rk3288 Enable print log file to lcd crash when scroll screen
arch/arm/dts/rk3399-evb.dts | 141 +++++++++ arch/arm/dts/rk3399.dtsi | 88 ++++++ arch/arm/include/asm/arch-rockchip/cru_rk3399.h | 2 +- arch/arm/include/asm/arch-rockchip/mipi_rk3399.h | 203 +++++++++++++ arch/arm/include/asm/arch-rockchip/vop_rk3288.h | 1 + arch/arm/mach-rockchip/rk3399/syscon_rk3399.c | 1 + configs/evb-rk3399_defconfig | 11 + drivers/clk/rockchip/clk_rk3399.c | 4 + drivers/i2c/rk_i2c.c | 1 + drivers/video/Kconfig | 2 + drivers/video/console_normal.c | 2 +- drivers/video/rockchip/Kconfig | 44 +++ drivers/video/rockchip/Makefile | 7 +- drivers/video/rockchip/panel.c | 81 +++++ drivers/video/rockchip/rk_mipi.c | 371 +++++++++++++++++++++++ drivers/video/rockchip/rk_vop.c | 12 +- include/configs/rk3399_common.h | 5 +- 17 files changed, 969 insertions(+), 7 deletions(-) create mode 100644 arch/arm/include/asm/arch-rockchip/mipi_rk3399.h create mode 100644 drivers/video/rockchip/Kconfig create mode 100644 drivers/video/rockchip/panel.c create mode 100644 drivers/video/rockchip/rk_mipi.c

From: "eric.gao" eric.gao@rock-chips.com
if we enable PMIC rk808,the system will halt at very early stage ,log is shown as bellow.
INFO: plat_rockchip_pmu_init(1211): pd status 3e INFO: BL31: Initializing runtime services INFO: BL31: Preparing for EL3 exit to normal world INFO: Entry point address = 0x200000 INFO: SPSR = 0x3c9 time 44561b, 0 (<<----Just stop here)
It's caused by the absence of "{ }" in file rk3399/syscon_rk3399.c ,which will lead to memory overflow like below.According to Sysmap file ,we can find the function buck_get_value of rk808 is just follow the compatible struct, the pointer "of_match" point to "buck_get_value", but it is not a struct and don't have member of compatible, In this case,system crash. So,on the face, it looks like that rk808 is guilty. but he is really innocent.
while (of_match->compatible) { <<---------- if (!strcmp(of_match->compatible, compat)) { *of_idp = of_match; return 0; } of_match++; }
Signed-off-by: eric.gao eric.gao@rock-chips.com ---
arch/arm/mach-rockchip/rk3399/syscon_rk3399.c | 1 + 1 file changed, 1 insertion(+)
diff --git a/arch/arm/mach-rockchip/rk3399/syscon_rk3399.c b/arch/arm/mach-rockchip/rk3399/syscon_rk3399.c index d32985b..74d4552 100644 --- a/arch/arm/mach-rockchip/rk3399/syscon_rk3399.c +++ b/arch/arm/mach-rockchip/rk3399/syscon_rk3399.c @@ -14,6 +14,7 @@ static const struct udevice_id rk3399_syscon_ids[] = { { .compatible = "rockchip,rk3399-pmugrf", .data = ROCKCHIP_SYSCON_PMUGRF }, { .compatible = "rockchip,rk3399-pmusgrf", .data = ROCKCHIP_SYSCON_PMUSGRF }, { .compatible = "rockchip,rk3399-cic", .data = ROCKCHIP_SYSCON_CIC }, + { } };
U_BOOT_DRIVER(syscon_rk3399) = {
participants (1)
-
eric.gao@rock-chips.com