From owner-p4-projects@FreeBSD.ORG Fri May 4 18:28:54 2007 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id F321616A401; Fri, 4 May 2007 18:28:53 +0000 (UTC) X-Original-To: perforce@freebsd.org Delivered-To: perforce@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 94FFA16A402; Fri, 4 May 2007 18:28:53 +0000 (UTC) (envelope-from zec@icir.org) Received: from xaqua.tel.fer.hr (xaqua.tel.fer.hr [161.53.19.25]) by mx1.freebsd.org (Postfix) with ESMTP id 5162513C448; Fri, 4 May 2007 18:28:53 +0000 (UTC) (envelope-from zec@icir.org) Received: by xaqua.tel.fer.hr (Postfix, from userid 20006) id 3F0EC9B651; Fri, 4 May 2007 20:28:52 +0200 (CEST) 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.3 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 autolearn=ham version=3.1.7 Received: from [192.168.200.106] (zec2.tel.fer.hr [161.53.19.79]) by xaqua.tel.fer.hr (Postfix) with ESMTP id 69AB29B644; Fri, 4 May 2007 20:28:51 +0200 (CEST) From: Marko Zec To: Julian Elischer Date: Fri, 4 May 2007 20:28:46 +0200 User-Agent: KMail/1.9.6 References: <200705041118.l44BIdN0039418@repoman.freebsd.org> <463B762B.1090005@elischer.org> In-Reply-To: <463B762B.1090005@elischer.org> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200705042028.47360.zec@icir.org> Cc: Perforce Change Reviews , Marko Zec Subject: Re: PERFORCE change 119231 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: Fri, 04 May 2007 18:28:54 -0000 On Friday 04 May 2007 20:06:35 Julian Elischer wrote: > Marko Zec wrote: > > http://perforce.freebsd.org/chv.cgi?CH=119231 > > > > Change 119231 by zec@zec_zoo on 2007/05/04 11:18:33 > > > > proc0_init() is called before vi_init() during kernel > > autoconfiguratino / booting, so pointers inside vimage_0 are > > not yet populated at that time. Hence, access vprocg_0 > > directly at that point, not through vimage_0. > > > > Affected files ... > > > > .. //depot/projects/vimage/src/sys/kern/init_main.c#8 edit > > > > Differences ... > > > > ==== //depot/projects/vimage/src/sys/kern/init_main.c#8 (text+ko) > > ==== > > > > @@ -443,7 +443,7 @@ > > p->p_ucred->cr_prison = NULL; /* Don't jail it. */ > > #ifdef VIMAGE > > p->p_ucred->cr_vimage = p->p_ucred->cr_rvimage = &vimage_0; > > - vimage_0.v_procg->nprocs = 1; > > + vprocg_0.nprocs = 1; > > #endif > > #ifdef AUDIT > > audit_proc_alloc(p); > > or change the order? Yup... In general I'm always more nervous about changing initialization order than introducing simple changes as above, but vi_init() doesn't (yet) depend on anything particular so yes this should work... Marko