Skip to content

Commit 2f36bae

Browse files
committed
mtd: rawnand: toshiba: Implement ->choose_interface_config() for TC58TEG5DCLTA00
Implement this hook for the tc58teg5dclta00 NAND chip and stop setting ->default_timing_mode. Signed-off-by: Miquel Raynal <[email protected]> Reviewed-by: Boris Brezillon <[email protected]> Link: https://lore.kernel.org/linux-mtd/[email protected]
1 parent 26d014f commit 2f36bae

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

drivers/mtd/nand/raw/nand_toshiba.c

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -194,11 +194,21 @@ static void toshiba_nand_decode_id(struct nand_chip *chip)
194194
}
195195
}
196196

197+
static int
198+
tc58teg5dclta00_choose_interface_config(struct nand_chip *chip,
199+
struct nand_interface_config *iface)
200+
{
201+
onfi_fill_interface_config(chip, iface, NAND_SDR_IFACE, 5);
202+
203+
return nand_choose_best_sdr_timings(chip, iface, NULL);
204+
}
205+
197206
static int tc58teg5dclta00_init(struct nand_chip *chip)
198207
{
199208
struct mtd_info *mtd = nand_to_mtd(chip);
200209

201-
chip->onfi_timing_mode_default = 5;
210+
chip->ops.choose_interface_config =
211+
&tc58teg5dclta00_choose_interface_config;
202212
chip->options |= NAND_NEED_SCRAMBLING;
203213
mtd_set_pairing_scheme(mtd, &dist3_pairing_scheme);
204214

0 commit comments

Comments
 (0)