Skip to contentSkip to conversation

SAMSUNG: SMDKC100: Adds ethernet support.

PATCH Superseded Naveen Krishna Ch 3 participants 5 messages Feb 10, 2010

v2 of 7 Superseded Latest is v7 →

lore
Share & tools
lore
#0 lore raw

PATCH v2 3/3 SAMSUNG: SMDKC100: Adds ethernet support.

From: Naveen Krishna CH <[email protected]>

Add setup for ethernet on SMDKC100, allowing kernel/ramdisk to be loaded over tftp.

The preinit function will configure GPIO (GPK0CON) & SROMC to look for environment in SROM Bank 3.

Changes since v1:

1. Removed the CONFIG_BOOTP_* and Net config macros from board header file as per comments from Ben Warren.

Signed-off-by Naveen Krishna Ch <ch.naveen <at> samsung.com>
---
 board/samsung/smdkc100/smdkc100.c |   37 +++++++++++++++++++++++++++++++++++++
 include/configs/smdkc100.h        |   13 ++++++++++++-
 2 files changed, 49 insertions(+), 1 deletions(-)
board/samsung/smdkc100/smdkc100.c +37 -0
index 15a1a27..6e50f14 100644
@@ -23,10 +23,38 @@
  */
 
 #include <common.h>
+#include <asm/io.h>
+#include <asm/arch/mem.h>
+
+#define GPK0CON_OFFSET          0x2A0
+#define GPK0CON                 (S5PC100_GPIO_BASE + GPK0CON_OFFSET)
+
 DECLARE_GLOBAL_DATA_PTR;
 
+/*
+ * Miscellaneous platform dependent initialisations
+ */
+static void smc9115_pre_init(void)
+{
+	u32 tmp;
+	u32 smc_bw_conf;
+
+	/* gpio configuration */
+	tmp = __raw_readl(GPK0CON);
+	tmp &= ~(0xf << CONFIG_ENV_SROM_BANK * 4);
+	tmp |=  (0x2 << CONFIG_ENV_SROM_BANK * 4);
+	__raw_writel(tmp, GPK0CON);
+
+	/* Ethernet needs bus width of 16 bits */
+	smc_bw_conf = SROM_DATA16_WIDTH(CONFIG_ENV_SROM_BANK);
+
+	/* Select and configure the SROMC bank */
+	config_sromc(CONFIG_ENV_SROM_BANK, smc_bw_conf, SMC_BC_X_CON);
+}
+
 int board_init(void)
 {
+	smc9115_pre_init();
 	gd->bd->bi_arch_number = MACH_TYPE_SMDKC100;
 	gd->bd->bi_boot_params = PHYS_SDRAM_1 + 0x100;
 
@@ -49,3 +77,12 @@ int checkboard(void)
 	return 0;
 }
 #endif
+
+int board_eth_init(bd_t *bis)
+{
+	int rc = 0;
+#ifdef CONFIG_SMC911X
+	rc = smc911x_initialize(0, CONFIG_SMC911X_BASE);
+#endif
+	return rc;
+}
include/configs/smdkc100.h +12 -1
index a8ba052..eceb93f 100644
@@ -83,7 +83,7 @@
 #undef CONFIG_CMD_FLASH
 #undef CONFIG_CMD_IMLS
 #undef CONFIG_CMD_NAND
-#undef CONFIG_CMD_NET
+#define CONFIG_CMD_NET		/* bootp, tftpboot, rarpboot */
 
 #define CONFIG_CMD_CACHE
 #define CONFIG_CMD_REGINFO
@@ -235,4 +235,15 @@
 
 #define CONFIG_DOS_PARTITION		1
 
+/*
+ * Ethernet Contoller driver
+ */
+#ifdef CONFIG_CMD_NET
+#define CONFIG_NET_MULTI
+#define CONFIG_SMC911X   	1	/* we have a SMC9115 on-board	*/
+#define CONFIG_SMC911X_16_BIT	1	/* SMC911X_16_BIT Mode		*/
+#define CONFIG_SMC911X_BASE	0x98800300	/* SMC911X Drive Base	*/
+#define CONFIG_ENV_SROM_BANK	3	/* Select SROM Bank-3 for Ethernet*/
+#endif /* CONFIG_CMD_NET */
+
 #endif	/* __CONFIG_H */
