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

From: Michael Ellerman
Date: Tue Jun 02 2009 - 22:35:21 EST


On Tue, 2009-06-02 at 15:03 -0700, Andrew Morton wrote:
> On Tue, 02 Jun 2009 13:44:02 +0200
> Peter Oberparleiter <oberpar@xxxxxxxxxxxxxxxxxx> 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: signature.asc
Description: This is a digitally signed message part