MPC8308:DDR2 memory space overlapped

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

MPC8308:DDR2 memory space overlapped

989 次查看
gengdongwan
Contributor I

Hi:
I meet a problem about the memory access when I do some develop job on my own board based on mpc8308.
Below is the detail description.

Hardware Environment:
    CPU:MPC8308
    DDR2:MT47H64M16HR(2 chips,256MBytes in total)
Note:The schematic will shows you that the connection between CPU and DDR2_Memory Device.

DDR2 initialize sequence as follows(Configure the registers associate with the DDR2 Memory Controller):

# DDR2 local access window 0 attribute regster (DDRLAWAR0)

lis  r5, 0x8000
ori  r5, r5, 0x001b
lis  r4, 0xe00000a4@ha
stw  r5, 0xe00000a4@l(r4)

#Chip Select Bounds Registers (CS0_BNDS)
lis  r5, 0x0000
ori  r5, r5, 0x000f
lis  r4, 0xe0002000@ha
stw  r5, 0xe0002000@l(r4)

After congiguring the DDR2 Memory controller as above,I found a strange problem when I do some memory access operations,the lower 128MB space is overlapped with the upper 128MB space,such as:

int * p = (int *)0x01000000;
      *p = 0x12345678;

after the operation above,I found the space 0x01000000 & 0x09000000 were filled with the same value(0x12345678).

(I guess becuz some steps of the configuration were wrong and it caused the MSB(bit27) of the address line of DDR2 doesn't work)

what causes this and why?please help me?

Thanks very much!

标签 (1)
标记 (2)
0 项奖励
回复
1 回复

741 次查看
marius_grigoras
NXP Employee
NXP Employee

Hi,

At first sight your DDR initialization is not complete -- it's mandatory to set up and the rest DDR registers (for timings, SDRAM modes and so on). Please find attached 2 files (for 8308SOM and 8308_mITX boards) where you can find some full DDR inits. Please note that these files are for some ROM applications - you can ignore the rest init parts for eLBC modules and so on.

Regards,

Marius

0 项奖励
回复