linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Michael Ellerman <michael@ellerman.id.au>
To: Jimi Xenidis <jimix@watson.ibm.com>
Cc: linuxppc-dev@ozlabs.org
Subject: Re: [PATCH][resend] udbg_printf() formatting attribute
Date: Fri, 19 May 2006 01:56:45 +1000	[thread overview]
Message-ID: <1147967806.8469.10.camel@localhost.localdomain> (raw)
In-Reply-To: <34FAC3E5-F717-4640-B094-312C8773852E@watson.ibm.com>

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

On Thu, 2006-05-18 at 08:22 -0400, Jimi Xenidis wrote:
> On May 17, 2006, at 7:36 PM, Michael Ellerman wrote:
> 
> > On Wed, 2006-05-17 at 12:00 -0400, jimix@watson.ibm.com wrote:
> >> -	pr_debug("%s: current_entitled = %lu, current_weight = %lu\n",
> >> +	pr_debug("%s: current_entitled = %lu, current_weight = %u\n",
> >>  		 __FUNCTION__, current_entitled, current_weight);
> >>
> >> -	pr_debug("%s: new_entitled = %lu, new_weight = %lu\n",
> >> +	pr_debug("%s: new_entitled = %lu, new_weight = %u\n",
> >>  		 __FUNCTION__, *new_entitled_ptr, *new_weight_ptr);
> >
> > But pr_debug() calls printk, not udbg_printf() ?
> 
> Now _thats_ funny!
> Then I'm so happy to have found and fixed this compiler warning :)

Haha, nice one Jimi :D

> >> -extern void udbg_printf(const char *fmt, ...);
> >> +extern void udbg_printf(const char *fmt, ...)
> >> +	__attribute__ ((format (printf, 1, 2)));
> 
> I believe this chunk is still goodness as it will catch format issues  
> for developers.

I'm actually hoping to get rid of udbg_printf(), but if I can't we
should stick this in I guess. The real problem IMHO is that debug
printks rot because they're rarely compiled, not sure what to do about
that.

cheers

-- 
Michael Ellerman
IBM OzLabs

wwweb: http://michael.ellerman.id.au
phone: +61 2 6212 1183 (tie line 70 21183)

We do not inherit the earth from our ancestors,
we borrow it from our children. - S.M.A.R.T Person

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

  reply	other threads:[~2006-05-18 15:56 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-05-17 16:00 [PATCH][resend] udbg_printf() formatting attribute jimix
2006-05-17 23:36 ` Michael Ellerman
2006-05-18 12:22   ` Jimi Xenidis
2006-05-18 15:56     ` Michael Ellerman [this message]
2006-05-18 16:52       ` Jimi Xenidis
2006-05-22  6:33         ` Michael Ellerman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1147967806.8469.10.camel@localhost.localdomain \
    --to=michael@ellerman.id.au \
    --cc=jimix@watson.ibm.com \
    --cc=linuxppc-dev@ozlabs.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).