Signature · 1 line
1.6.6
#1 lore raw

PATCH v2 3/3 SAMSUNG: SMDKC100: Adds ethernet support.

Dear Naveen Krishna Ch,

Quoted 5 lines · Naveen Krishna Ch

From: Naveen Krishna CH <[email protected]>

Add setup for ethernet on SMDKC100, allowing kernel/ramdisk to be loaded over tftp.

Quoted 7 lines

The preinit function will configure GPIO (GPK0CON) & SROMC to look for environment in SROM Bank 3.

Changes since v1:

1. Removed the CONFIG_BOOTP_* and Net config macros from board header file ? as per comments from Ben Warren.

please move this change log under the --- line.
And if you send next version patch, you must send all of your patch series.

Quoted 26 lines
Signed-off-by Naveen Krishna Ch <ch.naveen <at> samsung.com>

---
?board/samsung/smdkc100/smdkc100.c | ? 37 +++++++++++++++++++++++++++++++++++++ ?include/configs/smdkc100.h ? ? ? ?| ? 13 ++++++++++++-
?2 files changed, 49 insertions(+), 1 deletions(-)

board/samsung/smdkc100/smdkc100.c +0 -0
index 15a1a27..6e50f14 100644
@@ -23,10 +23,38 @@

?*/

?#include <common.h>

board/samsung/smdkc100/smdkc100.c +6 -0
+#include <asm/io.h>
+#include <asm/arch/mem.h>
+
+#define GPK0CON_OFFSET ? ? ? ? ?0x2A0
+#define GPK0CON ? ? ? ? ? ? ? ? (S5PC100_GPIO_BASE + GPK0CON_OFFSET)
+

?DECLARE_GLOBAL_DATA_PTR;

board/samsung/smdkc100/smdkc100.c +3 -0
+/*
+ * Miscellaneous platform dependent initialisations
+ */

board/samsung/smdkc100/smdkc100.c

Quoted 10 lines
board/samsung/smdkc100/smdkc100.c +10 -0
+static void smc9115_pre_init(void)
+{
+ ? ? ? u32 tmp;
+ ? ? ? u32 smc_bw_conf;
+
+ ? ? ? /* gpio configuration */
+ ? ? ? tmp = __raw_readl(GPK0CON);
+ ? ? ? tmp &= ~(0xf << CONFIG_ENV_SROM_BANK * 4);
+ ? ? ? tmp |= ?(0x2 << CONFIG_ENV_SROM_BANK * 4);
+ ? ? ? __raw_writel(tmp, GPK0CON);

NAK.
Please use the structure (see gpio.h)

Quoted 59 lines
board/samsung/smdkc100/smdkc100.c +8 -0
+
+ ? ? ? /* Ethernet needs bus width of 16 bits */
+ ? ? ? smc_bw_conf = SROM_DATA16_WIDTH(CONFIG_ENV_SROM_BANK);
+
+ ? ? ? /* Select and configure the SROMC bank */
+ ? ? ? config_sromc(CONFIG_ENV_SROM_BANK, smc_bw_conf, SMC_BC_X_CON);
+}
+

?int board_init(void)
?{
+ ? ? ? smc9115_pre_init();
? ? ? ?gd->bd->bi_arch_number = MACH_TYPE_SMDKC100; ? ? ? ?gd->bd->bi_boot_params = PHYS_SDRAM_1 + 0x100;

board/samsung/smdkc100/smdkc100.c +0 -0
@@ -49,3 +77,12 @@ int checkboard(void)
 ? ? ? ?return 0;
 ?}

?#endif

board/samsung/smdkc100/smdkc100.c +9 -0
+
+int board_eth_init(bd_t *bis)
+{
+ ? ? ? int rc = 0;
+#ifdef CONFIG_SMC911X
+ ? ? ? rc = smc911x_initialize(0, CONFIG_SMC911X_BASE);
+#endif
+ ? ? ? return rc;
+}
include/configs/smdkc100.h +0 -0
index a8ba052..eceb93f 100644
@@ -83,7 +83,7 @@

