From 52a887985300cf11fbc183f6a4a4408ff9a45ec6 Mon Sep 17 00:00:00 2001 From: Vadim Bendebury Date: Wed, 5 Nov 2014 17:50:09 -0800 Subject: pistachio: implement timer support C0_COUNT register is a free running counter clocked by the CPU frequency divided by two. On the FPGA board it results in 25 MHz, on real SOCs it will have to be figured out later. Some magic addresses and numbers are used to find out if the code is running on the FPGA board. timestamp_get() and timer_monotonic_get() are kept in the same file. The CPU initialization makes sure that CO COUNT is in fact enabled and starts from zero. BRANCH=none BUG=chrome-os-partner:33595,chrome-os-partner:31438 TEST=with timer enabled, the startup code properly initializes UART and prints the coreboot bootblock banner message on the serial console. Change-Id: I98fe330b961f677448b222917ab7d586494ed4b7 Signed-off-by: Stefan Reinauer Original-Commit-Id: a7324221c1d856ac72fa2b0ab586b5ea8cab3a05 Original-Change-Id: I2d518213de939e91a35f8aea174aed76d297dd72 Original-Signed-off-by: Vadim Bendebury Original-Reviewed-on: https://chromium-review.googlesource.com/227888 Original-Reviewed-by: Aaron Durbin Reviewed-on: http://review.coreboot.org/9188 Tested-by: build bot (Jenkins) Reviewed-by: Patrick Georgi --- src/soc/imgtec/pistachio/Makefile.inc | 3 --- 1 file changed, 3 deletions(-) (limited to 'src/soc/imgtec/pistachio/Makefile.inc') diff --git a/src/soc/imgtec/pistachio/Makefile.inc b/src/soc/imgtec/pistachio/Makefile.inc index e955968ddc..f7a0848e86 100644 --- a/src/soc/imgtec/pistachio/Makefile.inc +++ b/src/soc/imgtec/pistachio/Makefile.inc @@ -31,16 +31,13 @@ ramstage-y += uart.c endif bootblock-y += monotonic_timer.c -bootblock-y += timestamp.c ramstage-y += cbmem.c ramstage-y += monotonic_timer.c -ramstage-y += timestamp.c romstage-y += cbmem.c romstage-y += romstage.c romstage-y += monotonic_timer.c -romstage-y += timestamp.c CPPFLAGS_common += -Isrc/soc/imgtec/pistachio/include/ -- cgit v1.2.3