Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 17 Feb 2009 23:21:42 +0100
From:      Roman Divacky <rdivacky@freebsd.org>
To:        John Baldwin <jhb@freebsd.org>
Cc:        freebsd-hackers@freebsd.org, hackers@freebsd.org, Ryan Stone <rysto32@gmail.com>
Subject:   Re: TUNABLE_INT question
Message-ID:  <20090217222142.GA94925@freebsd.org>
In-Reply-To: <200902170931.12983.jhb@freebsd.org>
References:  <20090213183229.GA94272@freebsd.org> <bc2d970902131255h1a0965d8g4e8c54a10436ee22@mail.gmail.com> <20090213221607.GA25161@freebsd.org> <200902170931.12983.jhb@freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
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



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20090217222142.GA94925>