]> git.kernelconcepts.de Git - karo-tx-uboot.git/blob - drivers/mtd/nand/Kconfig
efd8fd58f02160d13df4288855ee36e80b3d985b
[karo-tx-uboot.git] / drivers / mtd / nand / Kconfig
1 menuconfig NAND
2         bool "NAND Device Support"
3
4 if NAND
5
6 config SYS_NAND_USE_FLASH_BBT
7         bool "Use a flash based bad block table"
8
9 config SYS_NAND_SELF_INIT
10         bool
11         help
12           This option, if enabled, provides more flexible and linux-like
13           NAND initialization process.
14
15 config NAND_DENALI
16         bool "Support Denali NAND controller"
17         select SYS_NAND_SELF_INIT
18         help
19           Enable support for the Denali NAND controller.
20
21 config SYS_NAND_DENALI_64BIT
22         bool "Use 64-bit variant of Denali NAND controller"
23         depends on NAND_DENALI
24         help
25           The Denali NAND controller IP has some variations in terms of
26           the bus interface.  The DMA setup sequence is completely differenct
27           between 32bit / 64bit AXI bus variants.
28
29           If your Denali NAND controller is the 64-bit variant, say Y.
30           Otherwise (32 bit), say N.
31
32 config NAND_DENALI_SPARE_AREA_SKIP_BYTES
33         int "Number of bytes skipped in OOB area"
34         depends on NAND_DENALI
35         range 0 63
36         help
37           This option specifies the number of bytes to skip from the beginning
38           of OOB area before last ECC sector data starts.  This is potentially
39           used to preserve the bad block marker in the OOB area.
40
41 config NAND_VF610_NFC
42         bool "Support for Freescale NFC for VF610/MPC5125"
43         select SYS_NAND_SELF_INIT
44         help
45           Enables support for NAND Flash Controller on some Freescale
46           processors like the VF610, MPC5125, MCF54418 or Kinetis K70.
47           The driver supports a maximum 2k page size. The driver
48           currently does not support hardware ECC.
49
50 choice
51         prompt "Hardware ECC strength"
52         depends on NAND_VF610_NFC
53         default SYS_NAND_VF610_NFC_45_ECC_BYTES
54         help
55           Select the ECC strength used in the hardware BCH ECC block.
56
57 config SYS_NAND_VF610_NFC_45_ECC_BYTES
58         bool "24-error correction (45 ECC bytes)"
59
60 config SYS_NAND_VF610_NFC_60_ECC_BYTES
61         bool "32-error correction (60 ECC bytes)"
62
63 endchoice
64
65 config NAND_PXA3XX
66         bool "Support for NAND on PXA3xx and Armada 370/XP/38x"
67         select SYS_NAND_SELF_INIT
68         help
69           This enables the driver for the NAND flash device found on
70           PXA3xx processors (NFCv1) and also on Armada 370/XP (NFCv2).
71
72 comment "Generic NAND options"
73
74 # Enhance depends when converting drivers to Kconfig which use this config
75 # option (mxc_nand, ndfc, omap_gpmc).
76 config SYS_NAND_BUSWIDTH_16BIT
77         bool "Use 16-bit NAND interface"
78         depends on NAND_VF610_NFC
79         help
80           Indicates that NAND device has 16-bit wide data-bus. In absence of this
81           config, bus-width of NAND device is assumed to be either 8-bit and later
82           determined by reading ONFI params.
83           Above config is useful when NAND device's bus-width information cannot
84           be determined from on-chip ONFI params, like in following scenarios:
85           - SPL boot does not support reading of ONFI parameters. This is done to
86             keep SPL code foot-print small.
87           - In current U-Boot flow using nand_init(), driver initialization
88             happens in board_nand_init() which is called before any device probe
89             (nand_scan_ident + nand_scan_tail), thus device's ONFI parameters are
90             not available while configuring controller. So a static CONFIG_NAND_xx
91             is needed to know the device's bus-width in advance.
92
93 if SPL
94
95 config SPL_NAND_DENALI
96         bool "Support Denali NAND controller for SPL"
97         help
98           This is a small implementation of the Denali NAND controller
99           for use on SPL.
100
101 config SPL_NAND_SUNXI
102         bool "Support for NAND on Allwinner A20 in SPL"
103         depends on MACH_SUN7I
104         ---help---
105         Enable support for NAND. This option allows SPL to read from
106         sunxi NAND using DMA transfers.
107         Depending on the NAND chip, values like ECC strength and page sizes
108         have to be configured.
109
110 config NAND_SUNXI_SPL_SYNDROME_PARTITIONS_END
111         hex "Size of syndrome partitions in sunxi NAND"
112         default 0x400000
113         depends on SPL_NAND_SUNXI
114         ---help---
115         End address for boot partitions on NAND. Those partitions have a
116         different random seed that has to match the sunxi BROM setting.
117
118 config NAND_SUNXI_SPL_ECC_STRENGTH
119         int "ECC Strength for sunxi NAND"
120         default 40
121         depends on SPL_NAND_SUNXI
122         ---help---
123         ECC strength used by the sunxi NAND SPL driver. This is specific to the
124         chosen NAND chip and has to match the value used by the sunxi BROM.
125
126 config NAND_SUNXI_SPL_ECC_PAGE_SIZE
127         hex "ECC page size for sunxi NAND"
128         default 0x400
129         depends on SPL_NAND_SUNXI
130         ---help---
131         ECC page size used by the sunxi NAND SPL driver for syndrome partitions.
132         This setting has to match the value used by the sunxi BROM.
133
134 config NAND_SUNXI_SPL_PAGE_SIZE
135         hex "Page size for sunxi NAND"
136         default 0x2000
137         depends on SPL_NAND_SUNXI
138         ---help---
139         Page size of the NAND flash used by the sunxi NAND SPL driver. This is
140         specific to the chosen NAND chip.
141 endif
142
143 config NAND_ATMEL
144         bool "AT91 NAND flash controller"
145         select SYS_NAND_SELF_INIT
146
147 config NAND_MXC
148         bool "Support Freescale i.MX NAND controller"
149         select SYS_NAND_SELF_INIT
150         help
151           Enable support for the Freescale NAND controller found on
152           i.MX processors.
153
154 config NAND_MXS
155         bool "Support Freescale GPMI NAND controller"
156         help
157           Enable support for the Freescale GPMI NAND controller found
158           on i.MX28 and i.MX6 processors.
159
160 config NAND_MXS_NO_BBM_SWAP
161         bool "disable bad block mark swapping"
162         depends on NAND_MXS && SOC_MX6
163         select SYS_NAND_USE_FLASH_BBT
164
165 endif