[U-Boot] [PATCH] smc91111_eeprom: fix compile warning

Ben Warren biggerbadderben at gmail.com
Mon Nov 9 22:19:58 CET 2009


smc91111_eeprom.c:278: warning: suggest parentheses around + or - in operand
smc91111_eeprom.c:281: warning: suggest parentheses around + or - in operand

Signed-off-by: Ben Warren <biggerbadderben at gmail.com>
---
 examples/standalone/smc91111_eeprom.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/examples/standalone/smc91111_eeprom.c b/examples/standalone/smc91111_eeprom.c
index 89afc87..345b1ab 100644
--- a/examples/standalone/smc91111_eeprom.c
+++ b/examples/standalone/smc91111_eeprom.c
@@ -275,10 +275,10 @@ void print_macaddr (struct eth_device *dev)
 	printf ("Current MAC Address in SMSC91111 ");
 	SMC_SELECT_BANK (dev, 1);
 	for (i = 0; i < 5; i++) {
-		printf ("%02x:", SMC_inb (dev, ADDR0_REG + i));
+		printf ("%02x:", SMC_inb (dev, (ADDR0_REG + i)));
 	}
 
-	printf ("%02x\n", SMC_inb (dev, ADDR0_REG + 5));
+	printf ("%02x\n", SMC_inb (dev, (ADDR0_REG + 5)));
 
 	i = 0;
 	for (j = 0x20; j < 0x23; j++) {
-- 
1.6.0.4



More information about the U-Boot mailing list