Source-Changes-HG archive

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

[src/trunk]: src/sys/netisdn More ALTQ gotchas from Thomas Klausner:



details:   https://anonhg.NetBSD.org/src/rev/a96090840674
branches:  trunk
changeset: 522025:a96090840674
user:      martin <martin%NetBSD.org@localhost>
date:      Sun Feb 10 15:29:58 2002 +0000

description:
More ALTQ gotchas from Thomas Klausner:
Use IFQ_SET_MAXLEN instead of accesing opaque queue members directly.
Don't forget to IFQ_SET_READY the queue.

diffstat:

 sys/netisdn/i4b_isppp.c |  7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)

diffs (31 lines):

diff -r 8c9db112a1dc -r a96090840674 sys/netisdn/i4b_isppp.c
--- a/sys/netisdn/i4b_isppp.c   Sun Feb 10 15:17:24 2002 +0000
+++ b/sys/netisdn/i4b_isppp.c   Sun Feb 10 15:29:58 2002 +0000
@@ -34,7 +34,7 @@
  *     the "cx" driver for Cronyx's HDLC-in-hardware device).  This driver
  *     is only the glue between sppp and i4b.
  *
- *     $Id: i4b_isppp.c,v 1.10 2002/01/06 20:18:19 martin Exp $
+ *     $Id: i4b_isppp.c,v 1.11 2002/02/10 15:29:58 martin Exp $
  *
  * $FreeBSD$
  *
@@ -43,7 +43,7 @@
  *---------------------------------------------------------------------------*/
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: i4b_isppp.c,v 1.10 2002/01/06 20:18:19 martin Exp $");
+__KERNEL_RCSID(0, "$NetBSD: i4b_isppp.c,v 1.11 2002/02/10 15:29:58 martin Exp $");
 
 #ifndef __NetBSD__
 #define USE_ISPPP
@@ -276,7 +276,8 @@
 
                sc->sc_sp.pp_if.if_hdrlen = 0;
                sc->sc_sp.pp_if.if_addrlen = 0;
-               sc->sc_sp.pp_if.if_snd.ifq_maxlen = IFQ_MAXLEN;
+               IFQ_SET_MAXLEN(&sc->sc_sp.pp_if.if_snd, IFQ_MAXLEN);
+               IFQ_SET_READY(&sc->sc_sp.pp_if.if_snd);
 
                sc->sc_sp.pp_if.if_ipackets = 0;
                sc->sc_sp.pp_if.if_ierrors = 0;



Home | Main Index | Thread Index | Old Index