linux_dsm_epyc7002/include/linux/mtd
Masahiro Yamada a03c60178c mtd: nand: add a shorthand to generate nand_ecc_caps structure
struct nand_ecc_caps was designed as flexible as possible to support
multiple stepsizes (like sunxi_nand.c).

So, we need to write multiple arrays even for the simplest case.
I guess many controllers support a single stepsize, so here is a
shorthand macro for the case.

It allows to describe like ...

NAND_ECC_CAPS_SINGLE(denali_pci_ecc_caps, denali_calc_ecc_bytes, 512, 8, 15);

... instead of

static const int denali_pci_ecc_strengths[] = {8, 15};
static const struct nand_ecc_step_info denali_pci_ecc_stepinfo = {
        .stepsize = 512,
        .strengths = denali_pci_ecc_strengths,
        .nstrengths = ARRAY_SIZE(denali_pci_ecc_strengths),
};
static const struct nand_ecc_caps denali_pci_ecc_caps = {
        .stepinfos = &denali_pci_ecc_stepinfo,
        .nstepinfos = 1,
        .calc_ecc_bytes = denali_calc_ecc_bytes,
};

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
2017-06-10 13:40:10 +02:00
..
bbm.h mtd: onenand: make onenand_scan_bbt() static 2016-01-23 14:00:16 -08:00
blktrans.h
cfi_endian.h
cfi.h mtd: cfi: deinline large functions 2015-05-27 12:42:16 -07:00
concat.h
doc2000.h
flashchip.h
ftl.h
gen_probe.h
inftl.h mtd: inftl: kill unused oobinfo field 2016-01-26 10:27:33 -08:00
latch-addr-flash.h
lpc32xx_mlc.h
lpc32xx_slc.h
map.h mtd: avoid stack overflow in MTD CFI code 2016-04-03 16:46:24 -07:00
mtd.h MTD updates for 4.12-rc1: 2017-05-11 10:44:22 -07:00
mtdram.h
nand_bch.h mtd: nand: simplify nand_bch_init() usage 2016-03-07 16:23:09 -08:00
nand_ecc.h
nand-gpio.h
nand.h mtd: nand: add a shorthand to generate nand_ecc_caps structure 2017-06-10 13:40:10 +02:00
ndfc.h
nftl.h mtd: nftl: kill unused oobinfo field 2016-01-26 10:27:34 -08:00
onenand_regs.h
onenand.h mtd: onenand: switch to mtd_ooblayout_ops 2016-05-05 23:51:49 +02:00
partitions.h mtd: Add partition device node to mtd partition devices 2017-02-09 19:19:25 -08:00
pfow.h
physmap.h
pismo.h
plat-ram.h
qinfo.h scripts/spelling.txt: add "partiton" pattern and fix typo instances 2017-02-27 18:43:46 -08:00
sh_flctl.h mtd: sh_flctl: pass FIFO as physical address 2015-12-18 18:27:13 -08:00
sharpsl.h mtd: nand: sharpsl: switch to mtd_ooblayout_ops 2016-05-05 23:51:36 +02:00
spear_smi.h
spi-nor.h mtd: spi-nor: rename SPINOR_OP_* macros of the 4-byte address op codes 2017-02-10 13:55:03 +01:00
super.h
ubi.h
xip.h