[U-Boot] [RFC PATCH 0/6] rockchip: rk3368: remove secure timer usage and use DM timer
Dr. Philipp Tomsich
philipp.tomsich at theobroma-systems.com
Wed Aug 2 11:09:11 UTC 2017
This patchset does not force the use of the DM timer for any chipsets/boards.
It is essentially opt-in and (for now—i.e. until we enable it for the RK3399) it is
enabled for the RK3368 only.
Note that this does not currently target any ARMv7 devices, as it is meant to
decouple the ARMv8 generic timer startup (i.e. starting the stimer) from U-Boot.
> On 02 Aug 2017, at 07:05, Kever Yang <kever.yang at rock-chips.com> wrote:
> Hi Philipp, Simon,
> I still think we should have a option to no involve so much framework thing in
> very early boot stage like TPL/SPL, for those chipset with very little sram onchip.
> Andy send some patches for rk3036 recently, because it get out of memory in SPL
> and not able to boot. Most of people do not notice this but please leave a option for
> those devices. The timer init should always happen very early like SPL/TPL, and I don't
> think the DM is a must for it.
> - Kever
> On 07/29/2017 12:31 AM, Philipp Tomsich wrote:
>> Trying to answer Simon's question whether the address of the secure
>> timer (for initialising stimer1 and starting up the ARMv8 generic
>> timer) can be obtained from the DTS, here's a series that tries to
>> give an answer.
>> To summarise this answer in plain English:
>> - The answer to the original question is: "no, but..."
>> - The "but" is what's implemented here: we don't need the ARMv8
>> generic timer ticking in U-Boot, so we won't have to initialise it
>> at all (this removing the need to obtain the address for stimer1).
>> - We also have a "however": the size of the TPL binary increases by
>> approx. 800 bytes, as we need the DM timer support.
>> This series is based on-top-of my RK3368 enablement series.
>> If we go ahead with merging this, then I'll have to add support for
>> the RK3399 as well...
>> Philipp Tomsich (6):
>> timer: add OF_PLATDATA support for timer-uclass
>> dm: timer: normalise SPL and TPL support
>> rockchip: timer: add device-model timer driver for RK3368 (and
>> dts: rk3368: make timer0 accessible for SPL and TPL
>> rockchip: lion-rk3368: defconfig: enable DM timer for all stages
>> rockchip: rk3368: remove setup of secure timer from TPL/SPL
>> arch/arm/cpu/armv8/Makefile | 2 +
>> arch/arm/dts/rk3368-lion-u-boot.dtsi | 2 +-
>> arch/arm/dts/rk3368.dtsi | 2 +-
>> arch/arm/mach-rockchip/rk3368-board-spl.c | 20 ------
>> arch/arm/mach-rockchip/rk3368-board-tpl.c | 19 ------
>> common/spl/Kconfig | 8 ---
>> configs/chromebook_link64_defconfig | 2 +-
>> configs/lion-rk3368_defconfig | 4 ++
>> configs/qemu-x86_64_defconfig | 2 +-
>> drivers/Makefile | 3 +-
>> drivers/timer/Kconfig | 25 +++++++
>> drivers/timer/Makefile | 3 +-
>> drivers/timer/rockchip_timer.c | 105 ++++++++++++++++++++++++++++++
>> drivers/timer/timer-uclass.c | 6 +-
>> 14 files changed, 148 insertions(+), 55 deletions(-)
>> create mode 100644 drivers/timer/rockchip_timer.c
More information about the U-Boot