X-Git-Url: https://git.librecmc.org/?a=blobdiff_plain;f=include%2Fnet.h;h=1c8ab12454b7e80de56eaaf8572f1fe3899e8957;hb=01471d538fb163f472a769f21267d7676c91267c;hp=88a951357168b0e57c05447bc1fb12a517e73560;hpb=d9bec9f42ab34383737c8a94429aa02fe76d7946;p=oweals%2Fu-boot.git diff --git a/include/net.h b/include/net.h index 88a9513571..1c8ab12454 100644 --- a/include/net.h +++ b/include/net.h @@ -119,10 +119,10 @@ extern struct eth_device *eth_get_dev(void); /* get the current device MAC */ extern struct eth_device *eth_get_dev_by_name(char *devname); /* get device */ extern struct eth_device *eth_get_dev_by_index(int index); /* get dev @ index */ extern int eth_get_dev_index (void); /* get the device index */ -extern void eth_set_enetaddr(int num, char* a); /* Set new MAC address */ extern void eth_parse_enetaddr(const char *addr, uchar *enetaddr); extern int eth_getenv_enetaddr(char *name, uchar *enetaddr); extern int eth_setenv_enetaddr(char *name, const uchar *enetaddr); +extern int eth_getenv_enetaddr_by_index(int index, uchar *enetaddr); extern int eth_init(bd_t *bis); /* Initialize the device */ extern int eth_send(volatile void *packet, int length); /* Send a packet */ @@ -361,6 +361,11 @@ typedef enum { BOOTP, RARP, ARP, TFTP, DHCP, PING, DNS, NFS, CDP, NETCONS, SNTP /* from net/net.c */ extern char BootFile[128]; /* Boot File name */ +#if defined(CONFIG_CMD_DNS) +extern char *NetDNSResolve; /* The host to resolve */ +extern char *NetDNSenvvar; /* the env var to put the ip into */ +#endif + #if defined(CONFIG_CMD_PING) extern IPaddr_t NetPingIP; /* the ip address to ping */ #endif @@ -512,6 +517,9 @@ extern ushort getenv_VLAN(char *); /* copy a filename (allow for "..." notation, limit length) */ extern void copy_filename (char *dst, char *src, int size); +/* get a random source port */ +extern unsigned int random_port(void); + /**********************************************************************/ #endif /* __NET_H__ */