From owner-cvs-src@FreeBSD.ORG Sat Jul 2 23:13:32 2005 Return-Path: X-Original-To: cvs-src@FreeBSD.org Delivered-To: cvs-src@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8EAD416A41C; Sat, 2 Jul 2005 23:13:32 +0000 (GMT) (envelope-from thompsa@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7738943D1D; Sat, 2 Jul 2005 23:13:32 +0000 (GMT) (envelope-from thompsa@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 j62NDWCg028249; Sat, 2 Jul 2005 23:13:32 GMT (envelope-from thompsa@repoman.freebsd.org) Received: (from thompsa@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j62NDWYC028248; Sat, 2 Jul 2005 23:13:32 GMT (envelope-from thompsa) Message-Id: <200507022313.j62NDWYC028248@repoman.freebsd.org> From: Andrew Thompson Date: Sat, 2 Jul 2005 23:13:31 +0000 (UTC) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Cc: Subject: cvs commit: src/sys/amd64/include _types.h src/sys/i386/include _types.h src/sys/net if_bridge.c src/sys/netinet ip_var.h src/sys/netinet6 ip6_var.h X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 02 Jul 2005 23:13:32 -0000 thompsa 2005-07-02 23:13:31 UTC FreeBSD src repository Modified files: sys/amd64/include _types.h sys/i386/include _types.h sys/net if_bridge.c sys/netinet ip_var.h sys/netinet6 ip6_var.h Log: Check the alignment of the IP header before passing the packet up to the packet filter. This would cause a panic on architectures that require strict alignment such as sparc64 (tier1) and ia64/ppc (tier2). This adds two new macros that check the alignment, these are compile time dependent on __NO_STRICT_ALIGNMENT which is set for i386 and amd64 where alignment isn't need so the cost is avoided. IP_HDR_ALIGNED_P() IP6_HDR_ALIGNED_P() Move bridge_ip_checkbasic()/bridge_ip6_checkbasic() up so that the alignment is checked for ipfw and dummynet too. PR: ia64/81284 Obtained from: NetBSD Approved by: re (dwhite), mlaier (mentor) Revision Changes Path 1.9 +2 -0 src/sys/amd64/include/_types.h 1.12 +2 -0 src/sys/i386/include/_types.h 1.10 +48 -27 src/sys/net/if_bridge.c 1.95 +6 -0 src/sys/netinet/ip_var.h 1.30 +6 -0 src/sys/netinet6/ip6_var.h