sdctrl.inc
上传用户:caisangzi8
上传日期:2013-10-25
资源大小:15756k
文件大小:18k
源码类别:

DVD

开发平台:

C/C++

  1. //
  2. // FILE
  3. // sdctrl.inc
  4. // 
  5. // DESCRIPTION
  6. // SDRAM related 
  7. //
  8. #include "regdef.h"
  9. #include "gpio.h"
  10. #include "config.h"
  11. #include "regmapa.h"
  12. #include "user_init.h"
  13. //#define PROBE_SDRAM
  14. /*
  15. ** SDRAM interface setup
  16. */
  17. #include "sdctrl.h"
  18. //#define SPCA728_720_TIMING
  19. #ifdef  SDRAM_BUS_32BITS
  20. #define SDRAM_USE_K4S161622
  21. #else
  22. #define SDRAM_USE_K4S641632
  23. #endif
  24. //#define SDRAM_USE_720
  25. //#define SDRAM_USE_MAX
  26. // 16MB
  27. #ifdef  SDRAM_USE_K4S161622     // K4S161622D-TC/L60 CL=3
  28. #define nRAS    7               // tRAS
  29. #define nRC     10              // tRC
  30. #define nMRD    2               // 
  31. #define nRFC    10              // use tRC
  32. #define nRCD    3               // tRCD
  33. #define nRP     3               // tRP
  34. #define nRRD    2               // tRRD
  35. #define nWR     2               // tRDL
  36. #define nCL     3               // CAS latency
  37. #endif
  38. // SLOWER
  39. #ifdef  SDRAM_USE_SLOWER        // slower
  40. #define nRAS    8               // tRAS
  41. #define nRC     11              // tRC
  42. #define nMRD    2               //
  43. #define nRFC    11              // (tRC)
  44. #define nRCD    4               // tRCD
  45. #define nRP     3               // tRP
  46. #define nRRD    2               // tRRD
  47. #define nWR     2               // tRDL
  48. #define nCL     3               // CAS latency
  49. #endif
  50. #ifdef  SDRAM_USE_K4S641632     // K4S641632F-75 CL=3
  51. #define FSYS    1215            // in 0.1MHz
  52. #define TRAS    450             // in 0.1ns scale
  53. #define TRCD    200             // in 0.1ns scale
  54. #define TRC     650             // in 0.1ns scale
  55. #define TRP     200             // in 0.1ns scale
  56. #define TCYC    (100000/FSYS)   // in 0.1ns
  57. // cal
  58. #define nRASv   (TRAS+TCYC-1)/TCYC
  59. #define nRCDv   (TRCD+TCYC-1)/TCYC
  60. #define nRCv    (TRC+TCYC-1)/TCYC
  61. #define nRPv    (TRP+TCYC-1)/TCYC
  62. // setup
  63. #define nRAS    nRASv 
  64. #define nRC     nRCv
  65. #define nMRD    2   
  66. #define nRFC    nRC
  67. #define nRCD    nRCDv           // 2    2
  68. #define nRP     nRPv            // 2    2
  69. #define nRRD    2               // 1    2       
  70. #define nWR     2               // 2    2
  71. #define nCL     3               // 2    3
  72. #endif
  73. // spca720 style
  74. #ifdef  SDRAM_USE_720
  75. // this table is in unit of cycle, actual writing value will be (n-1)
  76. //                              // 720  DEF
  77. #define nRAS    4               // 4    5
  78. #define nRC     5               // 5    7
  79. #define nMRD    2               // 2    2
  80. #define nRFC    5               // 5    7
  81. #define nRCD    2               // 2    2
  82. #define nRP     2               // 2    2
  83. #define nRRD    1               // 1    2
  84. #define nWR     2               // 2    2
  85. #define nCL     2               // 2    3
  86. #endif
  87. // around 148
  88. #if 0
  89. // this table is in unit of cycle, actual writing value will be (n-1)
  90. //                              // 720  DEF
  91. #define nRAS    7               // 4    5
  92. #define nRC     8               // 5    7
  93. #define nMRD    2               // 2    2
  94. #define nRFC    8               // 5    7
  95. #define nRCD    2               // 2    2
  96. #define nRP     2               // 2    2
  97. #define nRRD    2               // 1    2
  98. #define nWR     2               // 2    2
  99. #define nCL     3               // 2    3
  100. #endif
  101. // maximum
  102. #ifdef  SDRAM_USE_MAX
  103. // this table is in unit of cycle, actual writing value will be (n-1)
  104. //                              // 720  DEF MAX
  105. #define nRAS    8               // 4    5   8
  106. #define nRC     9               // 5    7   10
  107. #define nMRD    2               // 2    2   2
  108. #define nRFC    9               // 5    7   10
  109. #define nRCD    4               // 2    2   4
  110. #define nRP     2               // 2    2   2
  111. #define nRRD    2               // 1    2   2
  112. #define nWR     2               // 2    2   2
  113. #define nCL     3               // 2    3   3
  114. #endif
  115. // check SDRAM timing limit
  116. #if nRAS>8
  117. #error SDRAM timing nRAS<=8
  118. #endif
  119. #if nRCD>4
  120. #error SDRAM timing nRCD<=4
  121. #endif
  122. // CFG0 (default 0x023c)
  123. #define SDCTRL_CFG0_VAL_0       SDCTRL_CFG0_RAS(nRAS)           
  124.                                 | SDCTRL_CFG0_RC(nRC)           
  125.                                 | SDCTRL_CFG0_MRD(nMRD)
  126. #define SDCTRL_CFG0_VAL_SET     SDCTRL_CFG0_VAL_0
  127. // CFG1 (default 0x59A7)
  128. #define SDCTRL_CFG1_VAL_0       SDCTRL_CFG1_RFC(nRFC)           
  129.                                 | SDCTRL_CFG1_RCD(nRCD)         
  130.                                 | SDCTRL_CFG1_RP(nRP)           
  131.                                 | SDCTRL_CFG1_RRD(nRRD)         
  132.                                 | SDCTRL_CFG1_WR(nWR) 
  133. #define SDCTRL_CFG1_VAL_1       SDCTRL_CFG1_CL(nCL)
  134. #define SDCTRL_CFG1_VAL_SET     SDCTRL_CFG1_VAL_0 | SDCTRL_CFG1_VAL_1
  135. // CFG2 (default 0x0037)
  136. #define SDCTRL_CFG2_VAL_0       SDCTRL_CFG2_BL_8                
  137.                                 | SDCTRL_CFG2_BT_SEQUENTIAL     
  138.                                 | SDCTRL_CFG2_OP_NORMAL         
  139.                                 | SDCTRL_CFG2_BE_PROGRAMMED
  140. #if (nCL==2)
  141. #define SDCTRL_CFG2_VAL_1       SDCTRL_CFG2_CL_2
  142. #else
  143. #define SDCTRL_CFG2_VAL_1       SDCTRL_CFG2_CL_3
  144. #endif
  145. #define SDCTRL_CFG2_VAL_SET     SDCTRL_CFG2_VAL_0 | SDCTRL_CFG2_VAL_1
  146. // CFG3
  147. #define SDCTRL_CFG3_VAL_0       (SDCTRL_CFG3_CKE_EN | SDCTRL_CFG3_PRERAS_EN | SDCTRL_CFG3_BURST_8)
  148. #ifdef    SDRAM_BUS_32BITS
  149. #define SDCTRL_CFG3_VAL_1       SDCTRL_CFG3_INF_32B
  150. #else
  151. #define SDCTRL_CFG3_VAL_1       SDCTRL_CFG3_INF_16B
  152. #endif
  153. #define SDCTRL_CFG3_VAL_DEF     (SDCTRL_CFG3_VAL_0 | SDCTRL_CFG3_VAL_1)                // when using probing
  154. #ifdef SDRAM_1PCS
  155. #define SDCTRL_CFG3_VAL_2       (SDCTRL_CFG3_1PS)
  156. #else
  157. #define SDCTRL_CFG3_VAL_2       (SDCTRL_CFG3_2PS)
  158. #endif
  159. #define SDCTRL_CFG3_VAL_SET     (SDCTRL_CFG3_VAL_0 | SDCTRL_CFG3_VAL_1 | SDCTRL_CFG3_VAL_2)
  160. // CFG4
  161. #define SDCTRL_CFG4_VAL_16M     (SDCTRL_CFG4_CW(7) | SDCTRL_CFG4_RW(10) | SDCTRL_CFG4_PALL(10) | SDCTRL_CFG4_BANK4(0))
  162. #define SDCTRL_CFG4_VAL_64M     (SDCTRL_CFG4_CW(7) | SDCTRL_CFG4_RW(11) | SDCTRL_CFG4_PALL(10) | SDCTRL_CFG4_BANK4(1))
  163. #define SDCTRL_CFG4_VAL_128M    (SDCTRL_CFG4_CW(8) | SDCTRL_CFG4_RW(12) | SDCTRL_CFG4_PALL(10) | SDCTRL_CFG4_BANK4(1))
  164. #define SDCTRL_CFG4_VAL_256M    (SDCTRL_CFG4_CW(8) | SDCTRL_CFG4_RW(12) | SDCTRL_CFG4_PALL(10) | SDCTRL_CFG4_BANK4(1))
  165. #define SDCTRL_CFG4_VAL_SET     SDCTRL_CFG4_VAL_16M
  166. // SREF
  167. #define SDCTRL_SREF_VAL_SET SDCTRL_SREF_SEL(1)        // 63 cycle
  168. // AREF
  169. #define SDCTRL_AREF1_VAL_SET    (SDCTRL_AREF1_ENABLE 
  170.                                 | SDCTRL_AREF1_AUTOREF 
  171.                                 | SDCTRL_AREF1_REFCNT(4) 
  172.                                 | SDCTRL_AREF1_SEL(AREF1_SEL(SDCLK,4)) )
  173. //
  174. // override previous definition CFG0/1/2 for 720 mode configuration
  175. //
  176. #ifdef SPCA728_720_TIMING
  177. #undef  SDCTRL_CFG0_VAL_SET
  178. #undef  SDCTRL_CFG1_VAL_SET
  179. #undef  SDCTRL_CFG2_VAL_SET
  180. #define SDCTRL_CFG0_VAL_SET    SDCTRL_CFG0_VAL_720
  181. #define SDCTRL_CFG1_VAL_SET    SDCTRL_CFG1_VAL_720
  182. #define SDCTRL_CFG2_VAL_SET    SDCTRL_CFG2_VAL_720
  183. #endif
  184.                 .text
  185.                 .global     set_sdram_timing
  186.                 .global     set_sdram_timing_low
  187.                 .global     setup_sdctrl
  188.                 .global     setup_sdctrl_sref
  189.                 .text
  190. //
  191. // FUNCTION
  192. // setup_sdctrl()
  193. //
  194. // Setup SDRAM controller
  195. //
  196.                 .ent    setup_sdctrl
  197. setup_sdctrl:
  198. #ifdef    FIX_SDRAM_BOOTING_PROBLEM
  199.                 li      t0, 0
  200.                 sw      t0, RF_SDC_REQ_T_RESET(s6)
  201.                 WAIT(0x400)
  202. #endif
  203.                 // configure sdram timing
  204.                 li      t0, SDCTRL_CFG0_VAL_SET
  205.                 li      t1, SDCTRL_CFG1_VAL_SET
  206.                 li      t2, SDCTRL_CFG2_VAL_SET
  207.     
  208.                 sw      t0, RF_SDCTRL_CFG0(s6)
  209.                 sw      t1, RF_SDCTRL_CFG1(s6)
  210.                 sw      t2, RF_SDCTRL_CFG2(s6)
  211.                 li      t1, SDCTRL_SREF_VAL_SET
  212.                 sw      t1, RF_SDCTRL_SREF_CFG(s6)
  213.                 li      t1, SDCTRL_AREF1_VAL_SET
  214.                 sw      t1, RF_SDCTRL_AREF1_CFG(s6)
  215.                 // CFG3: configure sdram interface
  216.                 li      t3, SDCTRL_CFG3_VAL_SET
  217.                 sw      t3, RF_SDCTRL_CFG3(s6)
  218.                 // write sdram mrs
  219.                 WRITESTAMP(STAMP_SDRAM_MRS)
  220.                 li      t1, 1
  221.                 sw      t1, RF_SDCTRL_MRS(s6)            // write MRS
  222.                 // wait MRS
  223.                 WAIT(0x4000)
  224.                 // return
  225.                 jr      ra
  226.                 .end    setup_sdctrl
  227. //
  228. // FUNCTION
  229. // setup_sdctrl_sref()
  230. //
  231.                 .ent    setup_sdctrl_sref
  232. setup_sdctrl_sref:
  233.                 li      t1, SDCTRL_SREF_SEL(100)
  234.                 sw      t1, RF_SDCTRL_SREF_CFG(s6)
  235.                 li      t1, SDCTRL_AREF1_ENABLE|SDCTRL_AREF1_SELFREF|SDCTRL_AREF1_REFCNT(4)|SDCTRL_AREF1_SEL(200)
  236.                 sw      t1, RF_SDCTRL_AREF1_CFG(s6)
  237.                 jr      ra
  238.                 .end    setup_sdctrl_sref
  239. //
  240. // FUNCTION
  241. // set_sdram_timing
  242. //
  243.                 .ent    set_sdram_timing
  244. set_sdram_timing:
  245. #ifndef PROBE_SDRAM
  246.                 li      t3, SDCTRL_CFG4_VAL_SET
  247.                 sw      t3, RF_SDCTRL_CFG4(s6)
  248.                 jr      ra
  249. #endif
  250. #ifdef  SPHE8202
  251.                 // sphe8202
  252.                 lw      t1, RF_SFT_CFG8(s6)
  253.                 andi    t1, 0x0FFF
  254.                 ori     t1, 0x1000
  255.                 sw      t1, RF_SFT_CFG8(s6)             // ROM-SDRAM delay max.
  256.                 
  257. #ifdef  IC_8202E                                        // chyeh 2005/01/05  
  258.                 lw      t2, RF_SDCTRL_MISC_B0(s6)
  259.                 ori     t2, (1<<15)                     // Use 3-stage pipeline
  260.                 sw      t2, RF_SDCTRL_MISC_B0(s6)    
  261. #endif
  262. #if 0
  263.                 lw      t2, RF_SDCTRL_MISC_B0(s6)
  264.                 ori     t2, (1<<1)
  265.                 sw      t2, RF_SDCTRL_MISC_B0(s6)       // Force SDRAM output always
  266. #endif
  267. #else
  268.                 // sphe8200
  269. #ifdef SDRAM_BUS_32BITS
  270.                 li      t0, 0x5A;
  271.                 sw      t0, RF_PAD_CTRL(s6)             // Control pins: full-power
  272.                                                         // DQ pins: 8mA
  273. #endif
  274. #endif
  275.                 // new style timing setting                
  276.                 la      t0, CFG_sdram_config            // (t0): SDRAM config table (in init0.S)
  277. #ifdef SPHE8202                
  278.                 lw      t2, RF_STAMP(s6)
  279.                 li      t1, 0x82                        //  PS2.1 stamp:0x82 ,terry,2005/1/30 08:14PM
  280.                 bne     t2,t1,9f
  281.                 la      t0, CFG_sdram_config_PS21       // (t0): SDRAM config table (in init0.S)                
  282. 9:             
  283. #endif
  284.  
  285. #if defined(SPHE8202)||defined(SPHE1000)
  286.                 lhu     t1, 0(t0)                       // get OUT cfg
  287.                 lhu     t2, 2(t0)                       // get IN cfg
  288.                 lhu     t3, 4(t0)                       // get IN_DLY cfg
  289.                 lhu     t4, 6(t0)                       // get PADCTRL cfg
  290.                 sw      t1, RF_SDRAM_CLKO_CFG(s6)       // write OUT cfg
  291.                 sw      t2, RF_SDRAM_CLKI_CFG(s6)       // write IN cfg
  292.                 sw      t3, RF_SDRAM_CLKI_DLY_CFG(s6)   // write IN_DLY cfg
  293.                 sw      t4, RF_PAD_CTRL(s6)             // write PADCTRL cfg
  294.                 
  295. #else
  296.                 lhu     t1, 0(t0)                       // get OUT cfg
  297.                 lhu     t2, 2(t0)                       // get IN cfg
  298.                 sw      t1, RF_SDRAM_CLKO_CFG(s6)       // write OUT cfg
  299.                 sw      t2, RF_SDRAM_CLKI_CFG(s6)       // write IN cfg
  300. #endif
  301. #ifdef SDRAM_DBG //terry,2005/1/31 09:52AM
  302.                 lw      a0, RF_STAMP(s6);PUTA0
  303.                 move    a0,t0;PUTA0
  304.                 move    a0,t1;PUTA0
  305.                 move    a0,t2;PUTA0
  306.                 move    a0,t3;PUTA0
  307.                 move    a0,t4;PUTA0
  308. #endif
  309. #if 0
  310. #define     MON_SDRAM_CLK_O 5
  311. #define     MON_SDRAM_CASB  6
  312. //                li      t0, ((5<<2)|2)
  313. //                li      t0, ((1<<2)|2)          // sdram_clk_o
  314. //                li      t0, ((6<<2)|1)              // casb falling
  315.                 li      t0, ((2<<2)|2)          // sdram_clk_i
  316.                 sw      t0, RF_CLK_MON_SEL(s6)
  317.                 li      t0, 4096    
  318. 1:              addiu   t0, -1                            // wait 1024 cycles for mrs
  319.                 bnez    t0, 1b
  320.                 lw      a0, RF_CLK_MON_RESULT(s6)
  321.                 PUTA0
  322. #endif
  323.                 jr      ra
  324.                 .end    set_sdram_timing
  325. //
  326. // FUNCTION
  327. // set_sdram_timing_low()
  328. //
  329. // DESCRIPTION
  330. // System low-speed SDRAM timing setting
  331. //
  332.                 .ent    set_sdram_timing_low
  333. set_sdram_timing_low:
  334.                 li v0,(0x04<<3)|(0x00); sw v0,RF_SDRAM_CLKO_CFG(s6)
  335.                 li v0,(0x04<<3)|(0x00); sw v0,RF_SDRAM_CLKI_CFG(s6)
  336.                 li v0,(0x00); sw v0,RF_SDRAM_CLKI_DLY_CFG(s6)
  337.                 jr      ra
  338.                 .end    set_sdram_timing_low
  339. //
  340. // FUNCTION
  341. // probe_sdram_type
  342. //
  343. // DESCRIPTION
  344. // This function will probe SDRAM type from 256MB to 16MB
  345. // and set RF_SDCTRL_CFG3 register accordingly.
  346. //
  347. // *NOTE*
  348. // 1. Default value SDCTRL_CFG3_VAL_DEF will be used.
  349. // 2. Assume x16 and 2-SDRAM configuration.
  350. //
  351. #define    SDRAM_BASE_TESTED    0xA0000000
  352.                 .ent    probe_sdram_type
  353. flush_lbc_buffer:
  354.                 WRITESTAMP(STAMP_SDRAM_PROBE | 0x80)
  355.                 li      v0, 3
  356.                 sw      v0, RF_LBC_CONTROL(s6)
  357. 1:
  358.                 lw      v0, RF_LBC_CONTROL(s6)
  359.                 andi    v0, 1
  360.                 bnez    v0, 1b
  361.                 jr      ra
  362. error_sdram:
  363. #ifdef BOOTSTRAP_WRITE_UART
  364.                 PUTC('E'); PUTC('R'); PUTC('R');
  365.                 PUTCR(v0);
  366.                 PUTC(0x0d); PUTC(0x0a)
  367.                 li      v0, 0x00000000
  368.                 sw      v0, (t3)
  369.                 jal     flush_lbc_buffer
  370.                 lw      a0, (t3)
  371.                 PUTA0
  372.                 li      v0, 0xffffffff
  373.                 sw      v0, (t3)
  374.                 jal     flush_lbc_buffer
  375.                 lw      a0, (t3)
  376.                 PUTA0
  377.                 li      v0, 0x01234567
  378.                 sw      v0, (t3)
  379.                 jal     flush_lbc_buffer
  380.                 lw      a0, (t3)
  381.                 PUTA0
  382.                 li      v0, 0xabcdef01
  383.                 sw      v0, (t3)
  384.                 jal     flush_lbc_buffer
  385.                 lw      a0, (t3)
  386.                 PUTA0
  387. 1:
  388.                 li      v0, 0x01234567
  389.                 sw      v0, (t3)
  390.                 jal     flush_lbc_buffer
  391.                 b       1b
  392. #endif
  393. #ifdef ERROR_SDRAM_PROBE
  394.                 .extern test_sdram
  395.                 j       test_sdram
  396. #endif
  397.                 WRITESTAMP(STAMP_SDRAM_PROBE_ERROR)
  398. 1:
  399.                 b       1b
  400. probe_sdram_type:
  401.                 move    a3, ra
  402.                 li      t1, 0x01234567            // t1: tag #1
  403.                 li      t2, 0xfedcba98            // t2: tag #2
  404.                 la      t3, 0xA0000000            // t3: sdram startingpoint
  405.                 // default to 4-bank and max row/column
  406.                 li      t7, SDCTRL_CFG4_CW(13)|SDCTRL_CFG4_RW(13)|SDCTRL_CFG4_PALL(10)|SDCTRL_CFG4_BANK4(1)
  407.                 sw      t7, RF_SDCTRL_CFG4(s6)
  408.                 sw      zero, (t3)              // store 0 to column 0
  409.                 li      t4, 6                   // scan from 6: (col=a0~a6)
  410. #ifdef SDRAM_BUS_32BITS
  411.                 li      t6, 128*2*4             // 128 2-bank 32-bit 
  412. #else
  413.                 li      t6, 128*2*2             // 128 2-bank 16-bit
  414. #endif
  415. 1:
  416.                 addu    t7, t3, t6
  417.                 sw      t1, (t7)                // store tag#1 column +256/512/....
  418.                 jal     flush_lbc_buffer
  419.                 lw      t7, (t3)                // reload column 0
  420. #ifdef  BOOTSTRAP_WRITE_UART
  421.                 move a0, t7; PUTA0
  422. #endif
  423.                 bnez    t7, column_probed       // has been overwrittened by something
  424.                 addiu   t4, 1
  425.                 sll     t6, 1
  426.                 b       1b
  427. column_probed:
  428.                 li      v0, '0'
  429.                 bne     t7, t1, error_sdram
  430.                 WRITESTAMP(STAMP_SDRAM_PROBE | 2)
  431.                 /*
  432.                 ** PROBE ROW
  433.                 */
  434.                 // set to cw=a0~a5 (64w)
  435.                 li      t7, SDCTRL_CFG4_CW(5)|SDCTRL_CFG4_RW(15)|SDCTRL_CFG4_PALL(10)|SDCTRL_CFG4_BANK4(1)
  436.                 sw      t7, RF_SDCTRL_CFG4(s6)
  437.                 sw      zero, (t3)              // store 0 to column 0 (t3)
  438.                 li      t5, 6<<4                // row: a0~a6
  439. #ifdef SDRAM_BUS_32BITS
  440.                 li      t6, 128*64*2*4          // bank 2 column 64 width 4
  441. #else
  442.                 li      t6, 128*64*2*2          // bank 2 column 64 width 2
  443. #endif
  444. 2:
  445.                 addu    t7, t3, t6
  446.                 sw      t1, (t7)                // store row+t6
  447.                 jal     flush_lbc_buffer
  448.                 lw      t7, (t3)                // load row0
  449. #ifdef  BOOTSTRAP_WRITE_UART
  450.                 move a0, t7; PUTA0
  451. #endif
  452.                 bnez    t7, row_probed
  453.                 addiu   t5, 1<<4
  454.                 sll     t6, 1
  455.                 b       2b
  456. row_probed:
  457.                 li      v0, '1'
  458.                 bne     t7, t1, error_sdram
  459.                 or      t4, t5                    // save to t4
  460.                 WRITESTAMP(STAMP_SDRAM_PROBE | 3)
  461.                 
  462.                 /*
  463.                 ** PROBE BANK
  464.                 */
  465.                 // set to cw=a0~a5 (64w)  rw=a0~a1
  466.                 li      t7, SDCTRL_CFG4_CW(5)|SDCTRL_CFG4_RW(1)|SDCTRL_CFG4_PALL(10)|SDCTRL_CFG4_BANK4(1)
  467.                 sw      t7, RF_SDCTRL_CFG4(s6)
  468.                 sw      zero, (t3)                // store column 0
  469. #ifdef SDRAM_BUS_32BITS
  470.                 li      t6, 64*4*2*4
  471. #else
  472.                 li      t6, 64*4*2*2
  473. #endif
  474.                 addu    t7, t3, t6
  475.                 sw      t1, (t7)                // load column +256/512/....
  476.                 jal     flush_lbc_buffer
  477.                 lw      t7, (t3)                // load column 0
  478.                 bnez    t7, bank_probed
  479.                 ori     t4, SDCTRL_CFG4_BANK4(1)
  480. bank_probed:
  481.                 WRITESTAMP(STAMP_SDRAM_PROBE | 4)
  482.                 /*
  483.                 ** PROBE FINISHED
  484.                 */
  485.                 ori     t4, SDCTRL_CFG4_PALL(10)
  486.                 sw      t4, RF_SDCTRL_CFG4(s6)
  487.                 jr      a3
  488.                 .end    probe_sdram_type