summaryrefslogtreecommitdiff
path: root/drivers/mtd/ubi/Kconfig
diff options
context:
space:
mode:
authorShmulik Ladkani <shmulik.ladkani@gmail.com>2012-07-04 11:06:00 +0300
committerArtem Bityutskiy <artem.bityutskiy@linux.intel.com>2012-09-04 09:38:58 +0300
commit8beeb3bb9df8caba36ad3e4f226255dff9c92556 (patch)
tree4758809d39183d7aaccaa8178c5d5150c2bf1a9d /drivers/mtd/ubi/Kconfig
parentafe7d12b6d997ff8ceff02e405eae9ba54aa8350 (diff)
UBI: introduce new bad PEB limit
Introduce 'ubi->bad_peb_limit', which specifies an upper limit of PEBs UBI expects to go bad. Currently, it is initialized to a fixed percentage of total PEBs in the UBI device (configurable via CONFIG_MTD_UBI_BEB_LIMIT). The 'bad_peb_limit' is intended to be used for calculating the amount of PEBs UBI needs to reserve for bad eraseblock handling. Artem: minor amendments. Signed-off-by: Shmulik Ladkani <shmulik.ladkani@gmail.com> Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@linux.intel.com>
Diffstat (limited to 'drivers/mtd/ubi/Kconfig')
-rw-r--r--drivers/mtd/ubi/Kconfig26
1 files changed, 19 insertions, 7 deletions
diff --git a/drivers/mtd/ubi/Kconfig b/drivers/mtd/ubi/Kconfig
index ea4b95b5451c..76195ac90e51 100644
--- a/drivers/mtd/ubi/Kconfig
+++ b/drivers/mtd/ubi/Kconfig
@@ -34,13 +34,25 @@ config MTD_UBI_BEB_RESERVE
help
If the MTD device admits of bad eraseblocks (e.g. NAND flash), UBI
reserves some amount of physical eraseblocks to handle new bad
- eraseblocks. For example, if a flash physical eraseblock becomes bad,
- UBI uses these reserved physical eraseblocks to relocate the bad one.
- This option specifies how many physical eraseblocks will be reserved
- for bad eraseblock handling (percents of total number of good flash
- eraseblocks). If the underlying flash does not admit of bad
- eraseblocks (e.g. NOR flash), this value is ignored and nothing is
- reserved. Leave the default value if unsure.
+ eraseblocks. When a physical eraseblock becomes bad, UBI uses these
+ reserved physical eraseblocks to relocate the bad one. This
+ configuration option specifies how many physical eraseblocks will be
+ reserved for bad eraseblock handling (percents of total number of
+ good physical eraseblocks on this MTD partition). If the underlying
+ flash does not admit of bad eraseblocks (e.g. NOR flash), this value
+ is ignored and nothing is reserved. Leave the default value if
+ unsure.
+
+config MTD_UBI_BEB_LIMIT
+ int "Percentage of maximum expected bad eraseblocks"
+ default 2
+ range 0 25
+ help
+ This option specifies the maximum bad physical eraseblocks UBI
+ expects on the UBI device (percents of total number of physical
+ eraseblocks on this MTD partition). If the underlying flash does not
+ admit of bad eraseblocks (e.g. NOR flash), this value is ignored.
+ Leave the default value if unsure.
config MTD_UBI_GLUEBI
tristate "MTD devices emulation driver (gluebi)"