?#undef CONFIG_CMD_FLASH
?#undef CONFIG_CMD_IMLS
?#undef CONFIG_CMD_NAND

include/configs/smdkc100.h +1 -1
-#undef CONFIG_CMD_NET
+#define CONFIG_CMD_NET ? ? ? ? /* bootp, tftpboot, rarpboot */

?#define CONFIG_CMD_CACHE
?#define CONFIG_CMD_REGINFO

include/configs/smdkc100.h +0 -0
@@ -235,4 +235,15 @@
 

?#define CONFIG_DOS_PARTITION ? ? ? ? ? 1

include/configs/smdkc100.h +11 -0
+/*
+ * Ethernet Contoller driver
+ */
+#ifdef CONFIG_CMD_NET
+#define CONFIG_NET_MULTI
+#define CONFIG_SMC911X ? ? ? ? 1 ? ? ? /* we have a SMC9115 on-board ? */
+#define CONFIG_SMC911X_16_BIT ?1 ? ? ? /* SMC911X_16_BIT Mode ? ? ? ? ?*/
+#define CONFIG_SMC911X_BASE ? ?0x98800300 ? ? ?/* SMC911X Drive Base ? */
+#define CONFIG_ENV_SROM_BANK ? 3 ? ? ? /* Select SROM Bank-3 for Ethernet*/
+#endif /* CONFIG_CMD_NET */
+

?#endif /* __CONFIG_H */
--
1.6.6

Quoted 5 lines

_______________________________________________
U-Boot mailing list
U-Boot at lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Thanks
Minkyu Kang

Signature · 2 lines
from. prom.
www.promsoft.net
#2 lore raw

PATCH v2 3/3 SAMSUNG: SMDKC100: Adds ethernet support.

Dear Naveen Krishna Ch,

Quoted 59 lines · Minkyu Kang

Dear Naveen Krishna Ch,

Quoted 5 lines · Naveen Krishna Ch

From: Naveen Krishna CH <[email protected]>

Add setup for ethernet on SMDKC100, allowing kernel/ramdisk to be loaded over tftp.

Quoted 7 lines

The preinit function will configure GPIO (GPK0CON) & SROMC to look for environment in SROM Bank 3.

Changes since v1:

1. Removed the CONFIG_BOOTP_* and Net config macros from board header file ? as per comments from Ben Warren.

please move this change log under the --- line.
And if you send next version patch, you must send all of your patch series.

Quoted 26 lines
Signed-off-by Naveen Krishna Ch <ch.naveen <at> samsung.com>

---
?board/samsung/smdkc100/smdkc100.c | ? 37 +++++++++++++++++++++++++++++++++++++ ?include/configs/smdkc100.h ? ? ? ?| ? 13 ++++++++++++-
?2 files changed, 49 insertions(+), 1 deletions(-)

board/samsung/smdkc100/smdkc100.c +0 -0
index 15a1a27..6e50f14 100644
@@ -23,10 +23,38 @@

?*/

?#include <common.h>

board/samsung/smdkc100/smdkc100.c +6 -0
+#include <asm/io.h>
+#include <asm/arch/mem.h>
+
+#define GPK0CON_OFFSET ? ? ? ? ?0x2A0
+#define GPK0CON ? ? ? ? ? ? ? ? (S5PC100_GPIO_BASE + GPK0CON_OFFSET)
+

?DECLARE_GLOBAL_DATA_PTR;

board/samsung/smdkc100/smdkc100.c +3 -0
+/*
+ * Miscellaneous platform dependent initialisations
+ */

board/samsung/smdkc100/smdkc100.c

