summaryrefslogtreecommitdiffstats
path: root/sys/dev/fe/if_fe.c
diff options
context:
space:
mode:
authorbrooks <brooks@FreeBSD.org>2002-10-01 00:52:58 +0000
committerbrooks <brooks@FreeBSD.org>2002-10-01 00:52:58 +0000
commit8d85d3f96b724e383624fdbd12af2a342fabb2d3 (patch)
tree4c4f83f9f0d7e8a6c1b82691a0570c357fcbfb19 /sys/dev/fe/if_fe.c
parent14e083a35a84eb2e979f3ada30fb99171ef0d2dd (diff)
downloadFreeBSD-src-8d85d3f96b724e383624fdbd12af2a342fabb2d3.zip
FreeBSD-src-8d85d3f96b724e383624fdbd12af2a342fabb2d3.tar.gz
Use if_printf(ifp, "blah") instead of printf("fe%d: blah", ifp->if_unit).
A number of functions in this driver still use the unit number in their printouts because they pass the unit directly as a function argument instead of passing a softc or struct ifnet pointer. This should be resolved at a future date.
Diffstat (limited to 'sys/dev/fe/if_fe.c')
-rw-r--r--sys/dev/fe/if_fe.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/sys/dev/fe/if_fe.c b/sys/dev/fe/if_fe.c
index fb2ad57..1cbce78 100644
--- a/sys/dev/fe/if_fe.c
+++ b/sys/dev/fe/if_fe.c
@@ -991,11 +991,11 @@ fe_watchdog ( struct ifnet *ifp )
struct fe_softc *sc = (struct fe_softc *)ifp;
/* A "debug" message. */
- printf("fe%d: transmission timeout (%d+%d)%s\n",
- ifp->if_unit, sc->txb_sched, sc->txb_count,
+ if_printf(ifp, "transmission timeout (%d+%d)%s\n",
+ sc->txb_sched, sc->txb_count,
(ifp->if_flags & IFF_UP) ? "" : " when down");
if (sc->sc_if.if_opackets == 0 && sc->sc_if.if_ipackets == 0)
- printf("fe%d: wrong IRQ setting in config?\n", ifp->if_unit);
+ if_printf(ifp, "wrong IRQ setting in config?\n");
fe_reset(sc);
}
@@ -1179,8 +1179,8 @@ fe_start (struct ifnet *ifp)
* txb_count is zero if and only if txb_free is same
* as txb_size (which represents whole buffer.)
*/
- printf("fe%d: inconsistent txb variables (%d, %d)\n",
- sc->sc_unit, sc->txb_count, sc->txb_free);
+ if_printf(ifp, "inconsistent txb variables (%d, %d)\n",
+ sc->txb_count, sc->txb_free);
/*
* So, what should I do, then?
*
@@ -1205,8 +1205,8 @@ fe_start (struct ifnet *ifp)
* transmitter - should never happen at this point.
*/
if ((sc->txb_count > 0) && (sc->txb_sched == 0)) {
- printf("fe%d: transmitter idle with %d buffered packets\n",
- sc->sc_unit, sc->txb_count);
+ if_printf(ifp, "transmitter idle with %d buffered packets\n",
+ sc->txb_count);
fe_xmit(sc);
}
OpenPOWER on IntegriCloud