]> git.sur5r.net Git - u-boot/commitdiff
net: Use int instead of u8 for boolean flag
authorJoe Hershberger <joe.hershberger@ni.com>
Sun, 22 Mar 2015 22:09:05 +0000 (17:09 -0500)
committerSimon Glass <sjg@chromium.org>
Sat, 18 Apr 2015 17:11:11 +0000 (11:11 -0600)
On some archs masking the parameter is inefficient, so don't use u8.

Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
Reported-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Simon Glass <sjg@chromium.org>
include/net.h
net/eth.c

index df86176efe9a8c0763c841fe7c6e6a160aef807b..bcf396a4ebabee997e1e39d963253e2cd4f88c1b 100644 (file)
@@ -178,7 +178,7 @@ void eth_halt(void);                        /* stop SCC */
 const char *eth_get_name(void);                /* get name of current device */
 
 #ifdef CONFIG_MCAST_TFTP
-int eth_mcast_join(IPaddr_t mcast_addr, u8 join);
+int eth_mcast_join(IPaddr_t mcast_addr, int join);
 u32 ether_crc(size_t len, unsigned char const *p);
 #endif
 
index 9ad15cd8a33cfa196bd45ca11e7976e09612742e..b86994e9eb546aa50a285dea9aaba6e8dfa17af0 100644 (file)
--- a/net/eth.c
+++ b/net/eth.c
@@ -321,7 +321,7 @@ int eth_initialize(bd_t *bis)
  * mcast_addr: multicast ipaddr from which multicast Mac is made
  * join: 1=join, 0=leave.
  */
-int eth_mcast_join(IPaddr_t mcast_ip, u8 join)
+int eth_mcast_join(IPaddr_t mcast_ip, int join)
 {
        u8 mcast_mac[6];
        if (!eth_current || !eth_current->mcast)