Quoted 10 lines
board/samsung/smdkc100/smdkc100.c +10 -0
+static void smc9115_pre_init(void)
+{
+ ? ? ? u32 tmp;
+ ? ? ? u32 smc_bw_conf;
+
+ ? ? ? /* gpio configuration */
+ ? ? ? tmp = __raw_readl(GPK0CON);
+ ? ? ? tmp &= ~(0xf << CONFIG_ENV_SROM_BANK * 4);
+ ? ? ? tmp |= ?(0x2 << CONFIG_ENV_SROM_BANK * 4);
+ ? ? ? __raw_writel(tmp, GPK0CON);

NAK.
Please use the structure (see gpio.h)

Quoted 7 lines

board/samsung/smdkc100/smdkc100.c

Quoted 7 lines
board/samsung/smdkc100/smdkc100.c +7 -0
+
+ ? ? ? /* Ethernet needs bus width of 16 bits */
+ ? ? ? smc_bw_conf = SROM_DATA16_WIDTH(CONFIG_ENV_SROM_BANK);
+
+ ? ? ? /* Select and configure the SROMC bank */
+ ? ? ? config_sromc(CONFIG_ENV_SROM_BANK, smc_bw_conf, SMC_BC_X_CON);
+}

sorry, one more thing
I think smc_bw_conf is unnecessary.
please do it in config_sromc.

Quoted 52 lines
Quoted 52 lines

+
?int board_init(void)
?{
+ ? ? ? smc9115_pre_init();
? ? ? ?gd->bd->bi_arch_number = MACH_TYPE_SMDKC100; ? ? ? ?gd->bd->bi_boot_params = PHYS_SDRAM_1 + 0x100;

board/samsung/smdkc100/smdkc100.c +0 -0
@@ -49,3 +77,12 @@ int checkboard(void)
 ? ? ? ?return 0;
 ?}

?#endif

board/samsung/smdkc100/smdkc100.c +9 -0
+
+int board_eth_init(bd_t *bis)
+{
+ ? ? ? int rc = 0;
+#ifdef CONFIG_SMC911X
+ ? ? ? rc = smc911x_initialize(0, CONFIG_SMC911X_BASE);
+#endif
+ ? ? ? return rc;
+}
include/configs/smdkc100.h +0 -0
index a8ba052..eceb93f 100644
@@ -83,7 +83,7 @@

?#undef CONFIG_CMD_FLASH
?#undef CONFIG_CMD_IMLS
?#undef CONFIG_CMD_NAND

include/configs/smdkc100.h +1 -1
-#undef CONFIG_CMD_NET
+#define CONFIG_CMD_NET ? ? ? ? /* bootp, tftpboot, rarpboot */

?#define CONFIG_CMD_CACHE
?#define CONFIG_CMD_REGINFO

include/configs/smdkc100.h +0 -0
@@ -235,4 +235,15 @@
 

?#define CONFIG_DOS_PARTITION ? ? ? ? ? 1

include/configs/smdkc100.h +11 -0
+/*
+ * Ethernet Contoller driver
+ */
+#ifdef CONFIG_CMD_NET
+#define CONFIG_NET_MULTI
+#define CONFIG_SMC911X ? ? ? ? 1 ? ? ? /* we have a SMC9115 on-board ? */
+#define CONFIG_SMC911X_16_BIT ?1 ? ? ? /* SMC911X_16_BIT Mode ? ? ? ? ?*/
+#define CONFIG_SMC911X_BASE ? ?0x98800300 ? ? ?/* SMC911X Drive Base ? */
+#define CONFIG_ENV_SROM_BANK ? 3 ? ? ? /* Select SROM Bank-3 for Ethernet*/
+#endif /* CONFIG_CMD_NET */
+

?#endif /* __CONFIG_H */
--
1.6.6

Quoted 12 lines
Quoted 5 lines

_______________________________________________
U-Boot mailing list
U-Boot at lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Thanks
Minkyu Kang
--
from. prom.
www.promsoft.net

Thanks.
Minkyu Kang

Signature · 2 lines
from. prom.
www.promsoft.net
#3 lore raw

PATCH v2 3/3 SAMSUNG: SMDKC100: Adds ethernet support.

Hi kang,

Quoted 67 lines · Minkyu Kang

Dear Naveen Krishna Ch,

