Re: [PATCH 3/4] gcov: add gcov profiling infrastructure

Michael Ellerman
2009-06-03T02:34:51Z

[-- Attachment #1: Type: text/plain, Size: 886 bytes --]

On Tue, 2009-06-02 at 15:03 -0700, Andrew Morton wrote:
> On Tue, 02 Jun 2009 13:44:02 +0200
> Peter Oberparleiter <oberpar@linux.vnet.ibm.com> wrote:

> > +void __gcov_init(struct gcov_info *info)
> > +{
> > + static unsigned int gcov_version;
> > +
> > + mutex_lock(&gcov_lock);
> > + if (gcov_version == 0) {
> > + gcov_version = info->version;
> > + /*
> > + * Printing gcc's version magic may prove useful for debugging
> > + * incompatibility reports.
> > + */
> > + pr_info("version magic: 0x%x\n", gcov_version);
>
> Will this be spat out as simply
>
> version magic: 0x1234
>
> ? If so, that'll be rather obscure because people won't know what
> subsystem printed it. Prefixing this (and all other printks) with
> "gcov: " would fix that.

Great minds think alike, see a few lines above:

+#define pr_fmt(fmt) "gcov: " fmt

cheers

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 197 bytes --]