From owner-freebsd-net@freebsd.org Wed Nov 28 09:29:40 2018 Return-Path: Delivered-To: freebsd-net@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6C07D114E35E for ; Wed, 28 Nov 2018 09:29:40 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mailman.ysv.freebsd.org (mailman.ysv.freebsd.org [IPv6:2001:1900:2254:206a::50:5]) by mx1.freebsd.org (Postfix) with ESMTP id 26A516C584 for ; Wed, 28 Nov 2018 09:29:40 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: by mailman.ysv.freebsd.org (Postfix) id DA116114E358; Wed, 28 Nov 2018 09:29:39 +0000 (UTC) Delivered-To: net@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B73E4114E355 for ; Wed, 28 Nov 2018 09:29:39 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.ysv.freebsd.org (mxrelay.ysv.freebsd.org [IPv6:2001:1900:2254:206a::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (Client CN "mxrelay.ysv.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id CCB586C57F for ; Wed, 28 Nov 2018 09:29:38 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2001:1900:2254:206a::16:76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.ysv.freebsd.org (Postfix) with ESMTPS id E1ED214256 for ; Wed, 28 Nov 2018 09:29:37 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.118]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id wAS9Tb6o048159 for ; Wed, 28 Nov 2018 09:29:37 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id wAS9TbBb048158 for net@FreeBSD.org; Wed, 28 Nov 2018 09:29:37 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: net@FreeBSD.org Subject: [Bug 227720] Kernel panic in ppp server Date: Wed, 28 Nov 2018 09:29:36 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: kern X-Bugzilla-Version: 11.1-RELEASE X-Bugzilla-Keywords: crash, needs-qa X-Bugzilla-Severity: Affects Some People X-Bugzilla-Who: ae@FreeBSD.org X-Bugzilla-Status: Open X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: net@FreeBSD.org X-Bugzilla-Flags: mfc-stable11? X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-Rspamd-Queue-Id: 26A516C584 X-Spamd-Result: default: False [2.14 / 15.00]; local_wl_from(0.00)[freebsd.org]; NEURAL_SPAM_LONG(0.62)[0.618,0]; NEURAL_SPAM_SHORT(0.81)[0.809,0]; NEURAL_SPAM_MEDIUM(0.71)[0.707,0]; ASN(0.00)[asn:10310, ipnet:2001:1900:2254::/48, country:US] X-Rspamd-Server: mx1.freebsd.org X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 28 Nov 2018 09:29:40 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D227720 --- Comment #40 from Andrey V. Elsukov --- (In reply to Franck Rousseau from comment #37) > Thanks for the fast reply! Not sure if I continue here or in bug #230498 = but > since this is still related to PPP, I put it here. >=20 > I only had 15 min to test, but it crashed right away on the first try. He= re > is the procedure: > - setup PC3: configure address on Ethernet interface; > - setup PC2: configure address on Ethernet interface, add ARP pub entry, > activate forwarding, start ppp server and wait for connection; > - setup PC3: start pinging PC3, obviously it fails, start ppp client and > open connection, add default route, everything works correctly. > Leave everything running as it is, then quit ppp on both sides, restart t= he > server waiting for the connection, connect from client -> crash on PC2. >=20 > Here is the trace, it crashes one call further line rtsock.c:1559 after t= he > patch >=20 > info.rti_info[RTAX_GENMASK] =3D 0; > if (rt->rt_ifp) { > - info.rti_info[RTAX_IFP] =3D rt->rt_ifp->if_addr->ifa_addr; > + IF_ADDR_RLOCK(rt->rt_ifp); > + if (rt->rt_ifp->if_addr !=3D NULL) > + info.rti_info[RTAX_IFP] =3D rt->rt_ifp->if_addr->ifa_addr; > info.rti_info[RTAX_IFA] =3D rt->rt_ifa->ifa_addr; If this patch is full version that you used, you missed IF_ADDR_RUNLOCK() h= ere, and this is why it panics. > #8 0xffffffff80af2893 in __rw_rlock_hard (rw=3D0xfffff800be4bc990, > td=3D0xfffff80105056620, v=3D) at > /usr/src/sys/kern/kern_rwlock.c:493 > #9 0xffffffff80c0ce9b in sysctl_dumpentry (rn=3D0xfffff80008e74270, > vw=3D0xfffffe0468486690) at /usr/src/sys/net/rtsock.c:1559 --=20 You are receiving this mail because: You are the assignee for the bug.=