2013-04-30 23:54:02 +02:00
|
|
|
#
|
|
|
|
# For a description of the syntax of this configuration file,
|
2015-06-28 16:14:53 +02:00
|
|
|
# see the file kconfig-language.txt in the NuttX tools repository.
|
2013-04-30 23:54:02 +02:00
|
|
|
#
|
|
|
|
|
|
|
|
config EXAMPLES_MTDPART
|
2018-09-03 17:29:56 +02:00
|
|
|
tristate "MTD partition test"
|
2013-04-30 23:54:02 +02:00
|
|
|
default n
|
2020-04-29 11:14:04 +02:00
|
|
|
depends on MTD_PARTITION && BUILD_FLAT
|
2021-03-17 00:29:14 +01:00
|
|
|
select BCH
|
2013-04-30 23:54:02 +02:00
|
|
|
---help---
|
2013-05-03 20:52:33 +02:00
|
|
|
Enable the MTD partition test example.
|
|
|
|
|
|
|
|
NOTE: This example uses some internal NuttX interfaces and, hence,
|
|
|
|
is not available in the kernel build.
|
2013-04-30 23:54:02 +02:00
|
|
|
|
|
|
|
if EXAMPLES_MTDPART
|
|
|
|
|
|
|
|
config EXAMPLES_MTDPART_ARCHINIT
|
|
|
|
bool "Architecture-specific initialization"
|
|
|
|
default n
|
|
|
|
---help---
|
|
|
|
The default is to use the RAM MTD device at drivers/mtd/rammtd.c.
|
|
|
|
But an architecture-specific MTD driver can be used instead by
|
|
|
|
defining EXAMPLES_MTDPART_ARCHINIT. In this case, the
|
|
|
|
initialization logic will call mtdpart_archinitialize() to obtain
|
|
|
|
the MTD driver instance.
|
|
|
|
|
|
|
|
config EXAMPLES_MTDPART_NEBLOCKS
|
|
|
|
int "Number of erase blocks (simulated)"
|
|
|
|
default 32
|
|
|
|
depends on !EXAMPLES_MTDPART_ARCHINIT
|
|
|
|
---help---
|
|
|
|
When EXAMPLES_MTDPART_ARCHINIT is not defined, this test will use
|
|
|
|
the RAM MTD device at drivers/mtd/rammtd.c to simulate FLASH. In
|
2020-02-23 05:51:44 +01:00
|
|
|
this case, this value must be provided to give the number of erase
|
2013-04-30 23:54:02 +02:00
|
|
|
blocks in MTD RAM device.
|
|
|
|
|
|
|
|
The size of the allocated RAM drive will be:
|
|
|
|
|
|
|
|
EXAMPLES_MTDPART_ERASESIZE * EXAMPLES_MTDPART_NEBLOCKS
|
|
|
|
|
|
|
|
config EXAMPLES_MTDPART_NPARTITIONS
|
|
|
|
int "Number of partitions"
|
|
|
|
default 3
|
|
|
|
---help---
|
|
|
|
This setting provides the number of partitions to test. The
|
|
|
|
test will divide the reported size of the MTD device into equal-
|
|
|
|
sized sub-regions for each test partition.
|
|
|
|
|
|
|
|
endif
|