Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit fde85cfd authored by Boris Brezillon's avatar Boris Brezillon
Browse files

mtd: nand: Fix nand_command_lp() for 8bits opcodes



8 bits opcodes should be followed by a single address cycle. Make the
2nd address cycle dependent of !nand_opcode_8bits(command).

Signed-off-by: default avatarBoris Brezillon <boris.brezillon@free-electrons.com>
parent 4796d865
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -745,6 +745,9 @@ static void nand_command_lp(struct mtd_info *mtd, unsigned int command,
				column >>= 1;
			chip->cmd_ctrl(mtd, column, ctrl);
			ctrl &= ~NAND_CTRL_CHANGE;

			/* Only ouput a single addr cycle for 8bits opcodes. */
			if (!nand_opcode_8bits(command))
				chip->cmd_ctrl(mtd, column >> 8, ctrl);
		}
		if (page_addr != -1) {