PERFORCE change 109289 for review
Sam Leffler
sam at FreeBSD.org
Sun Nov 5 17:32:43 UTC 2006
http://perforce.freebsd.org/chv.cgi?CH=109289
Change 109289 by sam at sam_ebb on 2006/11/05 17:32:08
o inherit initial debug setting from tunable (as intended)
o use device_printf instead of if_printf so debug msgs
prior to ifp setup don't crash
Affected files ...
.. //depot/projects/arm/src/sys/arm/xscale/ixp425/if_npe.c#2 edit
Differences ...
==== //depot/projects/arm/src/sys/arm/xscale/ixp425/if_npe.c#2 (text+ko) ====
@@ -194,10 +194,10 @@
0, "IXP425 NPE network interface debug msgs");
TUNABLE_INT("debug.npe", &npe_debug);
#define DPRINTF(sc, fmt, ...) do { \
- if (sc->debug) if_printf(sc->sc_ifp, fmt, __VA_ARGS__); \
+ if (sc->debug) device_printf(sc->sc_dev, fmt, __VA_ARGS__); \
} while (0)
#define DPRINTFn(n, sc, fmt, ...) do { \
- if (sc->debug >= n) if_printf(sc->sc_ifp, fmt, __VA_ARGS__); \
+ if (sc->debug >= n) device_printf(sc->sc_dev, fmt, __VA_ARGS__);\
} while (0)
static int
@@ -229,6 +229,7 @@
sc->sc_iot = sa->sc_iot;
NPE_LOCK_INIT(sc);
callout_init_mtx(&sc->tick_ch, &sc->sc_mtx, 0);
+ sc->debug = npe_debug;
sc->sc_npe = ixpnpe_attach(dev);
if (sc->sc_npe == NULL) {
More information about the p4-projects
mailing list