lkml.org 
[lkml]   [2017]   [Nov]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] mm/page_alloc: Avoid KERN_CONT uses in warn_alloc
From
Date
On Tue, 2017-11-07 at 16:43 +0100, Michal Hocko wrote:
> On Tue 07-11-17 07:34:25, Joe Perches wrote:
[]
> > I believe, but have not tested, that using a specific width
> > as an argument to %*pb[l] will constrain the number of
> > spaces before the '(null)' output in any NULL pointer use.
> >
> > So how about a #define like
> >
> > /*
> > * nodemask_pr_args is only used with a "%*pb[l]" format for a nodemask.
> > * A NULL nodemask uses 6 to emit "(null)" without leading spaces.
> > */
> > #define nodemask_pr_args(maskp) \
> > (maskp) ? MAX_NUMNODES : 6, \
> > (maskp) ? (maskp)->bits : NULL
>
> Why not -1 then?

I believe it's the field width and not the precision that
needs to be set.

But if you test it and it works, then that's fine by me.

\
 
 \ /
  Last update: 2017-11-08 21:06    [W:0.098 / U:0.328 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site