From: John Ogness <john.ogness@linutronix.de>
To: Ruifeng Zhang <ruifeng.zhang0110@gmail.com>,
pmladek@suse.com, senozhatsky@chromium.org, rostedt@goodmis.org
Cc: linux-kernel@vger.kernel.org, ruifeng.zhang1@unisoc.com,
nianfu.bai@unisoc.com, orson.zhai@unisoc.com
Subject: Re: [PATCH v1 1/1] printk: always output coreid in caller information
Date: Wed, 19 May 2021 10:25:32 +0200 [thread overview]
Message-ID: <87v97ft9j7.fsf@jogness.linutronix.de> (raw)
In-Reply-To: <20210519063355.5147-1-ruifeng.zhang0110@gmail.com>
Hello Ruifeng,
On 2021-05-19, Ruifeng Zhang <ruifeng.zhang0110@gmail.com> wrote:
> From: Ruifeng Zhang <ruifeng.zhang1@unisoc.com>
>
> Sometimes we want to know which cpu the process is running
> on when the log output, rather than the thread id. So add
> the processor id output always in the caller information.
>
> caller_id bitmap:
> [63:32] thread_id
> [31] flags of in thread context
> [30:0] processor id
The primary purpose of @caller_id is so that the printk-subsystem can
coordinate LOG_CONT messages.
Your patch is about logging/printing additional context attributes of
the printk-caller. This is something we have discussed before [0]. I
think this should be addressed at some point. But we need to come up
with a solution that is flexible and generic. We should not be touching
these core structures every time some new attribute needs to be printed.
Also, this patch is controversial for other reasons:
- it adds bitwise logic, when it could more easily just add a new field
(for example, caller_cpu)
- it increases the size of all records by 4 bytes
- it changes the internal structure in a way that breaks existing crash
tools
- for non-task contexts, the increased size is wasted
John Ogness
[0] https://lore.kernel.org/lkml/20200904082438.20707-1-changki.kim@samsung.com
next prev parent reply other threads:[~2021-05-19 8:25 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-19 6:33 Ruifeng Zhang
2021-05-19 8:25 ` John Ogness [this message]
2021-05-19 9:24 ` Ruifeng Zhang
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=87v97ft9j7.fsf@jogness.linutronix.de \
--to=john.ogness@linutronix.de \
--cc=linux-kernel@vger.kernel.org \
--cc=nianfu.bai@unisoc.com \
--cc=orson.zhai@unisoc.com \
--cc=pmladek@suse.com \
--cc=rostedt@goodmis.org \
--cc=ruifeng.zhang0110@gmail.com \
--cc=ruifeng.zhang1@unisoc.com \
--cc=senozhatsky@chromium.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