Merge tag 'mtd/fixes-for-5.3-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux

Pull MTD fixes from Miquel Raynal:
"NAND:

- Fix Micron driver as some chips enable internal ECC correction
during their discovery while they advertize they do not have any.

Hyperbus:

- Restrict the build to only ARM64 SoCs (and compile testing) which
is what should have been done since the beginning.

- Fix Kconfig issue by selection something instead of implying it"

* tag 'mtd/fixes-for-5.3-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux:
mtd: hyperbus: Add hardware dependency to AM654 driver
mtd: hyperbus: Kconfig: Fix HBMC_AM654 dependencies
mtd: rawnand: micron: handle on-die "ECC-off" devices correctly

Changed files
+13 -4
drivers
mtd
hyperbus
nand
+2 -1
drivers/mtd/hyperbus/Kconfig
··· 14 14 15 15 config HBMC_AM654 16 16 tristate "HyperBus controller driver for AM65x SoC" 17 + depends on ARM64 || COMPILE_TEST 17 18 select MULTIPLEXER 18 - select MUX_MMIO 19 + imply MUX_MMIO 19 20 help 20 21 This is the driver for HyperBus controller on TI's AM65x and 21 22 other SoCs
+11 -3
drivers/mtd/nand/raw/nand_micron.c
··· 390 390 (chip->id.data[4] & MICRON_ID_INTERNAL_ECC_MASK) != 0x2) 391 391 return MICRON_ON_DIE_UNSUPPORTED; 392 392 393 + /* 394 + * It seems that there are devices which do not support ECC officially. 395 + * At least the MT29F2G08ABAGA / MT29F2G08ABBGA devices supports 396 + * enabling the ECC feature but don't reflect that to the READ_ID table. 397 + * So we have to guarantee that we disable the ECC feature directly 398 + * after we did the READ_ID table command. Later we can evaluate the 399 + * ECC_ENABLE support. 400 + */ 393 401 ret = micron_nand_on_die_ecc_setup(chip, true); 394 402 if (ret) 395 403 return MICRON_ON_DIE_UNSUPPORTED; ··· 406 398 if (ret) 407 399 return MICRON_ON_DIE_UNSUPPORTED; 408 400 409 - if (!(id[4] & MICRON_ID_ECC_ENABLED)) 410 - return MICRON_ON_DIE_UNSUPPORTED; 411 - 412 401 ret = micron_nand_on_die_ecc_setup(chip, false); 413 402 if (ret) 403 + return MICRON_ON_DIE_UNSUPPORTED; 404 + 405 + if (!(id[4] & MICRON_ID_ECC_ENABLED)) 414 406 return MICRON_ON_DIE_UNSUPPORTED; 415 407 416 408 ret = nand_readid_op(chip, 0, id, sizeof(id));