From owner-p4-projects@FreeBSD.ORG Wed Nov 26 01:07:37 2008 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 78EE41065675; Wed, 26 Nov 2008 01:07:37 +0000 (UTC) Delivered-To: perforce@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3D6961065673 for ; Wed, 26 Nov 2008 01:07:37 +0000 (UTC) (envelope-from zec@freebsd.org) Received: from xaqua.tel.fer.hr (xaqua.tel.fer.hr [161.53.19.25]) by mx1.freebsd.org (Postfix) with ESMTP id F290D8FC19 for ; Wed, 26 Nov 2008 01:07:35 +0000 (UTC) (envelope-from zec@freebsd.org) Received: by xaqua.tel.fer.hr (Postfix, from userid 20006) id 937129B64D; Wed, 26 Nov 2008 01:45:12 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.1.7 (2006-10-05) on xaqua.tel.fer.hr X-Spam-Level: X-Spam-Status: No, score=-4.2 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 autolearn=ham version=3.1.7 Received: from localhost (imunes.tel.fer.hr [161.53.19.8]) by xaqua.tel.fer.hr (Postfix) with ESMTP id 0F50B9B647; Wed, 26 Nov 2008 01:45:09 +0100 (CET) From: Marko Zec To: Julian Elischer Date: Wed, 26 Nov 2008 01:45:02 +0100 User-Agent: KMail/1.9.7 References: <200811252347.mAPNlvda037095@repoman.freebsd.org> <492C9515.9020703@elischer.org> In-Reply-To: <492C9515.9020703@elischer.org> MIME-Version: 1.0 Content-Disposition: inline Message-Id: <200811260145.02922.zec@freebsd.org> Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Cc: Perforce Change Reviews Subject: Re: PERFORCE change 153564 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 26 Nov 2008 01:07:37 -0000 On Wednesday 26 November 2008 01:15:17 Julian Elischer wrote: > Marko Zec wrote: > > http://perforce.freebsd.org/chv.cgi?CH=153564 > > > > Change 153564 by zec@zec_tpx32 on 2008/11/25 23:47:35 > > > > static struct sockaddr key_src should most probably be > > virtualized as well (?) > > why? > > is it ever written to? no it isn't - a call to sbappendaddr() has key_src as an argument but as a const... good catch, thanks! Marko > > Affected files ... > > > > .. //depot/projects/vimage-commit2/src/sys/netipsec/keysock.c#14 > > edit .. //depot/projects/vimage-commit2/src/sys/netipsec/vipsec.h#9 > > edit > > > > Differences ... > > > > ==== //depot/projects/vimage-commit2/src/sys/netipsec/keysock.c#14 > > (text+ko) ==== > > > > @@ -74,10 +74,9 @@ > > #ifdef VIMAGE_GLOBALS > > static struct key_cb key_cb; > > struct pfkeystat pfkeystat; > > +static struct sockaddr key_src; > > #endif > > > > -static struct sockaddr key_src = { 2, PF_KEY, }; > > - > > static int key_sendup0 __P((struct rawcb *, struct mbuf *, int)); > > > > /* > > @@ -573,6 +572,9 @@ > > { > > INIT_VNET_IPSEC(curvnet); > > > > + V_key_src.sa_len = 2; > > + V_key_src.sa_family = PF_KEY; > > + > > bzero((caddr_t)&V_key_cb, sizeof(V_key_cb)); > > ipsec_init(); > > key_init(); > > > > ==== //depot/projects/vimage-commit2/src/sys/netipsec/vipsec.h#9 > > (text+ko) ==== > > > > @@ -106,7 +106,7 @@ > > > > struct pfkeystat _pfkeystat; > > struct key_cb _key_cb; > > - > > + struct sockaddr _key_src; > > LIST_HEAD(, secpolicy) _sptree[IPSEC_DIR_MAX]; > > LIST_HEAD(, secashead) _sahtree; > > LIST_HEAD(, secreg) _regtree[SADB_SATYPE_MAX + 1];