mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Joe Perches <joe@perches.com>
To: Jae Hyun Yoo <jae.hyun.yoo@linux.intel.com>,
	Brendan Higgins <brendanhiggins@google.com>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>,
	Joel Stanley <joel@jms.id.au>, Andrew Jeffery <andrew@aj.id.au>,
	linux-i2c@vger.kernel.org,
	OpenBMC Maillist <openbmc@lists.ozlabs.org>,
	Linux ARM <linux-arm-kernel@lists.infradead.org>,
	linux-aspeed@lists.ozlabs.org,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	jarkko.nikula@linux.intel.com, james.feist@linux.intel.com,
	vernon.mauery@linux.intel.com
Subject: Re: [PATCH] i2c: aspeed: Add newline characters into message printings.
Date: Wed, 11 Jul 2018 10:10:03 -0700	[thread overview]
Message-ID: <c13fc12e859f7bdb300f08ad805cdf6d7ec09f52.camel@perches.com> (raw)
In-Reply-To: <2d2f2b2b-394a-506f-c870-33520335250b@linux.intel.com>

On Wed, 2018-07-11 at 09:53 -0700, Jae Hyun Yoo wrote:
> On 7/10/2018 10:42 PM, Brendan Higgins wrote:
> > On Mon, Jul 2, 2018 at 2:14 PM Jae Hyun Yoo <jae.hyun.yoo@linux.intel.com> wrote:
> > > There are some log printing without a newline character. This
> > > patch adds the missing newline characters.
[]
> > > diff --git a/drivers/i2c/busses/i2c-aspeed.c b/drivers/i2c/busses/i2c-aspeed.c
[]
> > > @@ -431,7 +431,7 @@ static bool aspeed_i2c_master_irq(struct aspeed_i2c_bus *bus)
> > >           */
> > >          if (bus->master_state == ASPEED_I2C_MASTER_START) {
> > >                  if (unlikely(!(irq_status & ASPEED_I2CD_INTR_TX_ACK))) {
> > > -                       pr_devel("no slave present at %02x", msg->addr);
> > > +                       pr_devel("no slave present at %02x\n", msg->addr);
> > 
> > Unless something changed in the last couple versions of the kernel, this is the
> > only line that actually changes anything. dev_* inserts a newline for every
> > call.

Not true.

Any printk without KERN_CONT inserts a newline
if the last character
emitted is not a newline.

dev_<level> uses can also be followed by pr_cont.

So this patch does reduce the possibility of
interleaved messages from multiple processes.

  reply	other threads:[~2018-07-11 17:10 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-07-02 21:13 Jae Hyun Yoo
2018-07-11  5:42 ` Brendan Higgins
2018-07-11 16:53   ` Jae Hyun Yoo
2018-07-11 17:10     ` Joe Perches [this message]
2018-07-12  8:38       ` Brendan Higgins
2018-07-12 17:10         ` Jae Hyun Yoo
2018-07-20 22:25 ` Wolfram Sang

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=c13fc12e859f7bdb300f08ad805cdf6d7ec09f52.camel@perches.com \
    --to=joe@perches.com \
    --cc=andrew@aj.id.au \
    --cc=benh@kernel.crashing.org \
    --cc=brendanhiggins@google.com \
    --cc=jae.hyun.yoo@linux.intel.com \
    --cc=james.feist@linux.intel.com \
    --cc=jarkko.nikula@linux.intel.com \
    --cc=joel@jms.id.au \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-aspeed@lists.ozlabs.org \
    --cc=linux-i2c@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=openbmc@lists.ozlabs.org \
    --cc=vernon.mauery@linux.intel.com \
    /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

all inboxes | Powered by JetHome®