The arch_cpu_init() should be called for cpu early init
for tpl.
Change-Id: I3aad0f284089d8523710a2d24daab44995fa148d
Signed-off-by: Zhihuan He <huan.he@rock-chips.com>
This patch fixes the following issues for rk3568 usb2 phy.
1. Set utmi opmode to normal mode for rk3568 usb phy when usb
phy enter suspend mode via usb phy grf. It can help to avoid
the DM/DP floating and the line state be detected as 2'b11.
2. Fix the offset of INT_STATUS_CLR. It can help to avoid
triggering the linestate irq constantly.
Signed-off-by: Ren Jianing <jianing.ren@rock-chips.com>
Change-Id: Ic108e116d1473341b61743ec4244bc034a95f501
The i2c5 xfer went wrong because of io-domain was not right
and was configured correctly in uboot to ensure that kernel
was right before initializing the io-domain driver.
Change-Id: Ic2f94952f7a851dc5b781af9f31bba2562b5a2b5
Signed-off-by: David Wu <david.wu@rock-chips.com>
Support get commit version of components image.
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Change-Id: Ic279ed457949a98693571ec2a8ff2cfac4e0469d
Before the patch, we get gpio index(0,1,2..) depends on gpio
fdt node name, such as: gpio0@..., gpio1@..., etc.
But from RK3568, we add gpio alias to indicate gpio index
information and index is removed from gpio node name, ie:
gpio@fdd60000, gpio@fe740000, etc.
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Change-Id: I56e45941f9572fbc6a5a5916896e12f6eff9dcf3
kernel FDT is for U-Boot if there is not valid one from images,
ie: resource.img, boot.img or recovery.img. It is put right
after U-Boot FDT.
This is used for U-disk bing up.
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Change-Id: I348b6ea5736f46c091284c501e7e0f9c64cd2f78
kernel FDT is for U-Boot if there is not valid one from images,
ie: resource.img, boot.img or recovery.img. It is put right
after U-Boot FDT.
This is used for U-disk bing up.
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Change-Id: Iab1ddbbf3978a6b2fc08316bb136c43c0d2eef60
Simply check cru node to verify if this kernel dtb
is belong to current platform.
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Change-Id: I8c0b2181a2ca3cada72a9e18788de0bfdc9ba3c5
In the 3.0 device core, if the core is programmed to operate in
2.0 only, then setting the GUCTL1.DEV_FORCE_20_CLK_FOR_30_CLK makes
the internal 2.0(utmi/ulpi) clock to be routed as the 3.0 (pipe)
clock. Enabling this feature allows the pipe3 clock to be not-running
when forcibly operating in 2.0 device mode.
Change-Id: Ib93da14b5309ec094b952e03f8514817910fedfa
Signed-off-by: William Wu <william.wu@rock-chips.com>
arch/arm/mach-rockchip/decode_bl31.py depends on pyelftools.
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Change-Id: Ic7a0524df5b58472b5cb73e8b0c83a997426eb1b
RK3568 has two USB 2.0 PHYs, and each PHY has two ports, the
OTG port of PHY0 support OTG mode with charging detection
function, they are similar to previous Rockchip SoCs.
However, there are three different designs for RK3568 USB 2.0 PHY.
1. RK3568 uses independent USB GRF module for each USB 2.0 PHY.
2. RK3568 accesses the registers of USB 2.0 PHY IP directly by APB.
3. The two ports of USB 2.0 PHY share one interrupt.
Signed-off-by: Ren Jianing <jianing.ren@rock-chips.com>
Change-Id: Ia33d3de222a6c7f263290f4098d0a5e557a9d568
Special handle:
Once the BCB offset changes, reinitialize "boot_mode".
Background:
1. there are two Android BCB at the 0x00 and 0x20 offset in
misc.img to compatible legacy(0x20) SDK.
2. android_bcb_msg_sector_offset() is for android image:
return 0x20 if image version < 10, otherwise 0x00.
3. If not android image, BCB at 0x20 is the valid one.
U-Boot can support booting both FIT & Android image, if FIT
boot flow enters here early than Android, the "boot_mode" is
set as BOOT_MODE_RECOVERY according to BCB at 0x20 offset.
After that, this function always return static variable "boot_mode"
as BOOT_MODE_RECOVERY even android(>=10) boot flow enter here.
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Change-Id: I0ed05ba1b18447a58d3faff37ac50ecc79fab374
Restore main fdt if it's destroyed by fdt_overlay_apply()
when overlay failed.
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Change-Id: Id26085f2df89d208caadeb3c4ce33f21f896ee22