From owner-freebsd-net Tue Mar 4 16:15: 5 2003 Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C68FF37B401 for ; Tue, 4 Mar 2003 16:15:03 -0800 (PST) Received: from InterJet.dellroad.org (adsl-63-194-81-26.dsl.snfc21.pacbell.net [63.194.81.26]) by mx1.FreeBSD.org (Postfix) with ESMTP id AF30B43FAF for ; Tue, 4 Mar 2003 16:15:02 -0800 (PST) (envelope-from archie@dellroad.org) Received: from arch20m.dellroad.org (arch20m.dellroad.org [10.1.1.20]) by InterJet.dellroad.org (8.9.1a/8.9.1) with ESMTP id QAA58381 for ; Tue, 4 Mar 2003 16:04:55 -0800 (PST) Received: from arch20m.dellroad.org (localhost [127.0.0.1]) by arch20m.dellroad.org (8.12.6/8.12.6) with ESMTP id h2504sn6012404 for ; Tue, 4 Mar 2003 16:04:54 -0800 (PST) (envelope-from archie@arch20m.dellroad.org) Received: (from archie@localhost) by arch20m.dellroad.org (8.12.6/8.12.6/Submit) id h2504sbY012403 for freebsd-net@freebsd.org; Tue, 4 Mar 2003 16:04:54 -0800 (PST) (envelope-from archie) From: Archie Cobbs Message-Id: <200303050004.h2504sbY012403@arch20m.dellroad.org> Subject: Mysterious MPD hangs? Please try this patch To: freebsd-net@freebsd.org Date: Tue, 4 Mar 2003 16:04:54 -0800 (PST) X-Mailer: ELM [version 2.4ME+ PL99b (25)] MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=US-ASCII Sender: owner-freebsd-net@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org Hi, For anyone who's using MPD with multilink PPP enabled and is experiencing mysterious "hangs" where no data gets through for an extended period of time, please try the patch below. Thanks to Matthew Impett for finding the bug. -Archie __________________________________________________________________________ Archie Cobbs * Precision I/O * http://www.precisionio.com Index: sys/netgraph/ng_ppp.c =================================================================== RCS file: /home/cvs/freebsd/src/sys/netgraph/ng_ppp.c,v retrieving revision 1.15.2.9 diff -u -r1.15.2.9 ng_ppp.c --- sys/netgraph/ng_ppp.c 2 Jul 2002 23:44:03 -0000 1.15.2.9 +++ sys/netgraph/ng_ppp.c 5 Mar 2003 00:00:48 -0000 @@ -1370,6 +1370,7 @@ struct mbuf *m; meta_p meta; int i, seq; + int endseq; now.tv_sec = 0; /* uninitialized state */ while (1) { @@ -1419,11 +1420,12 @@ } /* Extract completed packet */ + endseq = end->seq; ng_ppp_get_packet(node, &m, &meta); /* Bump MSEQ if necessary */ - if (MP_RECV_SEQ_DIFF(priv, priv->mseq, end->seq) < 0) { - priv->mseq = end->seq; + if (MP_RECV_SEQ_DIFF(priv, priv->mseq, endseq) < 0) { + priv->mseq = endseq; for (i = 0; i < priv->numActiveLinks; i++) { struct ng_ppp_link *const alink = &priv->links[priv->activeLinks[i]]; To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message