From: Timur Tabi <timur@kernel.org>
To: Marco Elver <elver@google.com>
Cc: Petr Mladek <pmladek@suse.com>,
LKML <linux-kernel@vger.kernel.org>,
Vlastimil Babka <vbabka@suse.cz>,
Steven Rostedt <rostedt@goodmis.org>,
Sergey Senozhatsky <sergey.senozhatsky@gmail.com>,
Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
Rasmus Villemoes <linux@rasmusvillemoes.dk>,
Geert Uytterhoeven <geert@linux-m68k.org>
Subject: Re: [PATCH 2/2] lib/vsprintf: reduce space taken by no_hash_pointers warning
Date: Thu, 11 Mar 2021 21:46:16 -0600 [thread overview]
Message-ID: <CAOZdJXUS6DJAtF2M7Rs28yzSOjRheLodL_F50wsrEFN_0upDPQ@mail.gmail.com> (raw)
In-Reply-To: <CANpmjNPTXPWZyPTqYZKdnvcbHP+ZOa0ce0Md5EE6GViQMyeTOw@mail.gmail.com>
On Mon, Mar 8, 2021 at 4:51 AM Marco Elver <elver@google.com> wrote:
> If we do __initconst change we need to manually remove the duplicate
> lines because we're asking the compiler to create a large array (and
> there's no more auto-dedup). If we do not remove the duplicate lines,
> the __initconst-only approach would create a larger image and result
> in subtly increased memory consumption during init. The additional
> code together with manual dedup should offset that. (I can split this
> patch as Andy suggests, but first need confirmation what people
> actually want.)
>
> I have no idea what the right trade-off is, and appeal to Geert to
> suggest what would be acceptable to him.
Maybe we can have only the message itself wrapped in an #ifdef CONFIG_
of some kind. For example:
+#ifndef CONFIG_CC_OPTIMIZE_FOR_SIZE
pr_warn("**********************************************************\n");
pr_warn("** NOTICE NOTICE NOTICE NOTICE NOTICE NOTICE NOTICE **\n");
pr_warn("** **\n");
pr_warn("** This system shows unhashed kernel memory addresses **\n");
...
+#endif
return 0;
}
In other words, if space is really constrained, then don't include the
message. Or maybe just include part of the message.
next prev parent reply other threads:[~2021-03-12 3:47 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-05 19:42 [PATCH 1/2] lib/vsprintf: do not show no_hash_pointers message multiple times Marco Elver
2021-03-05 19:42 ` [PATCH 2/2] lib/vsprintf: reduce space taken by no_hash_pointers warning Marco Elver
2021-03-06 20:27 ` Timur Tabi
2021-03-08 10:16 ` Petr Mladek
2021-03-08 10:51 ` Marco Elver
2021-03-12 3:46 ` Timur Tabi [this message]
2021-03-08 12:22 ` Geert Uytterhoeven
2021-03-08 17:23 ` Petr Mladek
2021-03-08 18:23 ` Marco Elver
2021-03-08 18:36 ` Andy Shevchenko
2021-03-09 9:12 ` David Laight
2021-03-08 10:33 ` Andy Shevchenko
2021-03-08 10:01 ` [PATCH 1/2] lib/vsprintf: do not show no_hash_pointers message multiple times Petr Mladek
2021-03-17 19:34 ` Marco Elver
2021-03-19 10:40 ` Petr Mladek
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=CAOZdJXUS6DJAtF2M7Rs28yzSOjRheLodL_F50wsrEFN_0upDPQ@mail.gmail.com \
--to=timur@kernel.org \
--cc=andriy.shevchenko@linux.intel.com \
--cc=elver@google.com \
--cc=geert@linux-m68k.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@rasmusvillemoes.dk \
--cc=pmladek@suse.com \
--cc=rostedt@goodmis.org \
--cc=sergey.senozhatsky@gmail.com \
--cc=vbabka@suse.cz \
/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).