km-powerpc.h 3.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192
  1. /*
  2. * (C) Copyright 2011
  3. * Heiko Schocher, DENX Software Engineering, hs@denx.de.
  4. *
  5. * See file CREDITS for list of people who contributed to this
  6. * project.
  7. *
  8. * This program is free software; you can redistribute it and/or
  9. * modify it under the terms of the GNU General Public License as
  10. * published by the Free Software Foundation; either version 2 of
  11. * the License, or (at your option) any later version.
  12. *
  13. * This program is distributed in the hope that it will be useful,
  14. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  15. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  16. * GNU General Public License for more details.
  17. *
  18. * You should have received a copy of the GNU General Public License
  19. * along with this program; if not, write to the Free Software
  20. * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
  21. * MA 02111-1307 USA
  22. */
  23. #ifndef __CONFIG_KEYMILE_POWERPC_H
  24. #define __CONFIG_KEYMILE_POWERPC_H
  25. #define CONFIG_BOOTCOUNT_LIMIT
  26. #define CONFIG_CMD_DTT
  27. #define CONFIG_JFFS2_CMDLINE
  28. #define CONFIG_ENV_SIZE 0x04000 /* Size of Environment */
  29. #define CONFIG_FLASH_CFI_MTD
  30. #define CONFIG_SYS_MEMTEST_START 0x00100000 /* memtest works on */
  31. #define CONFIG_SYS_MEMTEST_END 0x00f00000 /* 1 ... 15 MB in DRAM */
  32. #define CONFIG_SYS_LOAD_ADDR 0x100000 /* default load address */
  33. /******************************************************************************
  34. * (PRAM usage)
  35. * ... -------------------------------------------------------
  36. * ... |ROOTFSSIZE | PNVRAM |PHRAM |RESERVED_PRAM | END_OF_RAM
  37. * ... |<------------------- pram -------------------------->|
  38. * ... -------------------------------------------------------
  39. * @END_OF_RAM:
  40. * @CONFIG_KM_RESERVED_PRAM: reserved pram for special purpose
  41. * @CONFIG_KM_PHRAM: address for /var
  42. * @CONFIG_KM_PNVRAM: address for PNVRAM (for the application)
  43. * @CONFIG_KM_ROOTFSSIZE: address for rootfilesystem in RAM
  44. */
  45. /* size of rootfs in RAM */
  46. #define CONFIG_KM_ROOTFSSIZE 0x0
  47. /* pseudo-non volatile RAM [hex] */
  48. #define CONFIG_KM_PNVRAM 0x80000
  49. /* physical RAM MTD size [hex] */
  50. #define CONFIG_KM_PHRAM 0x100000
  51. /* resereved pram area at the end of memroy [hex] */
  52. #define CONFIG_KM_RESERVED_PRAM 0x0
  53. /* enable protected RAM */
  54. #define CONFIG_PRAM 0
  55. #define CONFIG_KM_CRAMFS_ADDR 0x800000
  56. #define CONFIG_KM_KERNEL_ADDR 0x400000 /* 3968Kbytes */
  57. #define CONFIG_KM_FDT_ADDR 0x7E0000 /* 128Kbytes */
  58. #define CONFIG_KM_DEF_ENV_CPU \
  59. "addbootcount=echo \\\\c\0" \
  60. "addmtdparts=echo \\\\c\0" \
  61. "boot=bootm ${actual_kernel_addr} - ${actual_fdt_addr}\0" \
  62. "cramfsloadfdt=" \
  63. "cramfsload ${fdt_addr_r} " \
  64. "fdt_0x${IVM_BoardId}_0x${IVM_HWKey}.dtb && " \
  65. "setenv actual_fdt_addr ${fdt_addr_r}\0" \
  66. "fdt_addr_r=" xstr(CONFIG_KM_FDT_ADDR) "\0" \
  67. "fdt_file=" \
  68. xstr(CONFIG_HOSTNAME) "/" \
  69. xstr(CONFIG_HOSTNAME) ".dtb\0" \
  70. "tftpfdt=" \
  71. "tftpboot ${fdt_addr_r} ${fdt_file} && " \
  72. "setenv actual_fdt_addr ${fdt_addr_r} \0" \
  73. "update=" \
  74. "protect off " xstr(BOOTFLASH_START) " +${filesize} && "\
  75. "erase " xstr(BOOTFLASH_START) " +${filesize} && " \
  76. "cp.b ${u-boot_addr_r} " xstr(BOOTFLASH_START) \
  77. " ${filesize} && " \
  78. "protect on " xstr(BOOTFLASH_START) " +${filesize}\0" \
  79. ""
  80. #endif /* __CONFIG_KEYMILE_POWERPC_H */