主题 : uboot中bank0~bank7内存控制器的设置问题 复制链接 | 浏览器收藏 | 打印
级别: 新手上路
UID: 3333
精华: 0
发帖: 26
金钱: 170 两
威望: 78 点
综合积分: 52 分
注册时间: 2009-01-05
最后登录: 2010-10-27
楼主  发表于: 2009-10-09 19:04

 uboot中bank0~bank7内存控制器的设置问题

小弟我在看uboot源码时,看到其中关于内存控制器的相关设置,如下:
#define DW8                 (0x0)
#define DW16             (0x1)
#define DW32             (0x2)
#define WAIT             (0x1<<2)
#define UBLB             (0x1<<3)

#define B1_BWSCON          (DW16)
#define B2_BWSCON          (DW16)
#define B3_BWSCON          (DW16 + WAIT + UBLB)
#define B4_BWSCON          (DW16)
#define B5_BWSCON          (DW16)
#define B6_BWSCON          (DW32)
#define B7_BWSCON          (DW32)

/* BANK0CON */
#define B0_Tacs             0x0    /*  0clk */
#define B0_Tcos             0x0    /*  0clk */
#define B0_Tacc             0x7    /* 14clk */
#define B0_Tcoh             0x0    /*  0clk */
#define B0_Tah             0x0    /*  0clk */
#define B0_Tacp             0x0
#define B0_PMC             0x0    /* normal */

/* BANK1CON */
#define B1_Tacs             0x0    /*  0clk */
#define B1_Tcos             0x0    /*  0clk */
#define B1_Tacc             0x7    /* 14clk */
#define B1_Tcoh             0x0    /*  0clk */
#define B1_Tah             0x0    /*  0clk */
#define B1_Tacp             0x0
#define B1_PMC             0x0

#define B2_Tacs             0x0
#define B2_Tcos             0x0
#define B2_Tacc             0x7
#define B2_Tcoh             0x0
#define B2_Tah             0x0
#define B2_Tacp             0x0
#define B2_PMC             0x0

#define B3_Tacs             0x0    /*  0clk */
#define B3_Tcos             0x3    /*  4clk */
#define B3_Tacc             0x7    /* 14clk */
#define B3_Tcoh             0x1    /*  1clk */
#define B3_Tah             0x0    /*  0clk */
#define B3_Tacp             0x3 /*  6clk */
#define B3_PMC             0x0    /* normal */

#define B4_Tacs             0x0    /*  0clk */
#define B4_Tcos             0x0    /*  0clk */
#define B4_Tacc             0x7    /* 14clk */
#define B4_Tcoh             0x0    /*  0clk */
#define B4_Tah             0x0    /*  0clk */
#define B4_Tacp             0x0
#define B4_PMC             0x0    /* normal */

#define B5_Tacs             0x0    /*  0clk */
#define B5_Tcos             0x0    /*  0clk */
#define B5_Tacc             0x7    /* 14clk */
#define B5_Tcoh             0x0    /*  0clk */
#define B5_Tah             0x0    /*  0clk */
#define B5_Tacp             0x0
#define B5_PMC             0x0    /* normal */

#define B6_MT             0x3    /* SDRAM */
#define B6_Trcd              0x1
#define B6_SCAN             0x1    /* 9bit */

#define B7_MT             0x3    /* SDRAM */
#define B7_Trcd             0x1    /* 3clk */
#define B7_SCAN             0x1    /* 9bit */

哪位能否解释一下,这些值是如何得来的?仅仅根据vivi来改吗?我不太懂