Quoted 3 lines · Minkyu Kang

Dear Naveen Krishna Ch,

On 10 February 2010 14:10, Naveen Krishna Ch <[email protected]>

Quoted 11 lines · wrote:
Quoted 11 lines

From: Naveen Krishna CH <[email protected]>

Add setup for ethernet on SMDKC100, allowing kernel/ramdisk to be loaded over tftp.

The preinit function will configure GPIO (GPK0CON) & SROMC to look for environment in SROM Bank 3.

Changes since v1:

1. Removed the CONFIG_BOOTP_* and Net config macros from board header

file

Quoted 4 lines
Quoted 1 line

as per comments from Ben Warren.

please move this change log under the --- line.
And if you send next version patch, you must send all of your patch

series.

Quoted 5 lines
Quoted 5 lines
Signed-off-by Naveen Krishna Ch <ch.naveen <at> samsung.com>
---
 board/samsung/smdkc100/smdkc100.c |   37

+++++++++++++++++++++++++++++++++++++

Quoted 4 lines

Review

Quoted 4 lines
 include/configs/smdkc100.h        |   13 ++++++++++++-
 2 files changed, 49 insertions(+), 1 deletions(-)
(quoted diff) +0 -0

b/board/samsung/smdkc100/smdkc100.c

Quoted 32 lines
Quoted 18 lines

index 15a1a27..6e50f14 100644

board/samsung/smdkc100/smdkc100.c +9 -0
@@ -23,10 +23,38 @@
 */
 
 #include <common.h>
+#include <asm/io.h>
+#include <asm/arch/mem.h>
+
+#define GPK0CON_OFFSET          0x2A0
+#define GPK0CON                 (S5PC100_GPIO_BASE + GPK0CON_OFFSET)
+
 DECLARE_GLOBAL_DATA_PTR;
 
+/*
+ * Miscellaneous platform dependent initialisations
+ */

board/samsung/smdkc100/smdkc100.c line 46

Quoted 10 lines
board/samsung/smdkc100/smdkc100.c +10 -0
+static void smc9115_pre_init(void)
+{
+       u32 tmp;
+       u32 smc_bw_conf;
+
+       /* gpio configuration */
+       tmp = __raw_readl(GPK0CON);
+       tmp &= ~(0xf << CONFIG_ENV_SROM_BANK * 4);
+       tmp |=  (0x2 << CONFIG_ENV_SROM_BANK * 4);
+       __raw_writel(tmp, GPK0CON);

NAK.
Please use the structure (see gpio.h)

Quoted 11 lines
Quoted 7 lines

board/samsung/smdkc100/smdkc100.c line 53

Quoted 7 lines
board/samsung/smdkc100/smdkc100.c +7 -0
+
+       /* Ethernet needs bus width of 16 bits */
+       smc_bw_conf = SROM_DATA16_WIDTH(CONFIG_ENV_SROM_BANK);
+
+       /* Select and configure the SROMC bank */
+       config_sromc(CONFIG_ENV_SROM_BANK, smc_bw_conf, SMC_BC_X_CON);
+}

sorry, one more thing
I think smc_bw_conf is unnecessary.
please do it in config_sromc.

The config_sromc() is a dumb/generic function which takes the configuration values for BandWidth and BankControl register and the SROM Bank number and accordingly programs the registers.
So, its better the caller send the value to be configured.

Quoted 81 lines
Quoted 37 lines
Quoted 37 lines
board/samsung/smdkc100/smdkc100.c +11 -0
+
 int board_init(void)
 {
+       smc9115_pre_init();
       gd->bd->bi_arch_number = MACH_TYPE_SMDKC100;
       gd->bd->bi_boot_params = PHYS_SDRAM_1 + 0x100;
 
@@ -49,3 +77,12 @@ int checkboard(void)
       return 0;
 }
 #endif
