mirror of
https://xff.cz/git/u-boot/
synced 2025-09-01 16:52:14 +02:00
net/: sparse fixes
bootp.c:44:14: warning: symbol 'dhcp_state' was not declared. Should it be static?
bootp.c:45:15: warning: symbol 'dhcp_leasetime' was not declared. Should it be static?
bootp.c:46:10: warning: symbol 'NetDHCPServerIP' was not declared. Should it be static?
arp.c:30:17: warning: symbol 'NetArpWaitReplyIP' was not declared. Should it be static?
arp.c:37:16: warning: symbol 'NetArpTxPacket' was not declared. Should it be static?
arp.c:38:17: warning: symbol 'NetArpPacketBuf' was not declared. Should it be static?
atheros.c:33:19: warning: symbol 'AR8021_driver' was not declared. Should it be static?
net.c:183:7: warning: symbol 'PktBuf' was not declared. Should it be static?
net.c:159:21: warning: symbol 'net_state' was not declared. Should it be static?
ping.c:73:6: warning: symbol 'ping_start' was not declared. Should it be static?
ping.c:82:13: warning: symbol 'ping_receive' was not declared. Should it be static?
tftp.c:53:7: warning: symbol 'TftpRRQTimeoutMSecs' was not declared. Should it be static?
tftp.c:54:5: warning: symbol 'TftpRRQTimeoutCountMax' was not declared. Should it be static?
eth.c:125:19: warning: symbol 'eth_current' was not declared. Should it be static?
Note: in the ping.c fix, commit a36b12f95a
"net: Move PING out of net.c" mistakenly carried the ifdef CMD_PING
clause from when it was necessary to avoid warnings when it was embedded
in net.c.
Signed-off-by: Kim Phillips <kim.phillips@freescale.com>
This commit is contained in:
@@ -102,12 +102,13 @@ extern int eth_register(struct eth_device* dev);/* Register network device */
|
||||
extern int eth_unregister(struct eth_device *dev);/* Remove network device */
|
||||
extern void eth_try_another(int first_restart); /* Change the device */
|
||||
extern void eth_set_current(void); /* set nterface to ethcur var */
|
||||
|
||||
/* get the current device MAC */
|
||||
extern struct eth_device *eth_current;
|
||||
|
||||
static inline __attribute__((always_inline))
|
||||
struct eth_device *eth_get_dev(void)
|
||||
{
|
||||
extern struct eth_device *eth_current;
|
||||
|
||||
return eth_current;
|
||||
}
|
||||
extern struct eth_device *eth_get_dev_by_name(const char *devname);
|
||||
@@ -517,10 +518,10 @@ enum net_loop_state {
|
||||
NETLOOP_SUCCESS,
|
||||
NETLOOP_FAIL
|
||||
};
|
||||
extern enum net_loop_state net_state;
|
||||
|
||||
static inline void net_set_state(enum net_loop_state state)
|
||||
{
|
||||
extern enum net_loop_state net_state;
|
||||
|
||||
debug_cond(DEBUG_INT_STATE, "--- NetState set to %d\n", state);
|
||||
net_state = state;
|
||||
}
|
||||
|
Reference in New Issue
Block a user