Explorar o código

ARM: at91: fix NAND bus width decoding from system_rev

Make it is safe to assign the return value of this function
to u8/u16 variables.

Signed-off-by: Christian Hitz <christian.hitz@aizo.com>
Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
Christian Hitz %!s(int64=14) %!d(string=hai) anos
pai
achega
a5f70b6717
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      arch/arm/mach-at91/include/mach/system_rev.h

+ 1 - 1
arch/arm/mach-at91/include/mach/system_rev.h

@@ -19,7 +19,7 @@
 #define BOARD_HAVE_NAND_16BIT	(1 << 31)
 static inline int board_have_nand_16bit(void)
 {
-	return system_rev & BOARD_HAVE_NAND_16BIT;
+	return (system_rev & BOARD_HAVE_NAND_16BIT) ? 1 : 0;
 }
 
 #endif /* __ARCH_SYSTEM_REV_H__ */