[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20e7ca5f3b7b5b473afe891e8b28c83de62bc6d6.camel@perches.com>
Date: Sun, 26 Jun 2022 14:02:31 -0700
From: Joe Perches <joe@...ches.com>
To: Kent Overstreet <kent.overstreet@...il.com>
Cc: Linus Torvalds <torvalds@...ux-foundation.org>,
Andrew Morton <akpm@...ux-foundation.org>,
David Laight <David.Laight@...lab.com>,
Petr Mladek <pmladek@...e.com>,
Steven Rostedt <rostedt@...dmis.org>,
Sergey Senozhatsky <senozhatsky@...omium.org>,
Rasmus Villemoes <linux@...musvillemoes.dk>,
Matthew Wilcox <willy@...radead.org>,
Miguel Ojeda <ojeda@...nel.org>,
Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
LKML <linux-kernel@...r.kernel.org>,
linux-mm <linux-mm@...ck.org>
Subject: Re: [RFC[ Alloc in vsprintf
On Sun, 2022-06-26 at 16:51 -0400, Kent Overstreet wrote:
> On Sun, Jun 26, 2022 at 01:39:01PM -0700, Joe Perches wrote:
> > On Sun, 2022-06-26 at 13:19 -0700, Linus Torvalds wrote:
> > > On Sun, Jun 26, 2022 at 12:53 PM Joe Perches <joe@...ches.com> wrote:
> > > >
> > > > In a reply to the printbufs thread, I wrote a proposal to use an
> > > > alloc to reduce stack in vsprintf when CONFIG_KALLSYMS is enabled.
> > > >
> > > > No one has replied to this but I think it's somewhat sensible.
> > >
> > > I think that's a bad idea.
> >
> > Somewhat sensible not sensible...
> >
> > > Those things are *literally* called from panic situations, which may
> > > be while holding core memory allocation locks, or similar.
> >
> > True, and special_hex_number was used on alloc failure.
> >
> > > Now, you are correct that the stack buffer is annoying. But I think
> > > the proper way to fix that is to say "we already *have* the target
> > > buffer, let's use it".
> >
> > OK, and that's true for all the temp stack buffers in every %p<foo>.
>
> Serious question: why are you trying to half-ass just _one_ of these functions
> when I've been working on solving stack allocations in all of them?
Because the stack use in _this_ function is quite large.
Backporting to stable would be trivial.
No so with printbufs.
> if you want to help out instead of just slag what I'm
> doing... well, it'd be nice...
Also nice to _be_ nice.
Honestly Kent, I haven't seen much of that from you.
Powered by blists - more mailing lists