From owner-cvs-all@FreeBSD.ORG Wed Aug 24 17:30:45 2005 Return-Path: X-Original-To: cvs-all@FreeBSD.org Delivered-To: cvs-all@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0C33E16A41F; Wed, 24 Aug 2005 17:30:45 +0000 (GMT) (envelope-from rwatson@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id CA47C43D46; Wed, 24 Aug 2005 17:30:44 +0000 (GMT) (envelope-from rwatson@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j7OHUiv2061619; Wed, 24 Aug 2005 17:30:44 GMT (envelope-from rwatson@repoman.freebsd.org) Received: (from rwatson@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j7OHUiNN061618; Wed, 24 Aug 2005 17:30:44 GMT (envelope-from rwatson) Message-Id: <200508241730.j7OHUiNN061618@repoman.freebsd.org> From: Robert Watson Date: Wed, 24 Aug 2005 17:30:44 +0000 (UTC) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: RELENG_6 Cc: Subject: cvs commit: src/sys/kern subr_witness.c src/sys/netinet igmp.c in.c in_var.h ip_input.c ip_output.c X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 24 Aug 2005 17:30:45 -0000 rwatson 2005-08-24 17:30:44 UTC FreeBSD src repository Modified files: (Branch: RELENG_6) sys/kern subr_witness.c sys/netinet igmp.c in.c in_var.h ip_input.c ip_output.c Log: Merge subr_witness.c:1.196, igmp.c:1.49, in.c:1.86, in_var.h:1.55, ip_input.c:1.303, ip_output.c:1.243 from HEAD to RELENG_6: Introduce in_multi_mtx, which will protect IPv4-layer multicast address lists, as well as accessor macros. For now, this is a recursive mutex due code sequences where IPv4 multicast calls into IGMP calls into ip_output(), which then tests for a multicast forwarding case. For support macros in in_var.h to check multicast address lists, assert that in_multi_mtx is held. Acquire in_multi_mtx around iteration over the IPv4 multicast address lists, such as in ip_input() and ip_output(). Acquire in_multi_mtx when manipulating the IPv4 layer multicast addresses, as well as over the manipulation of ifnet multicast address lists in order to keep the two layers in sync. Lock down accesses to IPv4 multicast addresses in IGMP, or assert the lock when performing IGMP join/leave events. Eliminate spl's associated with IPv4 multicast addresses, portions of IGMP that weren't previously expunged by IGMP locking. Add in_multi_mtx, igmp_mtx, and if_addr_mtx lock order to hard-coded lock order in WITNESS, in that order. Problem reported by: Ed Maste Approved by: re (scottl) Revision Changes Path 1.195.2.1 +7 -0 src/sys/kern/subr_witness.c 1.48.2.1 +12 -8 src/sys/netinet/igmp.c 1.85.2.1 +18 -10 src/sys/netinet/in.c 1.53.2.2 +14 -0 src/sys/netinet/in_var.h 1.301.2.2 +2 -0 src/sys/netinet/ip_input.c 1.242.2.2 +3 -0 src/sys/netinet/ip_output.c