From owner-freebsd-hackers@FreeBSD.ORG Tue Feb 17 23:09:42 2009 Return-Path: Delivered-To: hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7E70A10656E7; Tue, 17 Feb 2009 23:09:42 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from cyrus.watson.org (cyrus.watson.org [65.122.17.42]) by mx1.freebsd.org (Postfix) with ESMTP id 4C5858FC19; Tue, 17 Feb 2009 23:09:42 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from server.baldwin.cx (pool-98-109-39-197.nwrknj.fios.verizon.net [98.109.39.197]) by cyrus.watson.org (Postfix) with ESMTPSA id 07E9146B23; Tue, 17 Feb 2009 18:09:42 -0500 (EST) Received: from localhost (john@localhost [127.0.0.1]) (authenticated bits=0) by server.baldwin.cx (8.14.3/8.14.3) with ESMTP id n1HN9adV037468; Tue, 17 Feb 2009 18:09:36 -0500 (EST) (envelope-from jhb@freebsd.org) From: John Baldwin To: Roman Divacky Date: Tue, 17 Feb 2009 17:51:13 -0500 User-Agent: KMail/1.9.7 References: <20090213183229.GA94272@freebsd.org> <200902170931.12983.jhb@freebsd.org> <20090217222142.GA94925@freebsd.org> In-Reply-To: <20090217222142.GA94925@freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200902171751.13962.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH authentication, not delayed by milter-greylist-2.0.2 (server.baldwin.cx [127.0.0.1]); Tue, 17 Feb 2009 18:09:36 -0500 (EST) X-Virus-Scanned: ClamAV 0.94.2/8998/Mon Feb 16 22:40:00 2009 on server.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-4.4 required=4.2 tests=ALL_TRUSTED,AWL,BAYES_00 autolearn=ham version=3.1.3 X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on server.baldwin.cx Cc: freebsd-hackers@freebsd.org, hackers@freebsd.org, Ryan Stone Subject: Re: TUNABLE_INT question X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Feb 2009 23:09:44 -0000 On Tuesday 17 February 2009 5:21:42 pm Roman Divacky wrote: > On Tue, Feb 17, 2009 at 09:31:12AM -0500, John Baldwin wrote: > > On Friday 13 February 2009 5:16:07 pm Roman Divacky wrote: > > > On Fri, Feb 13, 2009 at 03:55:44PM -0500, Ryan Stone wrote: > > > > __FILE__ is a string so you can't concat that with anything to produce an > > > > identifier. In any case, the variable is static so there can't be any > > > > collision problems with other files. > > > > > > I was talking about the SYSINIT parameter. thats a section in a .o > > > file, and I am getting collisions there... > > > > Hmm, are you doing something like this: > > > > #define FOO(string) \ > > TUNABLE_INT(string ## ".bar", &bar); \ > > TUNABLE_INT(string ## ".foo", &foo); \ > > > > FOO(baz) > > > > That would collide as both of the TUNABLE_INT() invocations would have the > > same __LINE__ (the line number of the 'FOO(baz)'). > > no.. it was just two tunables in two files that happened to end up in the same > line. fixed now Hmmm, odd. Those should be static and not matter. -- John Baldwin