svn commit: r204401 - user/jmallett/octeon/sys/mips/cavium/dev/rgmii
Juli Mallett
jmallett at FreeBSD.org
Sat Feb 27 06:28:23 UTC 2010
Author: jmallett
Date: Sat Feb 27 06:28:22 2010
New Revision: 204401
URL: http://svn.freebsd.org/changeset/base/204401
Log:
o) Since typestr is always NULL don't bother printing it.
o) Don't mask off the low byte of chipid -- some of the case statements are
unreachable if you do that. This fixes crashes on the CAM-0100 from trying
to enumerate a 4th port that isn't there.
Modified:
user/jmallett/octeon/sys/mips/cavium/dev/rgmii/octeon_rgmx.c
Modified: user/jmallett/octeon/sys/mips/cavium/dev/rgmii/octeon_rgmx.c
==============================================================================
--- user/jmallett/octeon/sys/mips/cavium/dev/rgmii/octeon_rgmx.c Sat Feb 27 05:55:04 2010 (r204400)
+++ user/jmallett/octeon/sys/mips/cavium/dev/rgmii/octeon_rgmx.c Sat Feb 27 06:28:22 2010 (r204401)
@@ -136,7 +136,9 @@ struct rgmx_softc_dev {
u_int idx;
u_char ieee[6];
+#if 0
char const * typestr; /* printable name of the interface. */
+#endif
u_short txb_size; /* size of TX buffer, in bytes */
/* Transmission buffer management. */
@@ -350,7 +352,9 @@ static int octeon_rgmx_init_ifnet (struc
ether_ifattach(sc->ifp, sc->ieee);
/* Print additional info when attached. */
+#if 0
device_printf(sc->sc_dev, "type %s, full duplex\n", sc->typestr);
+#endif
return (0);
}
@@ -2181,7 +2185,7 @@ static int octeon_has_4ports (void)
u_int chipid;
int retcode = 1;
- chipid = octeon_get_chipid() & 0xffffff00;
+ chipid = octeon_get_chipid();
switch (chipid) {
case OCTEON_CN31XX_CHIP:
More information about the svn-src-user
mailing list