]> git.kernelconcepts.de Git - karo-tx-uboot.git/commitdiff
* Patch by Josef Baumgartner, 25 May 2004:
authorwdenk <wdenk>
Wed, 9 Jun 2004 15:24:18 +0000 (15:24 +0000)
committerwdenk <wdenk>
Wed, 9 Jun 2004 15:24:18 +0000 (15:24 +0000)
  Add missing functions get_ticks() and get_tbclk() in lib_m68k/time.c

* Patch by Paul Ruhland, 24 May 2004:
  fix SDRAM initialization for LPD7A400 board.

CHANGELOG
board/lpd7a40x/memsetup.S
lib_m68k/time.c

index 8dcf6bed996f1011af18ff44f2be503f9e175611..7922cdefb08e4f7c929de45b65837e8d838b4371 100644 (file)
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -2,6 +2,12 @@
 Changes since U-Boot 1.1.1:
 ======================================================================
 
+* Patch by Josef Baumgartner, 25 May 2004:
+  Add missing functions get_ticks() and get_tbclk() in lib_m68k/time.c
+
+* Patch by Paul Ruhland, 24 May 2004:
+  fix SDRAM initialization for LPD7A400 board.
+
 * Patch by Jian Zhang, 20 May 2004:
   add support for environment in NAND flash
 
index 09ab5e74c6e573c8ed9e79fa5d1a768267e621b6..d4e6c6a0e1db4c7e4e7d101d1a387492be66c75f 100644 (file)
 /*
  * The SDRAM DEVICE MODE PROGRAMMING VALUE
  */
-#define BURST_LENGTH_4         (0x010 << 10)
-#define BURST_LENGTH_8         (0x011 << 10)
-#define WBURST_LENGTH_BL       (0x01 << 19)
-#define WBURST_LENGTH_SINGLE   (0x01 << 19)
-#define CAS_2                  (0x010 << 14)
-#define CAS_3                  (0x011 << 14)
+#define BURST_LENGTH_4         (2 << 10)
+#define BURST_LENGTH_8         (3 << 10)
+#define WBURST_LENGTH_BL       (0 << 19)
+#define WBURST_LENGTH_SINGLE   (1 << 19)
+#define CAS_2                  (2 << 14)
+#define CAS_3                  (3 << 14)
 #define BAT_SEQUENTIAL         (0 << 13)
 #define BAT_INTERLEAVED                (1 << 13)
-#define OPM_NORMAL             (0x00 << 17)
+#define OPM_NORMAL             (0 << 17)
 #define SDRAM_DEVICE_MODE      (WBURST_LENGTH_BL|OPM_NORMAL|CAS_3|BAT_SEQUENTIAL|BURST_LENGTH_4)
 
 
index 0b85411dd87b4edf9af0a219af3c6d5327387bed..6f73ba9c2b02f679b1d6c7cc1ff18a72504e7769 100644 (file)
@@ -171,3 +171,24 @@ void wait_ticks (unsigned long ticks)
        while (get_timer (0) < ticks);
 }
 #endif
+
+
+/*
+ * This function is derived from PowerPC code (read timebase as long long).
+ * On M68K it just returns the timer value.
+ */
+unsigned long long get_ticks(void)
+{
+       return get_timer(0);
+}
+
+/*
+ * This function is derived from PowerPC code (timebase clock frequency).
+ * On M68K it returns the number of timer ticks per second.
+ */
+ulong get_tbclk (void)
+{
+       ulong tbclk;
+       tbclk = CFG_HZ;
+       return tbclk;
+}