mx53ppd.h 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148
  1. /* SPDX-License-Identifier: GPL-2.0+ */
  2. /*
  3. * Copyright (C) 2011 Freescale Semiconductor, Inc.
  4. * Jason Liu <r64343@freescale.com>
  5. *
  6. * Configuration settings for Freescale MX53 low cost board.
  7. */
  8. #ifndef __CONFIG_H
  9. #define __CONFIG_H
  10. #include <asm/arch/imx-regs.h>
  11. #define CONFIG_CMDLINE_TAG
  12. #define CONFIG_SETUP_MEMORY_TAGS
  13. #define CONFIG_INITRD_TAG
  14. #define CONFIG_SYS_FSL_CLK
  15. /* Size of malloc() pool */
  16. #define CONFIG_SYS_MALLOC_LEN (10 * 1024 * 1024)
  17. #define CONFIG_REVISION_TAG
  18. /* USB Configs */
  19. #define CONFIG_USB_HOST_ETHER
  20. #define CONFIG_USB_ETHER_ASIX
  21. #define CONFIG_USB_ETHER_MCS7830
  22. #define CONFIG_USB_ETHER_SMSC95XX
  23. #define CONFIG_MXC_USB_PORT 1
  24. #define CONFIG_MXC_USB_PORTSC (PORT_PTS_UTMI | PORT_PTS_PTW)
  25. #define CONFIG_MXC_USB_FLAGS 0
  26. /* Command definition */
  27. #define CONFIG_LOADADDR 0x72000000 /* loadaddr env var */
  28. #define PPD_CONFIG_NFS \
  29. "nfsserver=192.168.252.95\0" \
  30. "gatewayip=192.168.252.95\0" \
  31. "netmask=255.255.255.0\0" \
  32. "ipaddr=192.168.252.99\0" \
  33. "kernsize=0x2000\0" \
  34. "use_dhcp=0\0" \
  35. "nfsroot=/opt/springdale/rd\0" \
  36. "bootargs_nfs=setenv bootargs ${bootargs} root=/dev/nfs " \
  37. "${kern_ipconf} nfsroot=${nfsserver}:${nfsroot},v3,tcp rw\0" \
  38. "choose_ip=if test $use_dhcp = 1; then setenv kern_ipconf ip=dhcp; " \
  39. "setenv getcmd dhcp; else setenv kern_ipconf " \
  40. "ip=${ipaddr}:${nfsserver}:${gatewayip}:${netmask}::eth0:off; " \
  41. "setenv getcmd tftp; fi\0" \
  42. "nfs=run choose_ip setargs bootargs_nfs; ${getcmd} ${loadaddr} " \
  43. "${nfsserver}:${image}; bootm ${loadaddr}\0" \
  44. #define CONFIG_EXTRA_ENV_SETTINGS \
  45. PPD_CONFIG_NFS \
  46. "image=/boot/fitImage\0" \
  47. "dev=mmc\0" \
  48. "devnum=2\0" \
  49. "rootdev=mmcblk0p\0" \
  50. "quiet=quiet loglevel=0\0" \
  51. "lvds=ldb\0" \
  52. "setargs=setenv bootargs ${lvds} jtag=on mem=2G " \
  53. "vt.global_cursor_default=0 bootcause=${bootcause} ${quiet}\0" \
  54. "bootargs_emmc=setenv bootargs root=/dev/${rootdev}${partnum} ro " \
  55. "rootwait ${bootargs}\0" \
  56. "doquiet=if ext2load ${dev} ${devnum}:5 0x7000A000 /boot/console; " \
  57. "then setenv quiet; fi\0" \
  58. "hasfirstboot=" \
  59. "test -e ${dev} ${devnum}:${partnum} /boot/bootcause/firstboot\0" \
  60. "swappartitions=setexpr partnum 3 - ${partnum}\0" \
  61. "failbootcmd=" \
  62. "cls; " \
  63. "setcurs 5 4; " \
  64. "lcdputs \"Monitor failed to start. " \
  65. "Try again, or contact GE Service for support.\"; " \
  66. "bootcount reset; \0" \
  67. "altbootcmd=" \
  68. "run doquiet; " \
  69. "setenv partnum 1; run hasfirstboot || setenv partnum 2; " \
  70. "run hasfirstboot || setenv partnum 0; " \
  71. "if test ${partnum} != 0; then " \
  72. "setenv bootcause REVERT; " \
  73. "run swappartitions loadimage doboot; " \
  74. "fi; " \
  75. "run failbootcmd\0" \
  76. "loadimage=" \
  77. "ext2load ${dev} ${devnum}:${partnum} ${loadaddr} ${image}\0" \
  78. "doboot=" \
  79. "echo Booting from ${dev}:${devnum}:${partnum} ...; " \
  80. "run setargs; " \
  81. "run bootargs_emmc; " \
  82. "bootm ${loadaddr}\0" \
  83. "tryboot=" \
  84. "setenv partnum 1; run hasfirstboot || setenv partnum 2; " \
  85. "run loadimage || run swappartitions && run loadimage || " \
  86. "setenv partnum 0 && echo MISSING IMAGE;" \
  87. "run doboot; " \
  88. "run failbootcmd\0" \
  89. "video-mode=" \
  90. "lcd:800x480-24@60,monitor=lcd\0" \
  91. #define CONFIG_MMCBOOTCOMMAND \
  92. "if mmc dev ${devnum}; then " \
  93. "run doquiet; " \
  94. "run tryboot; " \
  95. "fi; " \
  96. #define CONFIG_BOOTCOMMAND CONFIG_MMCBOOTCOMMAND
  97. #define CONFIG_ARP_TIMEOUT 200UL
  98. /* Miscellaneous configurable options */
  99. #define CONFIG_SYS_CBSIZE 1024 /* Console I/O Buffer Size */
  100. #define CONFIG_SYS_MAXARGS 48 /* max number of command args */
  101. #define CONFIG_SYS_BARGSIZE CONFIG_SYS_CBSIZE /* Boot Argument Buffer Size */
  102. #define CONFIG_SYS_LOAD_ADDR CONFIG_LOADADDR
  103. #define CONFIG_SYS_BOOTMAPSZ (256 << 20) /* 256M */
  104. /* Physical Memory Map */
  105. #define PHYS_SDRAM_1 CSD0_BASE_ADDR
  106. #define PHYS_SDRAM_1_SIZE (gd->bd->bi_dram[0].size)
  107. #define PHYS_SDRAM_2 CSD1_BASE_ADDR
  108. #define PHYS_SDRAM_2_SIZE (gd->bd->bi_dram[1].size)
  109. #define PHYS_SDRAM_SIZE (gd->ram_size)
  110. #define CONFIG_SYS_SDRAM_BASE (PHYS_SDRAM_1)
  111. #define CONFIG_SYS_INIT_RAM_ADDR (IRAM_BASE_ADDR)
  112. #define CONFIG_SYS_INIT_RAM_SIZE (IRAM_SIZE)
  113. #define CONFIG_SYS_INIT_SP_OFFSET \
  114. (CONFIG_SYS_INIT_RAM_SIZE - GENERATED_GBL_DATA_SIZE)
  115. #define CONFIG_SYS_INIT_SP_ADDR \
  116. (CONFIG_SYS_INIT_RAM_ADDR + CONFIG_SYS_INIT_SP_OFFSET)
  117. /* FLASH and environment organization */
  118. #define CONFIG_FSL_IIM
  119. /* Backlight Control */
  120. #define CONFIG_IMX6_PWM_PER_CLK 66666000
  121. #define CONFIG_IMX_VIDEO_SKIP
  122. #endif /* __CONFIG_H */