Source-Changes-HG archive

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

[src/trunk]: src/sys/dev/ic Fix a few copy&pastos in an error path



details:   https://anonhg.NetBSD.org/src/rev/84d11987c963
branches:  trunk
changeset: 790833:84d11987c963
user:      martin <martin%NetBSD.org@localhost>
date:      Thu Oct 24 13:15:12 2013 +0000

description:
Fix a few copy&pastos in an error path

diffstat:

 sys/dev/ic/sgec.c |  10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)

diffs (39 lines):

diff -r f7e3acfb9c90 -r 84d11987c963 sys/dev/ic/sgec.c
--- a/sys/dev/ic/sgec.c Thu Oct 24 13:00:21 2013 +0000
+++ b/sys/dev/ic/sgec.c Thu Oct 24 13:15:12 2013 +0000
@@ -1,4 +1,4 @@
-/*      $NetBSD: sgec.c,v 1.39 2010/11/13 13:52:02 uebayasi Exp $ */
+/*      $NetBSD: sgec.c,v 1.40 2013/10/24 13:15:12 martin Exp $ */
 /*
  * Copyright (c) 1999 Ludd, University of Lule}, Sweden. All rights reserved.
  *
@@ -45,7 +45,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: sgec.c,v 1.39 2010/11/13 13:52:02 uebayasi Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sgec.c,v 1.40 2013/10/24 13:15:12 martin Exp $");
 
 #include "opt_inet.h"
 
@@ -241,17 +241,17 @@
  fail_6:
        for (i = 0; i < RXDESCS; i++) {
                if (sc->sc_rxmbuf[i] != NULL) {
-                       bus_dmamap_unload(sc->sc_dmat, sc->sc_xmtmap[i]);
+                       bus_dmamap_unload(sc->sc_dmat, sc->sc_rcvmap[i]);
                        m_freem(sc->sc_rxmbuf[i]);
                }
        }
  fail_5:
-       for (i = 0; i < RXDESCS; i++) {
+       for (i = 0; i < TXDESCS; i++) {
                if (sc->sc_xmtmap[i] != NULL)
                        bus_dmamap_destroy(sc->sc_dmat, sc->sc_xmtmap[i]);
        }
  fail_4:
-       for (i = 0; i < TXDESCS; i++) {
+       for (i = 0; i < RXDESCS; i++) {
                if (sc->sc_rcvmap[i] != NULL)
                        bus_dmamap_destroy(sc->sc_dmat, sc->sc_rcvmap[i]);
        }



Home | Main Index | Thread Index | Old Index