config.h 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. /*
  2. * (C) Copyright 2011
  3. * Marvell Semiconductor <www.marvell.com>
  4. * Written-by: Lei Wen <leiwen@marvell.com>
  5. *
  6. * SPDX-License-Identifier: GPL-2.0+
  7. */
  8. /*
  9. * This file should be included in board config header file.
  10. *
  11. * It supports common definitions for Armada XP platforms
  12. */
  13. #ifndef _ARMADA_XP_CONFIG_H
  14. #define _ARMADA_XP_CONFIG_H
  15. #include <asm/arch/soc.h>
  16. #define MV88F78X60 /* for the DDR training bin_hdr code */
  17. #define CONFIG_SYS_CACHELINE_SIZE 32
  18. /*
  19. * By default kwbimage.cfg from board specific folder is used
  20. * If for some board, different configuration file need to be used,
  21. * CONFIG_SYS_KWD_CONFIG should be defined in board specific header file
  22. */
  23. #ifndef CONFIG_SYS_KWD_CONFIG
  24. #define CONFIG_SYS_KWD_CONFIG $(CONFIG_BOARDDIR)/kwbimage.cfg
  25. #endif /* CONFIG_SYS_KWD_CONFIG */
  26. /* Add target to build it automatically upon "make" */
  27. #define CONFIG_BUILD_TARGET "u-boot.kwb"
  28. /* end of 16M scrubbed by training in bootrom */
  29. #define CONFIG_SYS_INIT_SP_ADDR 0x00FF0000
  30. #define CONFIG_NR_DRAM_BANKS_MAX 2
  31. #define MV_UART_CONSOLE_BASE MVEBU_UART0_BASE
  32. /*
  33. * SPI Flash configuration
  34. */
  35. #ifdef CONFIG_CMD_SF
  36. #define CONFIG_HARD_SPI 1
  37. #define CONFIG_KIRKWOOD_SPI 1
  38. #ifndef CONFIG_ENV_SPI_BUS
  39. # define CONFIG_ENV_SPI_BUS 0
  40. #endif
  41. #ifndef CONFIG_ENV_SPI_CS
  42. # define CONFIG_ENV_SPI_CS 0
  43. #endif
  44. #ifndef CONFIG_ENV_SPI_MAX_HZ
  45. # define CONFIG_ENV_SPI_MAX_HZ 50000000
  46. #endif
  47. #endif
  48. /*
  49. * Ethernet Driver configuration
  50. */
  51. #ifdef CONFIG_CMD_NET
  52. #define CONFIG_CMD_MII
  53. #define CONFIG_MII /* expose smi ove miiphy interface */
  54. #define CONFIG_MVNETA /* Enable Marvell Gbe Controller Driver */
  55. #define CONFIG_PHYLIB
  56. #define CONFIG_ENV_OVERWRITE /* ethaddr can be reprogrammed */
  57. #define CONFIG_PHY_GIGE /* GbE speed/duplex detect */
  58. #endif /* CONFIG_CMD_NET */
  59. /*
  60. * I2C related stuff
  61. */
  62. #ifdef CONFIG_CMD_I2C
  63. #ifndef CONFIG_SYS_I2C_SOFT
  64. #define CONFIG_I2C_MVTWSI
  65. #endif
  66. #define CONFIG_SYS_I2C_SLAVE 0x0
  67. #define CONFIG_SYS_I2C_SPEED 100000
  68. #endif
  69. #endif /* _ARMADA_XP_CONFIG_H */