lowlevel_init.S 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. /*
  2. * Memory sub-system initialization code for TANBAC Evaluation board TB0229.
  3. *
  4. * Copyright (c) 2003 Masami Komiya <mkomiya@sonare.it>
  5. *
  6. * This program is free software; you can redistribute it and/or
  7. * modify it under the terms of the GNU General Public License as
  8. * published by the Free Software Foundation; either version 2, or (at
  9. * your option) any later version.
  10. */
  11. #include <config.h>
  12. #include <version.h>
  13. #include <asm/regdef.h>
  14. .globl lowlevel_init
  15. lowlevel_init:
  16. /* BCUCNTREG1 = 0x0040 */
  17. la t0, 0xaf000000
  18. li t1, 0x0040
  19. sh t1, 0(t0)
  20. /* ROMSIZEREG = 0x3333 */
  21. la t0, 0xaf000004
  22. li t1, 0x3333
  23. sh t1, 0(t0)
  24. /* ROMSPEEDREG = 0x3003 */
  25. la t0, 0xaf000006
  26. li t1, 0x3003
  27. sh t1, 0(t0)
  28. /* BCUCNTREG3 = 0 */
  29. la t0, 0xaf000016
  30. li t1, 0x0000
  31. sh t1, 0(t0)
  32. /* CMUCLKMSK */
  33. la t0, 0xaf000060
  34. li t1, 0x39a2
  35. sh t1, 0(t0)
  36. /* PMUCNTREG */
  37. la t0, 0xaf0000c2
  38. li t1, 0x0006
  39. sh t1, 0(t0)
  40. /* SDRAMMODEREG = 0x8029 */
  41. la t0, 0xaf000400
  42. li t1, 0x8029
  43. sh t1, 0(t0)
  44. /* SDRAMCNTREG = 0x2322 */
  45. la t0, 0xaf000402
  46. li t1, 0x2322
  47. sh t1, 0(t0)
  48. /* BCURFCNTREG = 0x0106 */
  49. la t0, 0xaf000404
  50. li t1, 0x0106
  51. sh t1, 0(t0)
  52. /* RAMSZEREG = 0x5555 (64MB Bank) */
  53. la t0, 0xaf000408
  54. li t1, 0x5555
  55. sh t1, 0(t0)
  56. j ra
  57. nop