Kconfig 8.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263
  1. menu "SPI Flash Support"
  2. config DM_SPI_FLASH
  3. bool "Enable Driver Model for SPI flash"
  4. depends on DM && DM_SPI
  5. imply SPI_FLASH
  6. help
  7. Enable driver model for SPI flash. This SPI flash interface
  8. (spi_flash_probe(), spi_flash_write(), etc.) is then
  9. implemented by the SPI flash uclass. There is one standard
  10. SPI flash driver which knows how to probe most chips
  11. supported by U-Boot. The uclass interface is defined in
  12. include/spi_flash.h, but is currently fully compatible
  13. with the old interface to avoid confusion and duplication
  14. during the transition parent. SPI and SPI flash must be
  15. enabled together (it is not possible to use driver model
  16. for one and not the other).
  17. config SPI_FLASH_SANDBOX
  18. bool "Support sandbox SPI flash device"
  19. depends on SANDBOX && DM_SPI_FLASH
  20. help
  21. Since sandbox cannot access real devices, an emulation mechanism is
  22. provided instead. Drivers can be connected up to the sandbox SPI
  23. bus (see CONFIG_SANDBOX_SPI) and SPI traffic will be routed to this
  24. device. Typically the contents of the emulated SPI flash device is
  25. stored in a file on the host filesystem.
  26. config SPI_FLASH
  27. bool "SPI Flash Core Interface support"
  28. select SPI_MEM
  29. help
  30. Enable the SPI flash Core support. This will include basic
  31. standard support for things like probing, read / write, and
  32. erasing through cmd_sf interface.
  33. If unsure, say N
  34. config SF_DEFAULT_BUS
  35. int "SPI Flash default bus identifier"
  36. depends on SPI_FLASH || DM_SPI_FLASH
  37. default 0
  38. help
  39. The default bus may be provided by the platform
  40. to handle the common case when only a single serial
  41. flash is present on the system.
  42. config SF_DEFAULT_CS
  43. int "SPI Flash default Chip-select"
  44. depends on SPI_FLASH || DM_SPI_FLASH
  45. default 0
  46. help
  47. The default chip select may be provided by the platform
  48. to handle the common case when only a single serial
  49. flash is present on the system.
  50. config SF_DEFAULT_MODE
  51. hex "SPI Flash default mode (see include/spi.h)"
  52. depends on SPI_FLASH || DM_SPI_FLASH
  53. default 0
  54. help
  55. The default mode may be provided by the platform
  56. to handle the common case when only a single serial
  57. flash is present on the system.
  58. Not used for boot with device tree; the SPI driver reads
  59. speed and mode from plat values computed from
  60. available node.
  61. config SF_DEFAULT_SPEED
  62. int "SPI Flash default speed in Hz"
  63. depends on SPI_FLASH || DM_SPI_FLASH
  64. default 1000000
  65. help
  66. The default speed may be provided by the platform
  67. to handle the common case when only a single serial
  68. flash is present on the system.
  69. Not used for boot with device tree; the SPI driver reads
  70. speed and mode from plat values computed from
  71. available node.
  72. if SPI_FLASH
  73. config SPI_FLASH_SFDP_SUPPORT
  74. bool "SFDP table parsing support for SPI NOR flashes"
  75. depends on !SPI_FLASH_BAR
  76. help
  77. Enable support for parsing and auto discovery of parameters for
  78. SPI NOR flashes using Serial Flash Discoverable Parameters (SFDP)
  79. tables as per JESD216 standard.
  80. config SPI_FLASH_SMART_HWCAPS
  81. bool "Smart hardware capability detection based on SPI MEM supports_op() hook"
  82. default y
  83. help
  84. Enable support for smart hardware capability detection based on SPI
  85. MEM supports_op() hook that lets controllers express whether they
  86. can support a type of operation in a much more refined way compared
  87. to using flags like SPI_RX_DUAL, SPI_TX_QUAD, etc.
  88. config SPI_FLASH_SOFT_RESET
  89. bool "Software Reset support for SPI NOR flashes"
  90. help
  91. Enable support for xSPI Software Reset. It will be used to switch from
  92. Octal DTR mode to legacy mode on shutdown and boot (if enabled).
  93. config SPI_FLASH_SOFT_RESET_ON_BOOT
  94. bool "Perform a Software Reset on boot on flashes that boot in stateful mode"
  95. depends on SPI_FLASH_SOFT_RESET
  96. help
  97. Perform a Software Reset on boot to allow detecting flashes that are
  98. handed to us in Octal DTR mode. Do not enable this config on flashes
  99. that are not supposed to be handed to U-Boot in Octal DTR mode, even
  100. if they _do_ support the Soft Reset sequence.
  101. config SPI_FLASH_BAR
  102. bool "SPI flash Bank/Extended address register support"
  103. help
  104. Enable the SPI flash Bank/Extended address register support.
  105. Bank/Extended address registers are used to access the flash
  106. which has size > 16MiB in 3-byte addressing.
  107. config SPI_FLASH_UNLOCK_ALL
  108. bool "Unlock the entire SPI flash on u-boot startup"
  109. default y
  110. help
  111. Some flashes tend to power up with the software write protection
  112. bits set. If this option is set, the whole flash will be unlocked.
  113. For legacy reasons, this option default to y. But if you intend to
  114. actually use the software protection bits you should say n here.
  115. config SF_DUAL_FLASH
  116. bool "SPI DUAL flash memory support"
  117. help
  118. Enable this option to support two flash memories connected to a single
  119. controller. Currently Xilinx Zynq qspi supports this.
  120. config SPI_FLASH_ATMEL
  121. bool "Atmel SPI flash support"
  122. help
  123. Add support for various Atmel SPI flash chips (AT45xxx and AT25xxx)
  124. config SPI_FLASH_EON
  125. bool "EON SPI flash support"
  126. help
  127. Add support for various EON SPI flash chips (EN25xxx)
  128. config SPI_FLASH_GIGADEVICE
  129. bool "GigaDevice SPI flash support"
  130. help
  131. Add support for various GigaDevice SPI flash chips (GD25xxx)
  132. config SPI_FLASH_ISSI
  133. bool "ISSI SPI flash support"
  134. help
  135. Add support for various ISSI SPI flash chips (ISxxx)
  136. config SPI_FLASH_MACRONIX
  137. bool "Macronix SPI flash support"
  138. help
  139. Add support for various Macronix SPI flash chips (MX25Lxxx)
  140. config SPI_FLASH_SPANSION
  141. bool "Spansion SPI flash support"
  142. help
  143. Add support for various Spansion SPI flash chips (S25FLxxx)
  144. config SPI_FLASH_S28HS512T
  145. bool "Cypress S28HS512T chip support"
  146. depends on SPI_FLASH_SPANSION
  147. help
  148. Add support for the Cypress S28HS512T chip. This is a separate config
  149. because the fixup hooks for this flash add extra size overhead. Boards
  150. that don't use the flash can disable this to save space.
  151. config SPI_FLASH_STMICRO
  152. bool "STMicro SPI flash support"
  153. help
  154. Add support for various STMicro SPI flash chips (M25Pxxx and N25Qxxx)
  155. config SPI_FLASH_MT35XU
  156. bool "Micron MT35XU chip support"
  157. depends on SPI_FLASH_STMICRO
  158. help
  159. Add support for the Micron MT35XU chip. This is a separate config
  160. because the fixup hooks for this flash add extra size overhead. Boards
  161. that don't use the flash can disable this to save space.
  162. config SPI_FLASH_SST
  163. bool "SST SPI flash support"
  164. help
  165. Add support for various SST SPI flash chips (SST25xxx)
  166. config SPI_FLASH_WINBOND
  167. bool "Winbond SPI flash support"
  168. help
  169. Add support for various Winbond SPI flash chips (W25xxx)
  170. config SPI_FLASH_XMC
  171. bool "XMC SPI flash support"
  172. help
  173. Add support for various XMC (Wuhan Xinxin Semiconductor
  174. Manufacturing Corp.) SPI flash chips (XM25xxx)
  175. config SPI_FLASH_XTX
  176. bool "XTX SPI flash support"
  177. help
  178. Add support for various XTX (XTX Technology Limited)
  179. SPI flash chips (XT25xxx).
  180. endif
  181. config SPI_FLASH_USE_4K_SECTORS
  182. bool "Use small 4096 B erase sectors"
  183. depends on SPI_FLASH
  184. default y
  185. help
  186. Many flash memories support erasing small (4096 B) sectors. Depending
  187. on the usage this feature may provide performance gain in comparison
  188. to erasing whole blocks (32/64 KiB).
  189. Changing a small part of the flash's contents is usually faster with
  190. small sectors. On the other hand erasing should be faster when using
  191. 64 KiB block instead of 16 × 4 KiB sectors.
  192. Please note that some tools/drivers/filesystems may not work with
  193. 4096 B erase size (e.g. UBIFS requires 15 KiB as a minimum).
  194. config SPI_FLASH_DATAFLASH
  195. bool "AT45xxx DataFlash support"
  196. depends on SPI_FLASH && DM_SPI_FLASH
  197. help
  198. Enable the access for SPI-flash-based AT45xxx DataFlash chips.
  199. DataFlash is a kind of SPI flash. Most AT45 chips have two buffers
  200. in each chip, which may be used for double buffered I/O; but this
  201. driver doesn't (yet) use these for any kind of i/o overlap or prefetching.
  202. Sometimes DataFlash is packaged in MMC-format cards, although the
  203. MMC stack can't (yet?) distinguish between MMC and DataFlash
  204. protocols during enumeration.
  205. If unsure, say N
  206. config SPI_FLASH_MTD
  207. bool "SPI Flash MTD support"
  208. depends on SPI_FLASH && MTD
  209. help
  210. Enable the MTD support for spi flash layer, this adapter is for
  211. translating mtd_read/mtd_write commands into spi_flash_read/write
  212. commands. It is not intended to use it within sf_cmd or the SPI
  213. flash subsystem. Such an adapter is needed for subsystems like
  214. UBI which can only operate on top of the MTD layer.
  215. If unsure, say N
  216. config SPL_SPI_FLASH_MTD
  217. bool "SPI flash MTD support for SPL"
  218. depends on SPI_FLASH
  219. help
  220. Enable the MTD support for the SPI flash layer in SPL.
  221. If unsure, say N
  222. endmenu # menu "SPI Flash Support"