diff options
| author | Dmitry Torokhov <[email protected]> | 2023-08-30 16:06:38 -0700 | 
|---|---|---|
| committer | Dmitry Torokhov <[email protected]> | 2023-08-30 16:06:38 -0700 | 
| commit | 1ac731c529cd4d6adbce134754b51ff7d822b145 (patch) | |
| tree | 143ab3f35ca5f3b69f583c84e6964b17139c2ec1 /drivers/mtd/nand/raw/nand_hynix.c | |
| parent | 07b4c950f27bef0362dc6ad7ee713aab61d58149 (diff) | |
| parent | 54116d442e001e1b6bd482122043b1870998a1f3 (diff) | |
Merge branch 'next' into for-linus
Prepare input updates for 6.6 merge window.
Diffstat (limited to 'drivers/mtd/nand/raw/nand_hynix.c')
| -rw-r--r-- | drivers/mtd/nand/raw/nand_hynix.c | 13 | 
1 files changed, 13 insertions, 0 deletions
diff --git a/drivers/mtd/nand/raw/nand_hynix.c b/drivers/mtd/nand/raw/nand_hynix.c index 0d4d4bbfdece..39076735a3fb 100644 --- a/drivers/mtd/nand/raw/nand_hynix.c +++ b/drivers/mtd/nand/raw/nand_hynix.c @@ -728,8 +728,21 @@ static int hynix_nand_init(struct nand_chip *chip)  	return ret;  } +static void hynix_fixup_onfi_param_page(struct nand_chip *chip, +					struct nand_onfi_params *p) +{ +	/* +	 * Certain chips might report a 0 on sdr_timing_mode field +	 * (bytes 129-130). This has been seen on H27U4G8F2GDA-BI. +	 * According to ONFI specification, bit 0 of this field "shall be 1". +	 * Forcibly set this bit. +	 */ +	p->sdr_timing_modes |= cpu_to_le16(BIT(0)); +} +  const struct nand_manufacturer_ops hynix_nand_manuf_ops = {  	.detect = hynix_nand_decode_id,  	.init = hynix_nand_init,  	.cleanup = hynix_nand_cleanup, +	.fixup_onfi_param_page = hynix_fixup_onfi_param_page,  };  |