1 --- a/drivers/mtd/nand/xway_nand.c
2 +++ b/drivers/mtd/nand/xway_nand.c
3 @@ -80,13 +80,16 @@ static void xway_reset_chip(struct nand_
5 static void xway_select_chip(struct mtd_info *mtd, int chip)
7 + static unsigned long csflags;
11 ltq_ebu_w32_mask(NAND_CON_CE, 0, EBU_NAND_CON);
12 ltq_ebu_w32_mask(NAND_CON_NANDM, 0, EBU_NAND_CON);
13 + spin_unlock_irqrestore(&ebu_lock, csflags);
16 + spin_lock_irqsave(&ebu_lock, csflags);
17 ltq_ebu_w32_mask(0, NAND_CON_NANDM, EBU_NAND_CON);
18 ltq_ebu_w32_mask(0, NAND_CON_CE, EBU_NAND_CON);