mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@linux-foundation.org>
To: Tejun Heo <tj@kernel.org>
Cc: pmladek@suse.cz, davem@davemloft.net,
	linux-kernel@vger.kernel.org, netdev@vger.kernel.org,
	Kay Sievers <kay@vrfy.org>
Subject: Re: [PATCH 3/3] printk: implement support for extended console drivers
Date: Thu, 30 Apr 2015 14:31:28 -0700	[thread overview]
Message-ID: <20150430143128.68c2295ca18f1b872876f129@linux-foundation.org> (raw)
In-Reply-To: <1430318704-32374-4-git-send-email-tj@kernel.org>

On Wed, 29 Apr 2015 10:45:04 -0400 Tejun Heo <tj@kernel.org> wrote:

> printk log_buf keeps various metadata for each message including its
> sequence number and timestamp.  The metadata is currently available
> only through /dev/kmsg and stripped out before passed onto console
> drivers.  We want this metadata to be available to console drivers too
> so that console consumers can get full information including the
> metadata and dictionary, which among other things can be used to
> detect whether messages got lost in transit.
> 
> This patch implements support for extended console drivers.  Consoles
> can indicate that they want extended messages by setting the new
> CON_EXTENDED flag and they'll be fed messages formatted the same way
> as /dev/kmsg.
> 
>  "<level>,<sequnum>,<timestamp>,<contflag>;<message text>\n"
> 
> If extended consoles exist, in-kernel fragment assembly is disabled.
> This ensures that all messages emitted to consoles have full metadata
> including sequence number.  The contflag carries enough information to
> reassemble the fragments from the reader side trivially.  Note that
> this only affects /dev/kmsg.  Regular console and /proc/kmsg outputs
> are not affected by this change.
> 
> * Extended message formatting for console drivers is enabled iff there
>   are registered extended consoles.
> 
> * Comment describing /dev/kmsg message format updated to add missing
>   contflag field and help distinguishing variable from verbatim terms.

So if I'm understanding this correctly, the /dev/kmsg output is altered
(different cont handling) if some console registers with CON_EXTENDED
(and there are no such consoles yet, so the patch is a no-op).

If correct, this seems undesirable - registration of a CON_EXTENDED
console collaterally damages the /dev/kmsg interface?  If the user has
an app which depends on the original /dev/kmsg format then they'll be
wondered what-the-heck-just-happened?

  reply	other threads:[~2015-04-30 21:31 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-29 14:45 [PATCHSET] printk: implement extended console support Tejun Heo
2015-04-29 14:45 ` [PATCH 1/3] printk: guard the amount written per line by devkmsg_read() Tejun Heo
2015-04-29 14:45 ` [PATCH 2/3] printk: factor out message formatting from devkmsg_read() Tejun Heo
2015-04-29 14:45 ` [PATCH 3/3] printk: implement support for extended console drivers Tejun Heo
2015-04-30 21:31   ` Andrew Morton [this message]
2015-04-30 22:12     ` Tejun Heo
2015-04-30 22:15       ` Andrew Morton
2015-05-01 16:23   ` [PATCH v3 " Tejun Heo
2015-06-29  9:20   ` [PATCH " Geert Uytterhoeven
2015-06-29 15:28     ` Tejun Heo
2015-06-29 15:47       ` Geert Uytterhoeven
2015-06-29 15:49         ` Tejun Heo
2015-06-29 16:11           ` josh
2015-06-29 16:11           ` Geert Uytterhoeven
2015-06-29 16:13             ` Tejun Heo
2015-06-29 16:50               ` josh
2015-06-29 23:31               ` [PATCH v4.2-rc1] printk: make extended printk support conditional on netconsole Tejun Heo
2015-07-01 16:05                 ` Petr Mladek
2015-07-02 16:21                 ` [PATCH v2 " Tejun Heo
2015-07-03 14:07                   ` Petr Mladek
2015-07-03 15:25                     ` Tejun Heo
2015-07-03 16:22                   ` [PATCH v3 " Tejun Heo

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=20150430143128.68c2295ca18f1b872876f129@linux-foundation.org \
    --to=akpm@linux-foundation.org \
    --cc=davem@davemloft.net \
    --cc=kay@vrfy.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pmladek@suse.cz \
    --cc=tj@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

Powered by JetHome