]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
dm646x: pass board revision info to kernel
authorManjunath Hadli <manjunath.hadli@ti.com>
Tue, 8 Nov 2011 13:59:57 +0000 (08:59 -0500)
committerSandeep Paulraj <s-paulraj@ti.com>
Tue, 8 Nov 2011 13:59:57 +0000 (08:59 -0500)
add a function in board file to pass board revision
info to kernel. Revision number 0 and 1 are passed in
case of DM6467 and DM6467T respectively.

Signed-off-by: Manjunath Hadli <manjunath.hadli@ti.com>
Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
board/davinci/dm6467evm/dm6467evm.c
include/configs/davinci_dm6467Tevm.h
include/configs/davinci_dm6467evm.h

index 1a01c3ce2cab58bfba2bf283828274f79ab2cc71..ac82d5cf3db80d8e2ef7254d0a97e0687ca6da64 100644 (file)
 
 DECLARE_GLOBAL_DATA_PTR;
 
+#define REV_DM6467EVM          0
+#define REV_DM6467TEVM         1
+/*
+ * get_board_rev() - setup to pass kernel board revision information
+ * Returns:
+ * bit[0-3]    System clock frequency
+ * 0000b       - 27 MHz
+ * 0001b       - 33 MHz
+ */
+u32 get_board_rev(void)
+{
+
+#ifdef DAVINCI_DM6467TEVM
+       return REV_DM6467TEVM;
+#else
+       return REV_DM6467EVM;
+#endif
+
+}
+
 int board_init(void)
 {
        gd->bd->bi_arch_number = MACH_TYPE_DAVINCI_DM6467_EVM;
index c5070452c9bc05eb244ba0dc627d7c94d9561b17..f7c994eba94c8336e28ce5861a5e90123f6c38f1 100644 (file)
@@ -22,6 +22,7 @@
 
 /* Spectrum Digital TMS320DM6467T EVM board */
 #define DAVINCI_DM6467EVM
+#define DAVINCI_DM6467TEVM
 #define CONFIG_SYS_USE_NAND
 #define CONFIG_SYS_NAND_SMALLPAGE
 
@@ -64,6 +65,7 @@ extern unsigned int davinci_arm_clk_get(void);
 #define CONFIG_SETUP_MEMORY_TAGS
 #define CONFIG_SYS_BARGSIZE            1024            /* Bootarg Size */
 #define CONFIG_SYS_LOAD_ADDR           0x80700000      /* kernel address */
+#define CONFIG_REVISION_TAG
 
 /* Serial Driver info */
 #define CONFIG_SYS_NS16550
index ec1c31c0852f3cec4f1a2590c4b28ec9a7af6d01..c9a0cd1daa3234ed916fe3bcb7274a0130e45287 100644 (file)
@@ -65,6 +65,7 @@ extern unsigned int davinci_arm_clk_get(void);
 #define CONFIG_SETUP_MEMORY_TAGS
 #define CONFIG_SYS_BARGSIZE            1024            /* Bootarg Size */
 #define CONFIG_SYS_LOAD_ADDR           0x80700000      /* kernel address */
+#define CONFIG_REVISION_TAG
 
 /* Serial Driver info */
 #define CONFIG_SYS_NS16550