Subject: Re: RCSID vs KERNEL_RCSID
To: None <tech-kern@netbsd.org>
From: Christos Zoulas <christos@astron.com>
List: tech-kern
Date: 12/22/2005 16:03:22
In article <43AACB8B.8050908@tadpole.com>,
Garrett D'Amore <garrett_damore@tadpole.com> wrote:
>I have been informed to use __RCSID() in some code, but I find most
>kernel sources use __KERNEL_RCSID() (which evaluates to the same thing
>for ELF and a.out).
>
>I am not sure which to use, and in the case __KERNEL_RCSID() there are
>two arguments.  What is the first argument to __KERNEL_RCSID for?

I believe that __KERNEL_RCSID() is supposed to be used in kernel code
and __RCSID() is supposed to be used in userland code. The first argument
is used to make __KERNEL_RCSID() unique. I.e. if you include a file that
has already a __KERNEL_RCSID(0, "file.inc"), you can use
__KERNEL_RCSID(1, "file.c") to have both present in the binary without
symbol conflicts.

christos