From: computersforpeace@gmail.com (Brian Norris)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v4 11/11] mtd: nand: stm_nand_bch: provide ST's implementation of Bad Block Table
Date: Tue, 16 Dec 2014 14:49:42 -0800 [thread overview]
Message-ID: <20141216224942.GH9759@ld-irv-0074> (raw)
In-Reply-To: <1415206793-25670-12-git-send-email-lee.jones@linaro.org>
On Wed, Nov 05, 2014 at 04:59:53PM +0000, Lee Jones wrote:
> This is the BBT format ST use internally. It has to be used on boards
> which were flashed with or actively use ST's tooling and boards which
> are booted using ST's bootloaders.
>
> Signed-off-by: Lee Jones <lee.jones@linaro.org>
> ---
> drivers/mtd/nand/Kconfig | 8 +
> drivers/mtd/nand/Makefile | 4 +-
> drivers/mtd/nand/stm_nand_bbt.c | 619 ++++++++++++++++++++++++++++++++++++++++
> 3 files changed, 630 insertions(+), 1 deletion(-)
> create mode 100644 drivers/mtd/nand/stm_nand_bbt.c
>
> diff --git a/drivers/mtd/nand/Kconfig b/drivers/mtd/nand/Kconfig
> index 2738eec..040374d 100644
> --- a/drivers/mtd/nand/Kconfig
> +++ b/drivers/mtd/nand/Kconfig
> @@ -520,4 +520,12 @@ config MTD_NAND_STM_BCH
> help
> Adds support for the STMicroelectronics NANDi BCH Controller.
>
> +config MTD_NAND_STM_BCH_BBT
> + bool "STMicroelectronics: NANDi BCH Controller Bad Block Table support"
> + default y if MTD_NAND_STM_BCH=y || MTD_NAND_STM_BCH=m
This line could be simplified. But it's also weird now that you can
select CONFIG_MTD_NAND_STM_BCH_BBT, but that won't build the BBT code if
MTD_NAND_STM_BCH=n. So I'd suggest the following instead:
depends on MTD_NAND_STM_BCH
default y
Or maybe this could be more explicit about the default:
depends on MTD_NAND_STM_BCH
default MTD_NAND_STM_BCH
> + help
> + Adds support for the STMicroelectronics Bad Block Table support.
> + If you are using a device which has has already been initialised
> + by ST or using their tooling/bootloaders, leave this enabled.
> +
> endif # MTD_NAND
> diff --git a/drivers/mtd/nand/Makefile b/drivers/mtd/nand/Makefile
> index 6044e0a..e342c91 100644
> --- a/drivers/mtd/nand/Makefile
> +++ b/drivers/mtd/nand/Makefile
> @@ -41,7 +41,9 @@ obj-$(CONFIG_MTD_NAND_MLC_LPC32XX) += lpc32xx_mlc.o
> obj-$(CONFIG_MTD_NAND_SH_FLCTL) += sh_flctl.o
> obj-$(CONFIG_MTD_NAND_MXC) += mxc_nand.o
> obj-$(CONFIG_MTD_NAND_SOCRATES) += socrates_nand.o
> -obj-$(CONFIG_MTD_NAND_STM_BCH) += stm_nand_bch.o
> +obj-$(CONFIG_MTD_NAND_STM_BCH) += stm-nand.o
> +stm-nand-y += stm_nand_bch.o
> +stm-nand-$(CONFIG_MTD_NAND_STM_BCH_BBT) += stm_nand_bbt.o
> obj-$(CONFIG_MTD_NAND_TXX9NDFMC) += txx9ndfmc.o
> obj-$(CONFIG_MTD_NAND_NUC900) += nuc900_nand.o
> obj-$(CONFIG_MTD_NAND_MPC5121_NFC) += mpc5121_nfc.o
[...]
Brian
next prev parent reply other threads:[~2014-12-16 22:49 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-11-05 16:59 [PATCH v4 00/11] mtd: nand: Support for new DT NAND driver Lee Jones
2014-11-05 16:59 ` [PATCH v4 01/11] ARM: multi-v7: Enable ST BCH NAND Lee Jones
2014-11-05 16:59 ` [PATCH v4 02/11] ARM: sti: Add two new clock definitions for use with ST's NAND controllers Lee Jones
2014-11-05 16:59 ` [PATCH v4 03/11] ARM: sti: Add BCH (NAND Flash) Controller support for STiH41x (Orly) SoCs Lee Jones
2014-11-05 16:59 ` [PATCH v4 04/11] ARM: sti: Enable BCH NAND for STiH416 B2020-RevE Lee Jones
2014-11-05 16:59 ` [PATCH v4 05/11] mtd: nand: Add new generic NAND Device Tree property 'nand-chip-select' Lee Jones
2014-11-05 16:59 ` [PATCH v4 06/11] mtd: nand: WARN() if EEC Bytes per page is larger than the OOB Lee Jones
2014-11-05 16:59 ` [PATCH v4 07/11] mtd: nand: stm_nand_bch: provide Device Tree documentation Lee Jones
2014-11-05 16:59 ` [PATCH v4 08/11] mtd: nand: stm_nand_bch: add shared register defines for ST's NAND Controller drivers Lee Jones
2014-11-05 16:59 ` [PATCH v4 09/11] mtd: nand: stm_nand_bch: adding BBT header Lee Jones
2014-11-05 16:59 ` [PATCH v4 10/11] mtd: nand: stm_nand_bch: add support for ST's BCH NAND controller Lee Jones
2014-12-16 22:46 ` Brian Norris
2014-11-05 16:59 ` [PATCH v4 11/11] mtd: nand: stm_nand_bch: provide ST's implementation of Bad Block Table Lee Jones
2014-12-16 22:49 ` Brian Norris [this message]
2014-12-09 14:54 ` [PATCH v4 00/11] mtd: nand: Support for new DT NAND driver Lee Jones
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20141216224942.GH9759@ld-irv-0074 \
--to=computersforpeace@gmail.com \
--cc=linux-arm-kernel@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox