From d9bec9f42ab34383737c8a94429aa02fe76d7946 Mon Sep 17 00:00:00 2001 From: Mike Frysinger Date: Sat, 18 Jul 2009 21:04:08 -0400 Subject: net: rename NetRxPkt to NetRxPacket The net code is mostly consistent in using 'Packet' rather than 'Pkt', so rename the minor detractor to follow suite. Signed-off-by: Mike Frysinger Signed-off-by: Ben Warren --- include/net.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'include') diff --git a/include/net.h b/include/net.h index 5a1d36e..88a9513 100644 --- a/include/net.h +++ b/include/net.h @@ -331,8 +331,8 @@ extern IPaddr_t NetOurIP; /* Our IP addr (0 = unknown) */ extern IPaddr_t NetServerIP; /* Server IP addr (0 = unknown) */ extern volatile uchar * NetTxPacket; /* THE transmit packet */ extern volatile uchar * NetRxPackets[PKTBUFSRX];/* Receive packets */ -extern volatile uchar * NetRxPkt; /* Current receive packet */ -extern int NetRxPktLen; /* Current rx packet length */ +extern volatile uchar * NetRxPacket; /* Current receive packet */ +extern int NetRxPacketLen; /* Current rx packet length */ extern unsigned NetIPID; /* IP ID (counting) */ extern uchar NetBcastAddr[6]; /* Ethernet boardcast address */ extern uchar NetEtherNullAddr[6]; -- cgit v1.1 From 1a32bf41881b5dbe3119cb77a33572b4d462cabf Mon Sep 17 00:00:00 2001 From: Robin Getz Date: Mon, 20 Jul 2009 14:53:54 -0400 Subject: Add DNS support On 04 Oct 2008 Pieter posted a dns implementation for U-Boot. http://www.mail-archive.com/u-boot-users@lists.sourceforge.net/msg10216.html > > DNS can be enabled by setting CFG_CMD_DNS. After performing a query, > the serverip environment var is updated. > > Probably there are some cosmetic issues with the patch. Unfortunatly I > do not have the time to correct these. So if anybody else likes DNS > support in U-Boot and has the time, feel free to patch it in the main tree. Here it is again - slightly modified & smaller: - update to 2009-06 (Pieter's patch was for U-Boot 1.2.0) - README.dns is added - syntax is changed (now takes a third option, the env var to store the result in) - add a random port() function in net.c - sort Makefile in ./net/Makefile - dns just returns unless a env var is given - run through checkpatch, and clean up style issues - remove packet from stack - cleaned up some comments - failure returns much faster (if server responds, don't wait for timeout) - use built in functions (memcpy) rather than byte copy. Signed-off-by: Robin Getz Signed-off-by: Pieter Voorthuijsen Signed-off-by: Ben Warren --- include/net.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'include') diff --git a/include/net.h b/include/net.h index 88a9513..4a03717 100644 --- a/include/net.h +++ b/include/net.h @@ -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 -- cgit v1.1 From 736fead8fdbf8a8407048bebc373cd551d01ec98 Mon Sep 17 00:00:00 2001 From: Ben Warren Date: Mon, 20 Jul 2009 22:01:11 -0700 Subject: Convert SMC911X Ethernet driver to CONFIG_NET_MULTI API All in-tree boards that use this controller have CONFIG_NET_MULTI added Also: - changed CONFIG_DRIVER_SMC911X* to CONFIG_SMC911X* - cleaned up line lengths - modified all boards that override weak function in this driver - added Signed-off-by: Ben Warren Tested-by: Mike Frysinger --- include/configs/ap325rxa.h | 7 ++++--- include/configs/bf548-ezkit.h | 7 ++++--- include/configs/cm-bf548.h | 7 ++++--- include/configs/imx31_litekit.h | 7 ++++--- include/configs/imx31_phycore.h | 7 ++++--- include/configs/mx31pdk.h | 7 ++++--- include/configs/omap3_evm.h | 7 ++++--- include/configs/rsk7203.h | 7 ++++--- include/configs/vct.h | 9 +++++---- include/netdev.h | 1 + 10 files changed, 38 insertions(+), 28 deletions(-) (limited to 'include') diff --git a/include/configs/ap325rxa.h b/include/configs/ap325rxa.h index 6f58a05..70dd47e 100644 --- a/include/configs/ap325rxa.h +++ b/include/configs/ap325rxa.h @@ -53,9 +53,10 @@ #undef CONFIG_SHOW_BOOT_PROGRESS /* SMC9118 */ -#define CONFIG_DRIVER_SMC911X 1 -#define CONFIG_DRIVER_SMC911X_32_BIT 1 -#define CONFIG_DRIVER_SMC911X_BASE 0xB6080000 +#define CONFIG_NET_MULTI +#define CONFIG_SMC911X 1 +#define CONFIG_SMC911X_32_BIT 1 +#define CONFIG_SMC911X_BASE 0xB6080000 /* MEMORY */ #define AP325RXA_SDRAM_BASE (0x88000000) diff --git a/include/configs/bf548-ezkit.h b/include/configs/bf548-ezkit.h index dbcd2af..5b9de16 100644 --- a/include/configs/bf548-ezkit.h +++ b/include/configs/bf548-ezkit.h @@ -69,9 +69,10 @@ * Network Settings */ #define ADI_CMDS_NETWORK 1 -#define CONFIG_DRIVER_SMC911X 1 -#define CONFIG_DRIVER_SMC911X_BASE 0x24000000 -#define CONFIG_DRIVER_SMC911X_16_BIT +#define CONFIG_NET_MULTI +#define CONFIG_SMC911X 1 +#define CONFIG_SMC911X_BASE 0x24000000 +#define CONFIG_SMC911X_16_BIT #define CONFIG_HOSTNAME bf548-ezkit /* Uncomment next line to use fixed MAC address */ /* #define CONFIG_ETHADDR 02:80:ad:20:31:e8 */ diff --git a/include/configs/cm-bf548.h b/include/configs/cm-bf548.h index 93c2239..b5cfc21 100644 --- a/include/configs/cm-bf548.h +++ b/include/configs/cm-bf548.h @@ -69,9 +69,10 @@ * Network Settings */ #define ADI_CMDS_NETWORK 1 -#define CONFIG_DRIVER_SMC911X 1 -#define CONFIG_DRIVER_SMC911X_BASE 0x24000000 -#define CONFIG_DRIVER_SMC911X_16_BIT +#define CONFIG_NET_MULTI +#define CONFIG_SMC911X 1 +#define CONFIG_SMC911X_BASE 0x24000000 +#define CONFIG_SMC911X_16_BIT #define CONFIG_HOSTNAME cm-bf548 /* Uncomment next line to use fixed MAC address */ /* #define CONFIG_ETHADDR 02:80:ad:24:31:91 */ diff --git a/include/configs/imx31_litekit.h b/include/configs/imx31_litekit.h index 74f54c0..6131008 100644 --- a/include/configs/imx31_litekit.h +++ b/include/configs/imx31_litekit.h @@ -104,9 +104,10 @@ "prg_uboot=tftpboot 0x80000000 u-boot-imx31_litekit.bin; protect off all; erase 0xa00d0000 0xa01effff; cp.b 0x80000000 0xa00d0000 $(filesize)\0" -#define CONFIG_DRIVER_SMC911X 1 -#define CONFIG_DRIVER_SMC911X_BASE (CS4_BASE + 0x00020000) -#define CONFIG_DRIVER_SMC911X_32_BIT 1 +#define CONFIG_NET_MULTI +#define CONFIG_SMC911X 1 +#define CONFIG_SMC911X_BASE (CS4_BASE + 0x00020000) +#define CONFIG_SMC911X_32_BIT 1 /* * Miscellaneous configurable options diff --git a/include/configs/imx31_phycore.h b/include/configs/imx31_phycore.h index cb42a7c..1dbafa0 100644 --- a/include/configs/imx31_phycore.h +++ b/include/configs/imx31_phycore.h @@ -106,9 +106,10 @@ "prg_jffs2=tftpboot 0x80000000 $(jffs2); erase 0xa01c0000 0xa1ffffff; cp.b 0x80000000 0xa01c0000 $(filesize)\0" -#define CONFIG_DRIVER_SMC911X 1 -#define CONFIG_DRIVER_SMC911X_BASE 0xa8000000 -#define CONFIG_DRIVER_SMC911X_32_BIT 1 +#define CONFIG_NET_MULTI +#define CONFIG_SMC911X 1 +#define CONFIG_SMC911X_BASE 0xa8000000 +#define CONFIG_SMC911X_32_BIT 1 /* * Miscellaneous configurable options diff --git a/include/configs/mx31pdk.h b/include/configs/mx31pdk.h index a4862c6..fb61432 100644 --- a/include/configs/mx31pdk.h +++ b/include/configs/mx31pdk.h @@ -106,9 +106,10 @@ "bootcmd_net=run bootargs_base bootargs_mtd bootargs_nfs; " \ "tftpboot 0x81000000 uImage-mx31; bootm\0" -#define CONFIG_DRIVER_SMC911X 1 -#define CONFIG_DRIVER_SMC911X_BASE 0xB6000000 -#define CONFIG_DRIVER_SMC911X_32_BIT 1 +#define CONFIG_NET_MULTI +#define CONFIG_SMC911X 1 +#define CONFIG_SMC911X_BASE 0xB6000000 +#define CONFIG_SMC911X_32_BIT 1 /* * Miscellaneous configurable options diff --git a/include/configs/omap3_evm.h b/include/configs/omap3_evm.h index 198c3d1..3d9d72c 100644 --- a/include/configs/omap3_evm.h +++ b/include/configs/omap3_evm.h @@ -302,9 +302,10 @@ extern unsigned int boot_flash_type; */ #if defined(CONFIG_CMD_NET) -#define CONFIG_DRIVER_SMC911X -#define CONFIG_DRIVER_SMC911X_32_BIT -#define CONFIG_DRIVER_SMC911X_BASE 0x2C000000 +#define CONFIG_NET_MULTI +#define CONFIG_SMC911X +#define CONFIG_SMC911X_32_BIT +#define CONFIG_SMC911X_BASE 0x2C000000 #endif /* (CONFIG_CMD_NET) */ diff --git a/include/configs/rsk7203.h b/include/configs/rsk7203.h index 36e4c01..9aa71b4 100644 --- a/include/configs/rsk7203.h +++ b/include/configs/rsk7203.h @@ -105,8 +105,9 @@ #define CONFIG_SYS_HZ (CONFIG_SYS_CLK_FREQ / CMT_CLK_DIVIDER) /* Network interface */ -#define CONFIG_DRIVER_SMC911X -#define CONFIG_DRIVER_SMC911X_16_BIT -#define CONFIG_DRIVER_SMC911X_BASE (0x24000000) +#define CONFIG_NET_MULTI +#define CONFIG_SMC911X +#define CONFIG_SMC911X_16_BIT +#define CONFIG_SMC911X_BASE (0x24000000) #endif /* __RSK7203_H */ diff --git a/include/configs/vct.h b/include/configs/vct.h index e72b504..20bf481 100644 --- a/include/configs/vct.h +++ b/include/configs/vct.h @@ -89,10 +89,11 @@ /* * SMSC91C11x Network Card */ -#define CONFIG_DRIVER_SMC911X -#define CONFIG_DRIVER_SMC911X_BASE 0x00000000 -#define CONFIG_DRIVER_SMC911X_32_BIT +#define CONFIG_SMC911X +#define CONFIG_SMC911X_BASE 0x00000000 +#define CONFIG_SMC911X_32_BIT #define CONFIG_NET_RETRY_COUNT 20 +#define CONFIG_NET_MULTI #endif /* @@ -342,7 +343,7 @@ int vct_gpio_get(int pin); #undef CONFIG_CMD_TERMINAL #undef CONFIG_CMD_USB -#undef CONFIG_DRIVER_SMC911X +#undef CONFIG_SMC911X #undef CONFIG_SOFT_I2C #undef CONFIG_SOURCE #undef CONFIG_SYS_LONGHELP diff --git a/include/netdev.h b/include/netdev.h index 17fdafb..d8056ab 100644 --- a/include/netdev.h +++ b/include/netdev.h @@ -71,6 +71,7 @@ int rtl8139_initialize(bd_t *bis); int rtl8169_initialize(bd_t *bis); int scc_initialize(bd_t *bis); int skge_initialize(bd_t *bis); +int smc911x_initialize(u8 dev_num, int base_addr); int tsi108_eth_initialize(bd_t *bis); int uec_initialize(int index); int uec_standard_init(bd_t *bis); -- cgit v1.1 From 0b23fb368d08c9669fac647971ff249c3f9fee8f Mon Sep 17 00:00:00 2001 From: Ilya Yanok Date: Tue, 21 Jul 2009 19:32:21 +0400 Subject: fec_mxc: driver for FEC ethernet controller on i.MX27 Signed-off-by: Ilya Yanok Signed-off-by: Ben Warren --- include/netdev.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include') diff --git a/include/netdev.h b/include/netdev.h index d8056ab..3e66586 100644 --- a/include/netdev.h +++ b/include/netdev.h @@ -50,6 +50,7 @@ int e1000_initialize(bd_t *bis); int eepro100_initialize(bd_t *bis); int eth_3com_initialize (bd_t * bis); int fec_initialize (bd_t *bis); +int fecmxc_initialize (bd_t *bis); int greth_initialize(bd_t *bis); void gt6426x_eth_initialize(bd_t *bis); int inca_switch_initialize(bd_t *bis); -- cgit v1.1