Rockchip platforms defines BCB message at the 16KB offset of
misc partition while the Google defines it at 0x0 offset.
From Android-Q, the 0x0 offset is mandary on Google VTS.
Change-Id: Iac36d421ed605684353c30bfe0e9982bdd5de065
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Support command like: reboot loader/bootloader/recovery, etc.
It depends on the node whose compatible is "syscon-reboot-mode".
Change-Id: I3ef497c6a4355a0d8be9a277bd77bbee43df57fb
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
We are using DRAM offset 0~0x40000 as SPL text size, Note that BSS,
STACK and MALLOC may using separate space.
Change-Id: I1d9128b339140569e427fad44dc0a2f3058deaf0
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
- the partition disk layer takes over the responsibility of slot suffix
appending, we remove relative code to make file clean;
- put android a/b code together and name them to be eary understood,
this makes file esay to read.
Change-Id: Id8c838da682ce6098bd7192d7d7c64269f4e86ba
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
- The U-disk boot is only supported from U-Boot, the earlier preloader
doesn't support it;
- MMC1(SD) has higher priority than U-disk;
- Always boot into recovery mode and deliver "usbfwupdate" to cmdline;
- Usb driver may depend on clock/regulator init, so behind of them;
- Suggest to add ./dts/kern.dtb file to promise the kernel dtb always
to be loaded successfully even the native images are all damaged.
Change-Id: Ibbb2a061a727752277ac1b80abf362de5d94cca2
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
- It provides a way to promise kernel dtb can be loaded successfully
even when the image is damaged.
- This makes developers easily to add what they what just like a "U-Boot" dtb.
- The kern.dtb file is pack into the end of u-boot.bin while ./dts/kern.dtb
is exist.
Change-Id: I93a36a9c65ea8719e5610cdcbcc7708e5337c53f
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Add "fasboot getvar is-userspace" support.
The Android-Q document shows "not allow the flashing of dynamic partitions"
is not aimed at the physical partition(call "super") but its child partitions
(i.e. system, vendor, oem...).
Change-Id: I4e21a9728a1093b68a9d1a08420586f33dcf0117
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
- disable virq chip by default;
- fix bank->use_count little than 0;
Change-Id: I69aa07cc2924dab40eea6524588869361ad8cf66
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
The commit point is updated to google external/avb/
which commit point is 868db2a514bbb02e166fb55b1592b27de8c9680c.
Change-Id: I10f7c0ac356a7666b518b62e59ccb62277668578
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
We are going to update atf base to 0x40000, so that we can use space
0~0x40000 for SPL without relocate for support ATF.
0x40000 should be enough for SPL text, and we have separate BSS and
STACK.
Change-Id: I081d289f10a54d8a98e9f466e1730659f2c712a3
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
Some bridge can't get tv edid such as rk1000 cvbs, but
at present bridge can't provide timing without edid. So
we add get_timing interface to provide timing.
Change-Id: Id74802a3bff8140e3677f6633788aacd021afc91
Signed-off-by: Algea Cao <algea.cao@rock-chips.com>
- We have implement dump_stack() for both ARM and ARM64;
- It was brought back by careless on commit: (28386b6 UPSTREAM: lib: Add hexdump)
Change-Id: I8ebbd46862475485963d2ac835ea4031207d2153
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
This takes the latest changes from AOSP from the file
include/bootimg/bootimg.h from the repository:
https://android.googlesource.com/platform/system/tools/mkbootimg
and update the U-Boot version with the latest changes.
This file keeps the changes from AOSP to a minimum:
* Comments were converted from C++ to C style.
* Code inside __cplusplus #ifdef blocks were removed.
* C++11 struct extensions replaced with a single struct.
Change-Id: Ifdfa7cc365a28e45ab7f192c121b49f6da99af36
Signed-off-by: Alex Deymo <deymo@google.com>
Reviewed-by: Sam Protsenko <semen.protsenko@linaro.org>
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
(cherry picked from commit 0b6febfdb3cf9b4a51fa65fbd94f9ab2d7738f32)
Since AVB use sysmem alloc, we can decrease malloc size.
Change-Id: I1c81f13946b3f8e74b2400f9d12be882e4387b38
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Since AVB use sysmem alloc, we can decrease malloc size.
Change-Id: Ie863ed0627dd8604c8dbc8b59ed8f4197c68bc93
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Since AVB use sysmem alloc, we can decrease malloc size.
Change-Id: Ic5a2df1fbfec0e6d94f9904042db8961aa0abf4d
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Since AVB use sysmem alloc, we can decrease malloc size.
Change-Id: If806c7736ada2852931f8e06d137658d8cf3c0db
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Since AVB use sysmem alloc, we can decrease malloc size.
Change-Id: If88b142a81f5cd28f333b9dc901e70619b9ce12b
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Since AVB use sysmem alloc, we can decrease malloc size.
Change-Id: I627ceab0440a1655524904a8c4b11905bcdc830d
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
This is a encapsulation of android_image_load_separate(). It is used
for AVB boot/recovery.img which has been loaded to ram by AVB bootflow,
and we memcpy kernel/ramdisk/dtb to where we expect.
Change-Id: Iea4ea3404b84e9d3c091954ab27fb8c9d2ad84bc
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
- This makes arch_preboot_os() more flexsible;
- call arch_preboot_os() when BOOTM_STATE_OS_PREP;
Change-Id: Ia4ae3666b8180c993c761ef222acbcff5358ae97
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
We add secure_conf_base & otp_mask_base to platdata to operate
the secure OTP.
Change-Id: Ie336b2cf61076aa82f7c1987cc3cec7166751452
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
New name is more accurate about internal implementation..
Change-Id: I16891f5f614fbb17f1e65e04ef4d8a713c8624f3
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
At sometime, its parent driver would setup the main interrupt(e.g. PMIC).
Change-Id: I8d24266c48f515fc92c3529a5b6aa7a18d181af1
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
So that the child drivers can request their irq through the
generic interrupt framework.
Include: RK805/808/816/817/818.
Change-Id: I5556f2e926e850ac6717a05166eab5e19566d531
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
This patch support the device to add its interrupt controller as "irq chip"
into generic interrupt framework, the other driver can request its child
interrupt like a real hardware irq.
Example for PMIC:
GIC-\
|- ...
|- GPIO-\
|- ...
|- PMIC-\
|_ virq_0
|_ virq_1
|_ virq_2
|...
|_ virq_n
Change-Id: I17716f3db494a85fc22b23ff18042771a6116da8
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
The NAND sub-layers are likely to need the MTD_OPS_XXX mode information
in order to decide if they should enable/disable ECC or how they should
place the OOB bytes in the provided OOB buffer.
Add a field to nand_page_io_req to pass this information.
Signed-off-by: Boris Brezillon <boris.brezillon@bootlin.com>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Change-Id: Idb70434140c0304cfc97d7f3c52cbeca349fdff8
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
(cherry picked from commit f86787280b37e381f8d82f48583434d62dd16e27)
Porting from: https://tls.mbed.org/sha-512-source-code.
Update and follow sha1/256.c function name and coding style.
Change-Id: Idbe70b71e54e0e56a88aac5ec306c75fb2237f4f
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
spl_perform_fixups
On some boards, we want to give the board/architecture-specific code a
chance to look at where the next image has been loaded from and
perform fixups before starting the next image. This is of particular
importance, when we probe multiple devices for bootable payloads and
boot the first one found.
This change adds the following:
- we record the boot_device used into the spl_image structure
- we provide an extension-point for boards/architectures that can
perform late fixups depending on a fully populated spl_image
structure (i.e. we'll know the final boot_device and have info
on the image type and operating system to be booted).
Change-Id: Iebca59a61979bc12eabe743c73dc2279e870e2ff
Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Tested-by: Klaus Goger <klaus.goger@theobroma-systems.com>
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>