+
+int board_eth_init(bd_t *bis)
+{
+       int rc = 0;
+#ifdef CONFIG_SMC911X
+       rc = smc911x_initialize(0, CONFIG_SMC911X_BASE);
+#endif
+       return rc;
+}
include/configs/smdkc100.h +1 -1
index a8ba052..eceb93f 100644
@@ -83,7 +83,7 @@
 #undef CONFIG_CMD_FLASH
 #undef CONFIG_CMD_IMLS
 #undef CONFIG_CMD_NAND
-#undef CONFIG_CMD_NET
+#define CONFIG_CMD_NET         /* bootp, tftpboot, rarpboot */
 
 #define CONFIG_CMD_CACHE
 #define CONFIG_CMD_REGINFO
@@ -235,4 +235,15 @@
 
Quoted 8 lines

include/configs/smdkc100.h

Quoted 8 lines
include/configs/smdkc100.h +6 -0
 #define CONFIG_DOS_PARTITION           1
 
+/*
+ * Ethernet Contoller driver
+ */
+#ifdef CONFIG_CMD_NET
+#define CONFIG_NET_MULTI
+#define CONFIG_SMC911X         1       /* we have a SMC9115 on-board

*/

Quoted 1 line

include/configs/smdkc100.h line 244

Quoted 1 line
include/configs/smdkc100.h +1 -0
+#define CONFIG_SMC911X_16_BIT  1       /* SMC911X_16_BIT Mode

*/

Quoted 1 line

include/configs/smdkc100.h line 245

Quoted 1 line
include/configs/smdkc100.h +1 -0
+#define CONFIG_SMC911X_BASE    0x98800300      /* SMC911X Drive Base

*/

Quoted 1 line

include/configs/smdkc100.h line 246

Quoted 1 line
include/configs/smdkc100.h +1 -0
+#define CONFIG_ENV_SROM_BANK   3       /* Select SROM Bank-3 for

Ethernet*/

Quoted 6 lines
Quoted 6 lines
include/configs/smdkc100.h +2 -1
+#endif /* CONFIG_CMD_NET */
+
 #endif /* __CONFIG_H */
--

1.6.6

Quoted 12 lines
Quoted 5 lines

_______________________________________________
U-Boot mailing list
U-Boot at lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Thanks
Minkyu Kang
--
from. prom.
www.promsoft.net

Thanks.
Minkyu Kang
--
from. prom.
www.promsoft.net
_______________________________________________
U-Boot mailing list
U-Boot at lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Signature · 2 lines
Shine bright,
(: Naveen Krishna Ch :)
#4 lore raw

PATCH v2 3/3 SAMSUNG: SMDKC100: Adds ethernet support.

In reply to Minkyu Kang

Hi Kang,

Quoted 12 lines · Minkyu Kang

Dear Naveen Krishna Ch,

Quoted 8 lines · Naveen Krishna Ch

From: Naveen Krishna CH <[email protected]>

Add setup for ethernet on SMDKC100, allowing kernel/ramdisk to be loaded over tftp.

The preinit function will configure GPIO (GPK0CON) & SROMC to look for environment in SROM Bank 3.

Quoted 9 lines
Quoted 3 lines

Changes since v1:

1. Removed the CONFIG_BOOTP_* and Net config macros from board header

file

Quoted 1 line

as per comments from Ben Warren.

please move this change log under the --- line.
And if you send next version patch, you must send all of your patch series.

My Bad i will change it

Quoted 26 lines
Quoted 5 lines
Signed-off-by Naveen Krishna Ch <ch.naveen <at> samsung.com>
---
 board/samsung/smdkc100/smdkc100.c |   37

+++++++++++++++++++++++++++++++++++++

Review

Quoted 4 lines
 include/configs/smdkc100.h        |   13 ++++++++++++-
 2 files changed, 49 insertions(+), 1 deletions(-)
(quoted diff) +0 -0

b/board/samsung/smdkc100/smdkc100.c

Quoted 15 lines

index 15a1a27..6e50f14 100644

board/samsung/smdkc100/smdkc100.c +6 -0
@@ -23,10 +23,38 @@
 */
 
 #include <common.h>
