]> git.kernelconcepts.de Git - karo-tx-uboot.git/blobdiff - board/sandbox/sandbox/sandbox.c
sandbox: Switch over to generic board
[karo-tx-uboot.git] / board / sandbox / sandbox / sandbox.c
index 95a504597577d28ebc2dccd3ec87e6d85fd39e5d..8bdba9267bccdddc01918a5bdafb389eecebae4d 100644 (file)
@@ -21,6 +21,8 @@
 
 #include <common.h>
 
+#include <os.h>
+
 /*
  * Pointer to initial global data area
  *
@@ -32,9 +34,19 @@ void flush_cache(unsigned long start, unsigned long size)
 {
 }
 
+ulong get_tbclk(void)
+{
+       return CONFIG_SYS_HZ;
+}
+
+unsigned long long get_ticks(void)
+{
+       return get_timer(0);
+}
+
 ulong get_timer(ulong base)
 {
-       return 0;
+       return (os_get_nsec() / 1000000) - base;
 }
 
 int timer_init(void)
@@ -44,6 +56,6 @@ int timer_init(void)
 
 int dram_init(void)
 {
-       gd->ram_size = CONFIG_DRAM_SIZE;
+       gd->ram_size = CONFIG_SYS_SDRAM_SIZE;
        return 0;
 }