Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/evbarm/awin Cubieboard2 uses GMAC with a 100Mbit PH...



details:   https://anonhg.NetBSD.org/src/rev/4211b0f9db8f
branches:  trunk
changeset: 333073:4211b0f9db8f
user:      jmcneill <jmcneill%NetBSD.org@localhost>
date:      Fri Oct 17 20:24:18 2014 +0000

description:
Cubieboard2 uses GMAC with a 100Mbit PHY. Set phy-type property to "mii" for awge

diffstat:

 sys/arch/evbarm/awin/awin_machdep.c |  14 ++++++++++++--
 1 files changed, 12 insertions(+), 2 deletions(-)

diffs (35 lines):

diff -r 8c055af7a24a -r 4211b0f9db8f sys/arch/evbarm/awin/awin_machdep.c
--- a/sys/arch/evbarm/awin/awin_machdep.c       Fri Oct 17 20:18:41 2014 +0000
+++ b/sys/arch/evbarm/awin/awin_machdep.c       Fri Oct 17 20:24:18 2014 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: awin_machdep.c,v 1.15 2014/10/12 14:04:52 jmcneill Exp $ */
+/*     $NetBSD: awin_machdep.c,v 1.16 2014/10/17 20:24:18 jmcneill Exp $ */
 
 /*
  * Machine dependent functions for kernel setup for TI OSK5912 board.
@@ -125,7 +125,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: awin_machdep.c,v 1.15 2014/10/12 14:04:52 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: awin_machdep.c,v 1.16 2014/10/17 20:24:18 jmcneill Exp $");
 
 #include "opt_machdep.h"
 #include "opt_ddb.h"
@@ -673,6 +673,16 @@
                return;
        }
 
+       if (device_is_a(self, "awge")) {
+#if AWIN_board == AWIN_cubieboard
+               if (awin_chip_id() == AWIN_CHIP_ID_A20) {
+                       /* Cubieboard2 uses GMAC with a 100Mbit PHY */
+                       prop_dictionary_set_cstring(dict, "phy-type", "mii");
+               }
+#endif
+               return;
+       }
+
        if (device_is_a(self, "com")) {
 #if NAWIN_FB > 0
                if (use_fb_console)



Home | Main Index | Thread Index | Old Index