| /linux/drivers/mtd/nand/raw/ |
| H A D | sm_common.c | 13 struct mtd_oob_region *oobregion) in oob_sm_ooblayout_ecc() argument 18 oobregion->length = 3; in oob_sm_ooblayout_ecc() 19 oobregion->offset = ((section + 1) * 8) - 3; in oob_sm_ooblayout_ecc() 25 struct mtd_oob_region *oobregion) in oob_sm_ooblayout_free() argument 30 oobregion->offset = 0; in oob_sm_ooblayout_free() 31 oobregion->length = 4; in oob_sm_ooblayout_free() 35 oobregion->offset = 6; in oob_sm_ooblayout_free() 36 oobregion->length = 2; in oob_sm_ooblayout_free() 40 oobregion->offset = 11; in oob_sm_ooblayout_free() 41 oobregion->length = 2; in oob_sm_ooblayout_free() [all …]
|
| H A D | nand_micron.c | 102 struct mtd_oob_region *oobregion) in micron_nand_on_die_4_ooblayout_ecc() argument 107 oobregion->offset = (section * 16) + 8; in micron_nand_on_die_4_ooblayout_ecc() 108 oobregion->length = 8; in micron_nand_on_die_4_ooblayout_ecc() 115 struct mtd_oob_region *oobregion) in micron_nand_on_die_4_ooblayout_free() argument 120 oobregion->offset = (section * 16) + 2; in micron_nand_on_die_4_ooblayout_free() 121 oobregion->length = 6; in micron_nand_on_die_4_ooblayout_free() 133 struct mtd_oob_region *oobregion) in micron_nand_on_die_8_ooblayout_ecc() argument 140 oobregion->offset = mtd->oobsize - chip->ecc.total; in micron_nand_on_die_8_ooblayout_ecc() 141 oobregion->length = chip->ecc.total; in micron_nand_on_die_8_ooblayout_ecc() 148 struct mtd_oob_region *oobregion) in micron_nand_on_die_8_ooblayout_free() argument [all …]
|
| H A D | mxc_nand.c | 889 struct mtd_oob_region *oobregion) in mxc_v1_ooblayout_ecc() argument 896 oobregion->offset = (section * 16) + 6; in mxc_v1_ooblayout_ecc() 897 oobregion->length = MXC_V1_ECCBYTES; in mxc_v1_ooblayout_ecc() 903 struct mtd_oob_region *oobregion) in mxc_v1_ooblayout_free() argument 912 oobregion->offset = 0; in mxc_v1_ooblayout_free() 913 oobregion->length = 5; in mxc_v1_ooblayout_free() 915 oobregion->offset = 2; in mxc_v1_ooblayout_free() 916 oobregion->length = 4; in mxc_v1_ooblayout_free() 919 oobregion->offset = ((section - 1) * 16) + MXC_V1_ECCBYTES + 6; in mxc_v1_ooblayout_free() 921 oobregion->length = (section * 16) + 6 - in mxc_v1_ooblayout_free() [all …]
|
| H A D | fsl_ifc_nand.c | 85 struct mtd_oob_region *oobregion) in fsl_ifc_ooblayout_ecc() argument 92 oobregion->offset = 8; in fsl_ifc_ooblayout_ecc() 93 oobregion->length = chip->ecc.total; in fsl_ifc_ooblayout_ecc() 99 struct mtd_oob_region *oobregion) in fsl_ifc_ooblayout_free() argument 109 oobregion->offset = 0; in fsl_ifc_ooblayout_free() 110 oobregion->length = 5; in fsl_ifc_ooblayout_free() 112 oobregion->offset = 6; in fsl_ifc_ooblayout_free() 113 oobregion->length = 2; in fsl_ifc_ooblayout_free() 120 oobregion->offset = 2; in fsl_ifc_ooblayout_free() 121 oobregion->length = 6; in fsl_ifc_ooblayout_free() [all …]
|
| H A D | fsl_elbc_nand.c | 69 struct mtd_oob_region *oobregion) in fsl_elbc_ooblayout_ecc() argument 77 oobregion->offset = (16 * section) + 6; in fsl_elbc_ooblayout_ecc() 79 oobregion->offset += 2; in fsl_elbc_ooblayout_ecc() 81 oobregion->length = chip->ecc.bytes; in fsl_elbc_ooblayout_ecc() 87 struct mtd_oob_region *oobregion) in fsl_elbc_ooblayout_free() argument 96 oobregion->offset = 0; in fsl_elbc_ooblayout_free() 98 oobregion->offset++; in fsl_elbc_ooblayout_free() 99 oobregion->length = (priv->fmr & FMR_ECCM) ? 7 : 5; in fsl_elbc_ooblayout_free() 101 oobregion->offset = (16 * section) - in fsl_elbc_ooblayout_free() 104 oobregion->length = 13; in fsl_elbc_ooblayout_free() [all …]
|
| H A D | sh_flctl.c | 32 struct mtd_oob_region *oobregion) in flctl_4secc_ooblayout_sp_ecc() argument 39 oobregion->offset = 0; in flctl_4secc_ooblayout_sp_ecc() 40 oobregion->length = chip->ecc.bytes; in flctl_4secc_ooblayout_sp_ecc() 46 struct mtd_oob_region *oobregion) in flctl_4secc_ooblayout_sp_free() argument 51 oobregion->offset = 12; in flctl_4secc_ooblayout_sp_free() 52 oobregion->length = 4; in flctl_4secc_ooblayout_sp_free() 63 struct mtd_oob_region *oobregion) in flctl_4secc_ooblayout_lp_ecc() argument 70 oobregion->offset = (section * 16) + 6; in flctl_4secc_ooblayout_lp_ecc() 71 oobregion->length = chip->ecc.bytes; in flctl_4secc_ooblayout_lp_ecc() 77 struct mtd_oob_region *oobregion) in flctl_4secc_ooblayout_lp_free() argument [all …]
|
| H A D | intel-nand-controller.c | 237 struct mtd_oob_region *oobregion) in ebu_nand_ooblayout_ecc() argument 244 oobregion->offset = HSNAND_ECC_OFFSET; in ebu_nand_ooblayout_ecc() 245 oobregion->length = chip->ecc.total; in ebu_nand_ooblayout_ecc() 251 struct mtd_oob_region *oobregion) in ebu_nand_ooblayout_free() argument 258 oobregion->offset = chip->ecc.total + HSNAND_ECC_OFFSET; in ebu_nand_ooblayout_free() 259 oobregion->length = mtd->oobsize - oobregion->offset; in ebu_nand_ooblayout_free()
|
| H A D | lpc32xx_mlc.c | 130 struct mtd_oob_region *oobregion) in lpc32xx_ooblayout_ecc() argument 137 oobregion->offset = ((section + 1) * 16) - nand_chip->ecc.bytes; in lpc32xx_ooblayout_ecc() 138 oobregion->length = nand_chip->ecc.bytes; in lpc32xx_ooblayout_ecc() 144 struct mtd_oob_region *oobregion) in lpc32xx_ooblayout_free() argument 151 oobregion->offset = 16 * section; in lpc32xx_ooblayout_free() 152 oobregion->length = 16 - nand_chip->ecc.bytes; in lpc32xx_ooblayout_free()
|
| H A D | cafe_nand.c | 451 struct mtd_oob_region *oobregion) in cafe_ooblayout_ecc() argument 458 oobregion->offset = 0; in cafe_ooblayout_ecc() 459 oobregion->length = chip->ecc.total; in cafe_ooblayout_ecc() 465 struct mtd_oob_region *oobregion) in cafe_ooblayout_free() argument 472 oobregion->offset = chip->ecc.total; in cafe_ooblayout_free() 473 oobregion->length = mtd->oobsize - chip->ecc.total; in cafe_ooblayout_free()
|
| H A D | tegra_nand.c | 204 struct mtd_oob_region *oobregion) in tegra_nand_ooblayout_rs_ecc() argument 213 oobregion->offset = SKIP_SPARE_BYTES; in tegra_nand_ooblayout_rs_ecc() 214 oobregion->length = round_up(bytes_per_step * chip->ecc.steps, 4); in tegra_nand_ooblayout_rs_ecc() 220 struct mtd_oob_region *oobregion) in tegra_nand_ooblayout_no_free() argument 231 struct mtd_oob_region *oobregion) in tegra_nand_ooblayout_bch_ecc() argument 240 oobregion->offset = SKIP_SPARE_BYTES; in tegra_nand_ooblayout_bch_ecc() 241 oobregion->length = round_up(bytes_per_step * chip->ecc.steps, 4); in tegra_nand_ooblayout_bch_ecc()
|
| H A D | diskonchip.c | 811 struct mtd_oob_region *oobregion) in doc200x_ooblayout_ecc() argument 816 oobregion->offset = 0; in doc200x_ooblayout_ecc() 817 oobregion->length = 6; in doc200x_ooblayout_ecc() 823 struct mtd_oob_region *oobregion) in doc200x_ooblayout_free() argument 841 oobregion->offset = 8; in doc200x_ooblayout_free() 842 oobregion->length = 8; in doc200x_ooblayout_free() 844 oobregion->offset = 6; in doc200x_ooblayout_free() 845 oobregion->length = 2; in doc200x_ooblayout_free()
|
| H A D | denali.c | 923 struct mtd_oob_region *oobregion) in denali_ooblayout_ecc() argument 931 oobregion->offset = denali->oob_skip_bytes; in denali_ooblayout_ecc() 932 oobregion->length = chip->ecc.total; in denali_ooblayout_ecc() 938 struct mtd_oob_region *oobregion) in denali_ooblayout_free() argument 946 oobregion->offset = chip->ecc.total + denali->oob_skip_bytes; in denali_ooblayout_free() 947 oobregion->length = mtd->oobsize - oobregion->offset; in denali_ooblayout_free()
|
| H A D | hisi504_nand.c | 613 struct mtd_oob_region *oobregion) in hisi_ooblayout_ecc() argument 620 struct mtd_oob_region *oobregion) in hisi_ooblayout_free() argument 625 oobregion->offset = 2; in hisi_ooblayout_free() 626 oobregion->length = 6; in hisi_ooblayout_free()
|
| H A D | qcom_nandc.c | 1323 struct mtd_oob_region *oobregion) in qcom_nand_ooblayout_ecc() argument 1333 oobregion->length = (ecc->bytes * (ecc->steps - 1)) + in qcom_nand_ooblayout_ecc() 1335 oobregion->offset = 0; in qcom_nand_ooblayout_ecc() 1337 oobregion->length = host->ecc_bytes_hw + host->spare_bytes; in qcom_nand_ooblayout_ecc() 1338 oobregion->offset = mtd->oobsize - oobregion->length; in qcom_nand_ooblayout_ecc() 1345 struct mtd_oob_region *oobregion) in qcom_nand_ooblayout_free() argument 1354 oobregion->length = ecc->steps * 4; in qcom_nand_ooblayout_free() 1355 oobregion->offset = ((ecc->steps - 1) * ecc->bytes) + host->bbm_size; in qcom_nand_ooblayout_free()
|
| H A D | meson_nand.c | 1097 struct mtd_oob_region *oobregion) in meson_ooblayout_ecc() argument 1104 oobregion->offset = 2 + (section * (2 + nand->ecc.bytes)); in meson_ooblayout_ecc() 1105 oobregion->length = nand->ecc.bytes; in meson_ooblayout_ecc() 1111 struct mtd_oob_region *oobregion) in meson_ooblayout_free() argument 1118 oobregion->offset = section * (2 + nand->ecc.bytes); in meson_ooblayout_free() 1119 oobregion->length = 2; in meson_ooblayout_free()
|
| H A D | stm32_fmc2_nand.c | 1679 struct mtd_oob_region *oobregion) in stm32_fmc2_nfc_ooblayout_ecc() argument 1687 oobregion->length = ecc->total; in stm32_fmc2_nfc_ooblayout_ecc() 1688 oobregion->offset = FMC2_BBM_LEN; in stm32_fmc2_nfc_ooblayout_ecc() 1694 struct mtd_oob_region *oobregion) in stm32_fmc2_nfc_ooblayout_free() argument 1702 oobregion->length = mtd->oobsize - ecc->total - FMC2_BBM_LEN; in stm32_fmc2_nfc_ooblayout_free() 1703 oobregion->offset = ecc->total + FMC2_BBM_LEN; in stm32_fmc2_nfc_ooblayout_free()
|
| /linux/drivers/mtd/nand/raw/ingenic/ |
| H A D | ingenic_nand_drv.c | 72 struct mtd_oob_region *oobregion) in qi_lb60_ooblayout_ecc() argument 80 oobregion->length = ecc->total; in qi_lb60_ooblayout_ecc() 81 oobregion->offset = 12; in qi_lb60_ooblayout_ecc() 87 struct mtd_oob_region *oobregion) in qi_lb60_ooblayout_free() argument 95 oobregion->length = mtd->oobsize - ecc->total - 12; in qi_lb60_ooblayout_free() 96 oobregion->offset = 12 + ecc->total; in qi_lb60_ooblayout_free() 107 struct mtd_oob_region *oobregion) in jz4725b_ooblayout_ecc() argument 115 oobregion->length = ecc->total; in jz4725b_ooblayout_ecc() 116 oobregion->offset = 3; in jz4725b_ooblayout_ecc() 122 struct mtd_oob_region *oobregion) in jz4725b_ooblayout_free() argument [all …]
|
| /linux/arch/arm/mach-pxa/ |
| H A D | spitz.c | 844 struct mtd_oob_region *oobregion) in akita_ooblayout_ecc() argument 851 oobregion->offset = 5; in akita_ooblayout_ecc() 852 oobregion->length = 1; in akita_ooblayout_ecc() 856 oobregion->offset = 1; in akita_ooblayout_ecc() 857 oobregion->length = 3; in akita_ooblayout_ecc() 861 oobregion->offset = 6; in akita_ooblayout_ecc() 862 oobregion->length = 2; in akita_ooblayout_ecc() 866 oobregion->offset += (section / 3) * 0x10; in akita_ooblayout_ecc() 872 struct mtd_oob_region *oobregion) in akita_ooblayout_free() argument 877 oobregion->offset = 8; in akita_ooblayout_free() [all …]
|
| /linux/drivers/mtd/ |
| H A D | mtdchar.c | 446 struct mtd_oob_region oobregion; in shrink_ecclayout() local 458 ret = mtd_ooblayout_ecc(mtd, section++, &oobregion); in shrink_ecclayout() 466 eccpos = oobregion.offset; in shrink_ecclayout() 468 eccpos < oobregion.offset + oobregion.length; i++) { in shrink_ecclayout() 475 ret = mtd_ooblayout_free(mtd, i, &oobregion); in shrink_ecclayout() 483 to->oobfree[i].offset = oobregion.offset; in shrink_ecclayout() 484 to->oobfree[i].length = oobregion.length; in shrink_ecclayout() 493 struct mtd_oob_region oobregion; in get_oobinfo() local 505 ret = mtd_ooblayout_ecc(mtd, section++, &oobregion); in get_oobinfo() 513 if (oobregion.length + i > ARRAY_SIZE(to->eccpos)) in get_oobinfo() [all …]
|
| /linux/drivers/mtd/nand/ |
| H A D | ecc-realtek.c | 112 struct mtd_oob_region *oobregion) in rtl_ecc_ooblayout_ecc() argument 120 oobregion->offset = ctx->steps * RTL_ECC_FREE_SIZE + section * ctx->parity_size; in rtl_ecc_ooblayout_ecc() 121 oobregion->length = ctx->parity_size; in rtl_ecc_ooblayout_ecc() 127 struct mtd_oob_region *oobregion) in rtl_ecc_ooblayout_free() argument 138 oobregion->offset = section * RTL_ECC_FREE_SIZE + bbm; in rtl_ecc_ooblayout_free() 139 oobregion->length = RTL_ECC_FREE_SIZE - bbm; in rtl_ecc_ooblayout_free()
|
| /linux/drivers/mtd/devices/ |
| H A D | docg3.c | 57 struct mtd_oob_region *oobregion) in docg3_ooblayout_ecc() argument 63 oobregion->offset = 7; in docg3_ooblayout_ecc() 64 oobregion->length = 8; in docg3_ooblayout_ecc() 70 struct mtd_oob_region *oobregion) in docg3_ooblayout_free() argument 77 oobregion->offset = 0; in docg3_ooblayout_free() 78 oobregion->length = 7; in docg3_ooblayout_free() 80 oobregion->offset = 15; in docg3_ooblayout_free() 81 oobregion->length = 1; in docg3_ooblayout_free()
|
| /linux/drivers/spi/ |
| H A D | spi-amlogic-spifc-a4.c | 856 struct mtd_oob_region *oobregion) in aml_sfc_layout_ecc() argument 863 oobregion->offset = ECC_BCH8_USER_BYTES + (section * ECC_BCH8_INFO_BYTES); in aml_sfc_layout_ecc() 864 oobregion->length = ECC_BCH8_PARITY_BYTES; in aml_sfc_layout_ecc() 870 struct mtd_oob_region *oobregion) in aml_sfc_ooblayout_free() argument 877 oobregion->offset = section * ECC_BCH8_INFO_BYTES; in aml_sfc_ooblayout_free() 878 oobregion->length = ECC_BCH8_USER_BYTES; in aml_sfc_ooblayout_free()
|
| /linux/drivers/mtd/nand/raw/atmel/ |
| H A D | nand-controller.c | 820 struct mtd_oob_region oobregion; in atmel_nand_pmecc_generate_eccbytes() local 837 mtd_ooblayout_ecc(mtd, 0, &oobregion); in atmel_nand_pmecc_generate_eccbytes() 838 eccbuf = chip->oob_poi + oobregion.offset; in atmel_nand_pmecc_generate_eccbytes() 855 struct mtd_oob_region oobregion; in atmel_nand_pmecc_correct_data() local 872 mtd_ooblayout_ecc(mtd, 0, &oobregion); in atmel_nand_pmecc_correct_data() 873 eccbuf = chip->oob_poi + oobregion.offset; in atmel_nand_pmecc_correct_data()
|
| /linux/include/linux/mtd/ |
| H A D | mtd.h | 435 struct mtd_oob_region *oobregion);
|