Remove dram_initr_banksize(), use mmu_set_region_dcache_behaviour()
in board_initr_caches_fixup() to set region MMU table attr is more
easily.
Change-Id: I9d9917e938fe5bbab5aa27575a5c8592ff08ab50
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
- import memblk id to manage memory blocks;
- change "sysmem_property" to generic "memblock";
- use alloc instead of reserve for all memory blocks;
- clean up and fix some logic;
- add U-Boot cmd for sysmem;
Change-Id: I614223ce3bf97a7b3566412a9d1864fb30b68fd8
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Provide generic id and struct for memory blocks.
Change-Id: I1fe00dfdb8ee8209eca55c8e7ebbedcafa0371a1
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
use rockchip_setup_ddr_param to setup ddr parameter.
The dram_init() and dram_init_banksize() make use of
sdram common code.
Change-Id: Icfc6cbef9fcc128e3a835184b46b89b9b22aab16
Signed-off-by: Zhihuan He <huan.he@rock-chips.com>
The uart, dmc and grf device add "u-boot,dm-pre-reloc".
Before relocated, u-boot will analyse dram capacity which
is need the device of "u-boot,dm-pre-reloc" attribute.
Change-Id: I1d18b564b0c521b176a2293a03403139034ccc0b
Signed-off-by: Zhihuan He <huan.he@rock-chips.com>
There are sometimes we would like to disable ctrlc, just enable it.
Change-Id: I2911650b22d47b057a039774d8293cad6317bb6d
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Add cd-gpios to test the mmc device whether exit.
Change-Id: I171f4c0d895baf1a1b54c971fc88370a0b10ce3a
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
We should keep the boot mode value, linux
kernel need it.
Change-Id: Ic31166dffc3fefdf352cac1d1002a91dea319fc5
Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
Simply return magic char if one is trying to read data beyond 32MB.
Fixes: 628c827 ("usb: rockusb: forbid reading data beyond addr 32MB")
Change-Id: If2cdf05dbf9d6dcdd4cf8f9605ab84480fbca32d
Signed-off-by: Shunqian Zheng <zhengsq@rock-chips.com>
The data layout for rockchip nandc is:
1024 bytes data + 32 obb + 1024 data + 32 obb ...
The system detect bad block flag locate at 2048, 4096, 8192...
The system checks for bad blocks and gets the wrong bad block.
Add a bad block detect api to check the bad block.
Change-Id: I8b0f2907a851d3bbb4d1b9f5daf21319bfb047d9
Signed-off-by: Yifeng Zhao <zyf@rock-chips.com>
Fix the following compile error:
drivers/mtd/nand/rockchip_nand.c: In function ‘nand_spl_load_image’:
drivers/mtd/nand/rockchip_nand.c:657:39: error: passing argument 3 of
‘nand_read_skip_bad’ from incompatible pointer type
[-Werror=incompatible-pointer-types]
return nand_read_skip_bad(mtd, offs, &size, NULL, size, (u_char
*)dst);
^
In file included from drivers/mtd/nand/rockchip_nand.c:11:0:
include/nand.h:101:5: note: expected ‘size_t * {aka long unsigned int
*}’ but argument is of type ‘unsigned int *’
int nand_read_skip_bad(struct mtd_info *mtd, loff_t offset, size_t
*length,
Change-Id: I44c97f21c2c2d40a7dcbdab7ddb96a1025949ee4
Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
When make with rock_defconfig, compile warning for the
following implicitly defined function are raised due to
a missing include directive:
drivers/usb/phy/rockchip_usb2_phy.c: In function ‘otg_phy_parse’:
drivers/usb/phy/rockchip_usb2_phy.c: 102:10: error:
implicit declaration of function ‘fdt_translate_address’ [-Werror=implicit-function-declaration]
addr = fdt_translate_address(blob, node, reg);
^~~~~~~~~~~~~~~~~~~~~
This change fixes this by including <fdt_support.h>.
And this patch also fixes the following compile error:
drivers/usb/phy/rockchip_usb2_phy.c:96:1: error:
label ‘retry’ defined but not used [-Werror=unused-label]
Change-Id: Ia82d0ff02b0f528ddde8a553d457c6c0cb763680
Signed-off-by: William Wu <william.wu@rock-chips.com>
With 8 bytes addressing even on 32 bit machines these checks
are no longer valid. Remove them.
Signed-off-by: Keerthy <j-keerthy@ti.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
(cherry picked from commit f51f6715a5013f37620c38f0430e21d4736e235a)
Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
Change-Id: I07d143dbd4dfeff1ce99d081d1279c4f70fa4e8f
Minus the retry-count in every boot with ab system. If the ab system
boot success, the system service boot_ctrl reset the retry-count or set
boot-successful.
Change-Id: Ic37f65b745d1feb978730332835246dc43d72dab
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
Since we use the pre-loader public key to verify permanent attribute, then
we do not need to write permanent attribute hash to otp & efuse.
Change-Id: Ic5e19fed2fc9405ab5bc7504dd930fd5f02d847c
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
A cmd only returned with CMD_RET_XXX defined
by command_ret_t can ensure it work well when
called from shell.
Change-Id: I16e76ed62928380eaaf3c352efb4df9463b7e72d
Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
Clears the corresponding interrupt bit of the PI_INT_STATUS
parameter before trigger data training.
Change-Id: Ic25c952a19913cb4332b6cd3405f41474585bfb1
Signed-off-by: YouMin Chen <cym@rock-chips.com>
1.increase the number of read retry, Triggered only when the
readout is wrong, so efficiency affects small
2.add nand buildin ecc support
3.skip ECC error block instead of marking as bad block
4.less debug printing
5.adjust the way of building tables to increase ftl init
Change-Id: I9cbc369472740d472dfad29449d1fd6529cd9877
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
Add cd-gpios to test the mmc device whether exit.
Change-Id: I6a07ff130e506678a20e5128ef4c8e608e0ec448
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
Add cd-gpios to test the mmc device whether exit.
Change-Id: I3d4839180b36de22ce1e5f2b26c9090b0686a8a0
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
Add cd-gpios to test the mmc device whether exit.
Change-Id: Ie1cfffe0f7826eae47fab705d3a3bb7d1a85f8ce
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>