+#include <asm/io.h>
+#include <asm/arch/mem.h>
+
+#define GPK0CON_OFFSET          0x2A0
+#define GPK0CON                 (S5PC100_GPIO_BASE + GPK0CON_OFFSET)
+
 DECLARE_GLOBAL_DATA_PTR;
 
Quoted 17 lines

board/samsung/smdkc100/smdkc100.c line 46

Quoted 13 lines
board/samsung/smdkc100/smdkc100.c +13 -0
+/*
+ * Miscellaneous platform dependent initialisations
+ */
+static void smc9115_pre_init(void)
+{
+       u32 tmp;
+       u32 smc_bw_conf;
+
+       /* gpio configuration */
+       tmp = __raw_readl(GPK0CON);
+       tmp &= ~(0xf << CONFIG_ENV_SROM_BANK * 4);
+       tmp |=  (0x2 << CONFIG_ENV_SROM_BANK * 4);
+       __raw_writel(tmp, GPK0CON);

NAK.
Please use the structure (see gpio.h)

I wil resend the patches V2.

Quoted 80 lines
Quoted 42 lines
board/samsung/smdkc100/smdkc100.c +18 -0
+
+       /* Ethernet needs bus width of 16 bits */
+       smc_bw_conf = SROM_DATA16_WIDTH(CONFIG_ENV_SROM_BANK);
+
+       /* Select and configure the SROMC bank */
+       config_sromc(CONFIG_ENV_SROM_BANK, smc_bw_conf, SMC_BC_X_CON);
+}
+
 int board_init(void)
 {
+       smc9115_pre_init();
       gd->bd->bi_arch_number = MACH_TYPE_SMDKC100;
       gd->bd->bi_boot_params = PHYS_SDRAM_1 + 0x100;
 
@@ -49,3 +77,12 @@ int checkboard(void)
       return 0;
 }
 #endif
+
+int board_eth_init(bd_t *bis)
+{
+       int rc = 0;
+#ifdef CONFIG_SMC911X
+       rc = smc911x_initialize(0, CONFIG_SMC911X_BASE);
+#endif
+       return rc;
+}
include/configs/smdkc100.h +1 -1
index a8ba052..eceb93f 100644
@@ -83,7 +83,7 @@
 #undef CONFIG_CMD_FLASH
 #undef CONFIG_CMD_IMLS
 #undef CONFIG_CMD_NAND
-#undef CONFIG_CMD_NET
+#define CONFIG_CMD_NET         /* bootp, tftpboot, rarpboot */
 
 #define CONFIG_CMD_CACHE
 #define CONFIG_CMD_REGINFO

include/configs/smdkc100.h line 243

Quoted 9 lines
include/configs/smdkc100.h +6 -0
@@ -235,4 +235,15 @@
 
 #define CONFIG_DOS_PARTITION           1
 
+/*
+ * Ethernet Contoller driver
+ */
+#ifdef CONFIG_CMD_NET
+#define CONFIG_NET_MULTI
+#define CONFIG_SMC911X         1       /* we have a SMC9115 on-board

*/

include/configs/smdkc100.h line 244

Quoted 1 line
include/configs/smdkc100.h +1 -0
+#define CONFIG_SMC911X_16_BIT  1       /* SMC911X_16_BIT Mode

*/

include/configs/smdkc100.h line 245

Quoted 1 line
include/configs/smdkc100.h +1 -0
+#define CONFIG_SMC911X_BASE    0x98800300      /* SMC911X Drive Base

*/

include/configs/smdkc100.h line 246

Quoted 1 line
include/configs/smdkc100.h +1 -0
+#define CONFIG_ENV_SROM_BANK   3       /* Select SROM Bank-3 for

Ethernet*/

Quoted 11 lines
include/configs/smdkc100.h +2 -1
+#endif /* CONFIG_CMD_NET */
+
 #endif /* __CONFIG_H */
--

1.6.6

_______________________________________________
U-Boot mailing list
U-Boot at lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Thanks
Minkyu Kang
--
from. prom.
www.promsoft.net
_______________________________________________
U-Boot mailing list
U-Boot at lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Signature · 2 lines
Shine bright,
(: Naveen Krishna Ch :)