/openbmc/linux/drivers/mtd/nand/ |
H A D | ecc-mtk.c | 50 const u8 *ecc_strength; member 179 if (ecc->caps->ecc_strength[i] == config->strength) in mtk_ecc_config() 438 const u8 *ecc_strength = ecc->caps->ecc_strength; in mtk_ecc_adjust_strength() local 442 if (*p <= ecc_strength[i]) { in mtk_ecc_adjust_strength() 444 *p = ecc_strength[i]; in mtk_ecc_adjust_strength() 445 else if (*p != ecc_strength[i]) in mtk_ecc_adjust_strength() 446 *p = ecc_strength[i - 1]; in mtk_ecc_adjust_strength() 464 .ecc_strength = ecc_strength_mt2701, 475 .ecc_strength = ecc_strength_mt2712, 486 .ecc_strength = ecc_strength_mt7622, [all …]
|
/openbmc/u-boot/tools/ |
H A D | mxsboot.c | 137 static inline uint32_t mx28_nand_ecc_size_in_bits(uint32_t ecc_strength) in mx28_nand_ecc_size_in_bits() argument 139 return ecc_strength * MXS_NAND_BITS_PER_ECC_LEVEL; in mx28_nand_ecc_size_in_bits() 145 int ecc_strength; in mx28_nand_get_ecc_strength() local 155 ecc_strength = ((page_oob_size - MXS_NAND_METADATA_SIZE) * 8) in mx28_nand_get_ecc_strength() 159 return round_down(ecc_strength, 2); in mx28_nand_get_ecc_strength() 163 uint32_t ecc_strength) in mx28_nand_get_mark_offset() argument 173 chunk_ecc_size_in_bits = mx28_nand_ecc_size_in_bits(ecc_strength); in mx28_nand_get_mark_offset() 213 uint32_t ecc_strength; in mx28_nand_mark_byte_offset() local 215 return mx28_nand_get_mark_offset(nand_writesize, ecc_strength) >> 3; in mx28_nand_mark_byte_offset() 220 uint32_t ecc_strength; in mx28_nand_mark_bit_offset() local [all …]
|
H A D | sunxi-spl-image-builder.c | 22 int ecc_strength; member 118 int eccbytes = DIV_ROUND_UP(info->ecc_strength * 14, 8); in write_page() 245 bch = init_bch(14, info->ecc_strength, BCH_PRIMITIVE_POLY); in create_image() 371 if (valid_ecc_strengths[i] == info->ecc_strength) in check_image_info() 377 info->ecc_strength); in check_image_info() 381 eccbytes = DIV_ROUND_UP(info->ecc_strength * 14, 8); in check_image_info() 435 info.ecc_strength = strtol(optarg, &endptr, 0); in main()
|
/openbmc/linux/drivers/mtd/nand/raw/gpmi-nand/ |
H A D | gpmi-nand.c | 228 geo->ecc_strength, in gpmi_dump_info() 331 geo->ecc_strength = round_up(ecc_strength, 2); in set_geometry_by_ecc_info() 440 int ecc_strength; in get_ecc_strength() local 471 geo->ecc_strength); in set_geometry_for_large_oob() 488 geo->ecc_strength = max_ecc; in set_geometry_for_large_oob() 492 geo->ecc_strength -= 2; in set_geometry_for_large_oob() 560 geo->ecc_strength, in set_geometry_for_large_oob() 612 geo->ecc_strength, in legacy_set_geometry() 1506 unsigned int ecc_strength = geo->ecc_strength >> 1; in gpmi_bch_layout_std() local 1575 unsigned int ecc_strength; in gpmi_ecc_read_subpage() local [all …]
|
H A D | gpmi-nand.h | 50 unsigned int ecc_strength; member
|
/openbmc/u-boot/drivers/mtd/nand/raw/ |
H A D | sunxi_nand_spl.c | 87 int ecc_strength; member 259 int oob_chunk_sz = ecc_bytes[conf->ecc_strength]; in nand_read_page() 280 writel((rand_seed << 16) | (conf->ecc_strength << 12) | in nand_read_page() 390 for (conf->ecc_strength = max_ecc_strength; in nand_detect_ecc_config() 391 conf->ecc_strength >= 0; in nand_detect_ecc_config() 392 conf->ecc_strength--) { in nand_detect_ecc_config()
|
H A D | mxs_nand.c | 118 uint32_t chunk_ecc_size_in_bits = geo->ecc_strength * geo->gf_len; in mxs_nand_calc_mark_offset() 165 unsigned int ecc_strength, in mxs_nand_calc_ecc_layout_by_info() argument 183 geo->ecc_strength = round_up(ecc_strength, 2); in mxs_nand_calc_ecc_layout_by_info() 189 if (geo->ecc_strength > nand_info->max_ecc_strength_supported) in mxs_nand_calc_ecc_layout_by_info() 230 geo->ecc_strength = ((mtd->oobsize - MXS_NAND_METADATA_SIZE) * 8) in mxs_nand_calc_ecc_layout() 233 geo->ecc_strength = min(round_down(geo->ecc_strength, 2), in mxs_nand_calc_ecc_layout() 1018 tmp |= (geo->ecc_strength >> 1) << BCH_FLASHLAYOUT0_ECC0_OFFSET; in mxs_nand_setup_ecc() 1026 tmp |= (geo->ecc_strength >> 1) << BCH_FLASHLAYOUT1_ECCN_OFFSET; in mxs_nand_setup_ecc() 1252 nand->ecc.strength = nand_info->bch_geometry.ecc_strength; in mxs_nand_init_ctrl()
|
H A D | pxa3xx_nand.h | 56 int ecc_strength, ecc_step_size; member
|
H A D | mxs_nand.h | 30 unsigned int ecc_strength; member
|
H A D | pxa3xx_nand.c | 1646 uint16_t ecc_strength, ecc_step; in pxa3xx_nand_scan() local 1689 if (pdata->ecc_strength && pdata->ecc_step_size) { in pxa3xx_nand_scan() 1690 ecc_strength = pdata->ecc_strength; in pxa3xx_nand_scan() 1693 ecc_strength = chip->ecc_strength_ds; in pxa3xx_nand_scan() 1698 if (ecc_strength < 1 && ecc_step < 1) { in pxa3xx_nand_scan() 1699 ecc_strength = 1; in pxa3xx_nand_scan() 1703 ret = pxa_ecc_init(info, &chip->ecc, ecc_strength, in pxa3xx_nand_scan() 1851 pdata->ecc_strength = fdtdec_get_int(blob, node, in pxa3xx_nand_probe_dt()
|
H A D | nand_base.c | 3885 int ret, ecc_mode = -1, ecc_strength, ecc_step; in nand_dt_init() local 3913 ecc_strength = fdtdec_get_int(blob, node, "nand-ecc-strength", -1); in nand_dt_init() 3916 if ((ecc_step >= 0 && !(ecc_strength >= 0)) || in nand_dt_init() 3917 (!(ecc_step >= 0) && ecc_strength >= 0)) { in nand_dt_init() 3925 if (ecc_strength >= 0) in nand_dt_init() 3926 chip->ecc.strength = ecc_strength; in nand_dt_init() 4586 mtd->ecc_strength = ecc->strength; in nand_scan_tail() 4594 mtd->bitflip_threshold = DIV_ROUND_UP(mtd->ecc_strength * 3, 4); in nand_scan_tail()
|
/openbmc/linux/include/linux/platform_data/ |
H A D | brcmnand.h | 9 unsigned int ecc_strength; member
|
H A D | mtd-nand-pxa3xx.h | 19 int ecc_strength, ecc_step_size; member
|
/openbmc/linux/drivers/bcma/ |
H A D | driver_chipcommon_nflash.c | 53 cc->nflash.brcmnand_info.ecc_strength = 1; in bcma_nflash_init()
|
/openbmc/linux/Documentation/ABI/testing/ |
H A D | sysfs-class-mtd | 125 What: /sys/class/mtd/mtdX/ecc_strength 152 If not, then the default value is ecc_strength. 168 ecc_strength, -EUCLEAN is never returned by the read operations. 174 i.e., devices for which ecc_strength is zero.
|
/openbmc/u-boot/cmd/ |
H A D | mtd.c | 166 if (mtd->ecc_strength) { in mtd_show_device() 167 printf(" - ECC strength: %u bits\n", mtd->ecc_strength); in mtd_show_device()
|
/openbmc/u-boot/drivers/mtd/ |
H A D | mtdcore.c | 334 return snprintf(buf, PAGE_SIZE, "%u\n", mtd->ecc_strength); in mtd_ecc_strength_show() 336 static DEVICE_ATTR(ecc_strength, S_IRUGO, mtd_ecc_strength_show, NULL); 447 mtd->bitflip_threshold = mtd->ecc_strength; in add_mtd_device() 979 if (mtd->ecc_strength == 0) in mtd_read() 1096 if (mtd->ecc_strength == 0) in mtd_read_oob()
|
H A D | mtdpart.c | 759 slave->ecc_strength = master->ecc_strength; in allocate_partition()
|
/openbmc/linux/drivers/mtd/ |
H A D | mtdpart.c | 203 child->ecc_strength = parent->ecc_strength; in allocate_partition()
|
H A D | mtdcore.c | 261 return sysfs_emit(buf, "%u\n", mtd->ecc_strength); in mtd_ecc_strength_show() 263 MTD_DEVICE_ATTR_RO(ecc_strength); 703 mtd->bitflip_threshold = mtd->ecc_strength; in add_mtd_device() 1725 if (mtd->ecc_strength == 0) in mtd_read_oob()
|
/openbmc/linux/drivers/mtd/nand/raw/ |
H A D | intel-nand-controller.c | 443 static const u8 ecc_strength[] = { 1, 1, 4, 8, 24, 32, 40, 60, }; variable 478 if (ecc_strength_ds == ecc_strength[val]) in ebu_nand_attach_chip()
|
/openbmc/u-boot/include/linux/mtd/ |
H A D | mtd.h | 221 unsigned int ecc_strength; member
|
/openbmc/linux/include/linux/mtd/ |
H A D | mtd.h | 304 unsigned int ecc_strength; member
|
/openbmc/linux/drivers/mtd/nand/spi/ |
H A D | core.c | 1287 mtd->ecc_strength = nanddev_get_ecc_conf(nand)->strength; in spinand_init()
|
/openbmc/linux/drivers/mtd/devices/ |
H A D | docg3.c | 1787 mtd->ecc_strength = DOC_ECC_BCH_T; in doc_set_driver_info()
|