*/
static int nand_setup_data_interface(struct nand_chip *chip, int chipnr)
{
- u8 tmode_param[ONFI_SUBFEATURE_PARAM_LEN] = {
- chip->onfi_timing_mode_default,
- };
+ u8 mode = chip->data_interface.timings.mode;
+ u8 tmode_param[ONFI_SUBFEATURE_PARAM_LEN] = { mode, };
int ret;
if (!nand_has_setup_data_iface(chip))
if (ret)
goto err_reset_chip;
- if (tmode_param[0] != chip->onfi_timing_mode_default) {
+ if (tmode_param[0] != mode) {
pr_warn("timing mode %d not acknowledged by the NAND chip\n",
- chip->onfi_timing_mode_default);
+ mode);
goto err_reset_chip;
}