From: Finn Thain <fthain@telegraphics.com.au>
To: Kars de Jong <jongk@linux-m68k.org>
Cc: Geert Uytterhoeven <geert@linux-m68k.org>,
linux-m68k@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/4] m68k/mac: More printk modernization
Date: Sat, 28 Oct 2017 09:35:45 +1100 (AEDT) [thread overview]
Message-ID: <alpine.LNX.2.00.1710280923440.3@nippy.intranet> (raw)
In-Reply-To: <CACz-3riWPO6Kef8mtSHWp=zm0Tzi5P-GvbRdgqp6RTSwauOrYg@mail.gmail.com>
On Fri, 27 Oct 2017, Kars de Jong wrote:
> 2017-10-27 4:45 GMT+02:00 Finn Thain <fthain@telegraphics.com.au>:
> > Log message fragments used to be printed on one line but now get split
> > up. Fix this. Also, suppress log spam that merely prints known pointer
> > values.
> >
> > Tested-by: Stan Johnson <userm57@yahoo.com>
> > Signed-off-by: Finn Thain <fthain@telegraphics.com.au>
> > ---
> > arch/m68k/mac/baboon.c | 2 +-
> > arch/m68k/mac/iop.c | 4 ++--
> > arch/m68k/mac/psc.c | 6 ++----
> > arch/m68k/mac/via.c | 18 +++++-------------
> > 4 files changed, 10 insertions(+), 20 deletions(-)
>
> ...
>
> > diff --git a/arch/m68k/mac/psc.c b/arch/m68k/mac/psc.c
> > index 439a2a2e5874..8d547df4e16c 100644
> > --- a/arch/m68k/mac/psc.c
> > +++ b/arch/m68k/mac/psc.c
> > @@ -42,7 +42,7 @@ static void psc_debug_dump(void)
> > return;
> >
> > for (i = 0x30 ; i < 0x70 ; i += 0x10) {
> > - printk("PSC #%d: IFR = 0x%02X IER = 0x%02X\n",
> > + printk(KERN_DEBUG "PSC #%d: IFR = 0x%02X IER = 0x%02X\n",
> > i >> 4,
> > (int) psc_read_byte(pIFRbase + i),
> > (int) psc_read_byte(pIERbase + i));
>
> Any particular reason why you didn't use pr_debug() here? I'm guessing
> it's because this is not a known pointer value?
>
It's because the call to psc_debug_dump() is already conditional on #ifdef
DEBUG_PSC.
Having the printk conditional on both DEBUG and DEBUG_PSC would be
annoying. And I didn't want an unconditional call to psc_debug_dump()
because I think PSC_DEBUG could become more useful given that PSC support
is woefully incomplete.
Generally, I like to avoid pr_debug(). But printk() now works differently,
and now I have to avoid pr_cont(). And if I can avoid pr_cont() then it
actually makes sense to use pr_debug().
--
> Kars.
> --
> To unsubscribe from this list: send the line "unsubscribe linux-m68k" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
>
next prev parent reply other threads:[~2017-10-27 22:35 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-10-27 2:45 [PATCH 0/4] m68k/mac: Various cleanups and fixes Finn Thain
2017-10-27 2:45 ` [PATCH 2/4] m68k/mac: Disentangle VIA and OSS initialization Finn Thain
2017-10-27 11:00 ` Kars de Jong
2017-10-27 11:02 ` Kars de Jong
[not found] ` <CACz-3rgGZcdd3RZZm8Q7PxVtWsMmYLaXk_qEnb8LN2oUHSz6pQ@mail.gmail.com>
2017-10-27 22:23 ` Finn Thain
2017-10-27 2:45 ` [PATCH 4/4] m68k/mac: Add mutual exclusion for IOP interrupt polling Finn Thain
2017-10-27 2:45 ` [PATCH 1/4] m68k/mac: More printk modernization Finn Thain
2017-10-27 10:59 ` Kars de Jong
2017-10-27 22:35 ` Finn Thain [this message]
2017-10-28 2:04 ` Finn Thain
2017-10-27 2:45 ` [PATCH 3/4] m68k/mac: Disentangle VIA/RBV and NuBus initialization Finn Thain
2017-11-09 22:09 ` [PATCH 0/4] m68k/mac: Various cleanups and fixes Geert Uytterhoeven
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=alpine.LNX.2.00.1710280923440.3@nippy.intranet \
--to=fthain@telegraphics.com.au \
--cc=geert@linux-m68k.org \
--cc=jongk@linux-m68k.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-m68k@vger.kernel.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