Source-Changes-HG archive

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

[src/trunk]: src/sys/dev/pci if_rge.c: avoid aprint_error*() abuse



details:   https://anonhg.NetBSD.org/src/rev/826ac6442404
branches:  trunk
changeset: 950400:826ac6442404
user:      jakllsch <jakllsch%NetBSD.org@localhost>
date:      Wed Jan 27 14:25:22 2021 +0000

description:
if_rge.c: avoid aprint_error*() abuse

diffstat:

 sys/dev/pci/if_rge.c |  14 +++++++-------
 1 files changed, 7 insertions(+), 7 deletions(-)

diffs (63 lines):

diff -r 3d064287a65a -r 826ac6442404 sys/dev/pci/if_rge.c
--- a/sys/dev/pci/if_rge.c      Wed Jan 27 13:50:17 2021 +0000
+++ b/sys/dev/pci/if_rge.c      Wed Jan 27 14:25:22 2021 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: if_rge.c,v 1.15 2021/01/20 18:26:11 jakllsch Exp $     */
+/*     $NetBSD: if_rge.c,v 1.16 2021/01/27 14:25:22 jakllsch Exp $     */
 /*     $OpenBSD: if_rge.c,v 1.4 2020/07/10 13:26:38 patrick Exp $      */
 
 /*
@@ -18,7 +18,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_rge.c,v 1.15 2021/01/20 18:26:11 jakllsch Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_rge.c,v 1.16 2021/01/27 14:25:22 jakllsch Exp $");
 
 /* #include "vlan.h" Sevan */
 
@@ -623,7 +623,7 @@
 {
        struct rge_softc *sc = ifp->if_softc;
 
-       aprint_error_dev(sc->sc_dev, "watchdog timeout\n");
+       device_printf(sc->sc_dev, "watchdog timeout\n");
        if_statinc(ifp, if_oerrors);
 
        rge_init(ifp);
@@ -658,7 +658,7 @@
 
        /* Initialize RX descriptors list. */
        if (rge_rx_list_init(sc) == ENOBUFS) {
-               aprint_error_dev(sc->sc_dev,
+               device_printf(sc->sc_dev,
                    "init failed: no memory for RX buffers\n");
                rge_stop(ifp);
                return (ENOBUFS);
@@ -904,7 +904,7 @@
                ifp->if_baudrate = IF_Mbps(10);
                break;
        default:
-               aprint_error_dev(sc->sc_dev,
+               device_printf(sc->sc_dev,
                    "unsupported media type\n");
                return (EINVAL);
        }
@@ -1089,7 +1089,7 @@
        r = &sc->rge_ldata.rge_rx_list[idx];
 
        if (RGE_OWN(r)) {
-               aprint_error_dev(sc->sc_dev, "tried to map busy RX descriptor\n");
+               device_printf(sc->sc_dev, "tried to map busy RX descriptor\n");
                goto out;
        }
 
@@ -1384,7 +1384,7 @@
                        break;
        }
        if (i == RGE_TIMEOUT)
-               aprint_error_dev(sc->sc_dev, "reset never completed!\n");
+               device_printf(sc->sc_dev, "reset never completed!\n");
 }
 
 void



Home | Main Index | Thread Index | Old Index