From owner-freebsd-bugs@FreeBSD.ORG Sun Mar 4 19:10:10 2012 Return-Path: Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8D345106566B for ; Sun, 4 Mar 2012 19:10:10 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 662C68FC17 for ; Sun, 4 Mar 2012 19:10:10 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.5/8.14.5) with ESMTP id q24JAAIx010676 for ; Sun, 4 Mar 2012 19:10:10 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q24JAARu010675; Sun, 4 Mar 2012 19:10:10 GMT (envelope-from gnats) Resent-Date: Sun, 4 Mar 2012 19:10:10 GMT Resent-Message-Id: <201203041910.q24JAARu010675@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, "Bjoern A. Zeeb" Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C411F106564A for ; Sun, 4 Mar 2012 19:01:51 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from red.freebsd.org (red.freebsd.org [IPv6:2001:4f8:fff6::22]) by mx1.freebsd.org (Postfix) with ESMTP id AFD268FC08 for ; Sun, 4 Mar 2012 19:01:51 +0000 (UTC) Received: from red.freebsd.org (localhost [127.0.0.1]) by red.freebsd.org (8.14.4/8.14.4) with ESMTP id q24J1pLN009738 for ; Sun, 4 Mar 2012 19:01:51 GMT (envelope-from nobody@red.freebsd.org) Received: (from nobody@localhost) by red.freebsd.org (8.14.4/8.14.4/Submit) id q24J1pEv009737; Sun, 4 Mar 2012 19:01:51 GMT (envelope-from nobody) Message-Id: <201203041901.q24J1pEv009737@red.freebsd.org> Date: Sun, 4 Mar 2012 19:01:51 GMT From: "Bjoern A. Zeeb" To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Cc: Subject: kern/165692: nd6_nud_hint() a NOP due to removal of route caching X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 04 Mar 2012 19:10:10 -0000 >Number: 165692 >Category: kern >Synopsis: nd6_nud_hint() a NOP due to removal of route caching >Confidential: no >Severity: critical >Priority: medium >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Sun Mar 04 19:10:10 UTC 2012 >Closed-Date: >Last-Modified: >Originator: Bjoern A. Zeeb >Release: 10-CURRENT >Organization: >Environment: >Description: When removing route caching from the pcbs nd6_nud_hint() was called with two NULL pointers for rt and dst6 (and has probably only been called with rt before). Since the code in nd6_nud_hint() was changed as well and the entire function calls are now effectively NOPs as all mandatory options are missing. >How-To-Repeat: Index: sys/netinet/tcp_input.c =================================================================== --- sys/netinet/tcp_input.c (revision 232512) +++ sys/netinet/tcp_input.c (working copy) @@ -457,6 +457,7 @@ tcp_signature_verify_input(struct mbuf *m, int off /* Neighbor Discovery, Neighbor Unreachability Detection Upper layer hint. */ #ifdef INET6 +/* XXX-BZ useless without rt and dst6. Fix route chaching removal. */ #define ND6_HINT(tp) \ do { \ if ((tp) && (tp)->t_inpcb && \ Index: sys/netinet/tcp_var.h =================================================================== --- sys/netinet/tcp_var.h (revision 232512) +++ sys/netinet/tcp_var.h (working copy) @@ -85,6 +85,7 @@ struct tcptemp { /* Neighbor Discovery, Neighbor Unreachability Detection Upper layer hint. */ #ifdef INET6 +/* XXX-BZ useless without rt and dst6. Fix route chaching removal. */ #define ND6_HINT(tp) \ do { \ if ((tp) && (tp)->t_inpcb && \ Index: sys/netinet6/nd6.c =================================================================== --- sys/netinet6/nd6.c (revision 232514) +++ sys/netinet6/nd6.c (working copy) @@ -1136,6 +1136,8 @@ nd6_nud_hint(struct rtentry *rt, struct in6_addr * if ((dst6 == NULL) || (rt == NULL)) return; + /* NOTREACHED. XXX-BZ Fix route chaching removal. */ + ifp = rt->rt_ifp; IF_AFDATA_LOCK(ifp); ln = nd6_lookup(dst6, ND6_EXCLUSIVE, NULL); >Fix: Once PCB route caching is back cann nd6_nud_hint() with proper arguments again. >Release-Note: >Audit-Trail: >Unformatted: