0013-MTD-lantiq-xway-fix-invalid-operator.patch 816 B

123456789101112131415161718192021222324
  1. From 8e34da603f442624bb70e887d8f42064bb924224 Mon Sep 17 00:00:00 2001
  2. From: John Crispin <blogic@openwrt.org>
  3. Date: Sun, 28 Jul 2013 18:03:54 +0200
  4. Subject: [PATCH 13/36] MTD: lantiq: xway: fix invalid operator
  5. xway_read_byte should use a logic or and not an add operator when working out
  6. the nand address.
  7. Signed-off-by: John Crispin <blogic@openwrt.org>
  8. ---
  9. drivers/mtd/nand/xway_nand.c | 2 +-
  10. 1 file changed, 1 insertion(+), 1 deletion(-)
  11. --- a/drivers/mtd/nand/xway_nand.c
  12. +++ b/drivers/mtd/nand/xway_nand.c
  13. @@ -124,7 +124,7 @@ static unsigned char xway_read_byte(stru
  14. int ret;
  15. spin_lock_irqsave(&ebu_lock, flags);
  16. - ret = ltq_r8((void __iomem *)(nandaddr + NAND_READ_DATA));
  17. + ret = ltq_r8((void __iomem *)(nandaddr | NAND_READ_DATA));
  18. spin_unlock_irqrestore(&ebu_lock, flags);
  19. return ret;