[PATCH 2/2] versatilepb: force net a 100Mpps

Jean-Christophe PLAGNIOL-VILLARD plagnioj at jcrosoft.com
Thu Sep 19 01:50:15 EDT 2013


Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj at jcrosoft.com>
---
 arch/arm/boards/versatile/versatilepb.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/arch/arm/boards/versatile/versatilepb.c b/arch/arm/boards/versatile/versatilepb.c
index 2eb7473..fa0585d 100644
--- a/arch/arm/boards/versatile/versatilepb.c
+++ b/arch/arm/boards/versatile/versatilepb.c
@@ -28,6 +28,7 @@
 #include <environment.h>
 #include <partition.h>
 #include <sizes.h>
+#include <linux/phy.h>
 
 static int vpb_console_init(void)
 {
@@ -44,6 +45,8 @@ static int vpb_mem_init(void)
 }
 mem_initcall(vpb_mem_init);
 
+static int phy_flags = PHYLIB_FORCE_100;
+
 static int vpb_devices_init(void)
 {
 	add_cfi_flash_device(DEVICE_ID_DYNAMIC, VERSATILE_FLASH_BASE, VERSATILE_FLASH_SIZE, 0);
@@ -52,7 +55,7 @@ static int vpb_devices_init(void)
 	devfs_add_partition("nor0", 0x40000, 0x20000, DEVFS_PARTITION_FIXED, "env0");
 
 	add_generic_device("smc91c111", DEVICE_ID_DYNAMIC, NULL, VERSATILE_ETH_BASE,
-			64 * 1024, IORESOURCE_MEM, NULL);
+			64 * 1024, IORESOURCE_MEM, &phy_flags);
 
 	armlinux_set_architecture(MACH_TYPE_VERSATILE_PB);
 	armlinux_set_bootparams((void *)(0x00000100));
-- 
1.8.4.rc1




More information about the barebox mailing list