Home
last modified time | relevance | path

Searched refs:oobregion (Results 1 – 24 of 24) sorted by relevance

/linux/drivers/mtd/nand/raw/
H A Dsm_common.c13 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 Dnand_micron.c102 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 Dmxc_nand.c889 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 Dfsl_ifc_nand.c85 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 Dfsl_elbc_nand.c69 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 Dsh_flctl.c32 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 Dintel-nand-controller.c237 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 Dlpc32xx_mlc.c130 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 Dcafe_nand.c451 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 Dtegra_nand.c204 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 Ddiskonchip.c811 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 Ddenali.c923 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 Dhisi504_nand.c613 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 Dqcom_nandc.c1323 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 Dmeson_nand.c1097 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 Dstm32_fmc2_nand.c1679 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 Dingenic_nand_drv.c72 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 Dspitz.c844 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 Dmtdchar.c446 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 Decc-realtek.c112 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 Ddocg3.c57 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 Dspi-amlogic-spifc-a4.c856 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 Dnand-controller.c820 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 Dmtd.h435 struct mtd_oob_region *oobregion);