lkml.org 
[lkml]   [2018]   [Apr]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] x86/mm: vmemmap and vmalloc base addressess are usngined longs
On Mon, Apr 16, 2018 at 09:43:02AM +0000, Jiri Kosina wrote:
> On Thu, 12 Apr 2018, Kirill A. Shutemov wrote:
>
> > > Commits 9b46a051e4 ("x86/mm: Initialize vmemmap_base at boot-time") and
> > > a7412546d8 ("x86/mm: Adjust vmalloc base and size at boot-time") lost the
> > > type information for __VMALLOC_BASE_L4, __VMALLOC_BASE_L5,
> > > __VMEMMAP_BASE_L4 and __VMEMMAP_BASE_L5 constants.
> > >
> > > Let's declare them explicitly unsigned long again.
> >
> > It is just cosmetics, right? I mean these literals are 'unsigned long'
> > anyway.
>
> Yeah, I can't imagine this particular case leading to any overflow
> scenario, as the literal is big enough to be automatically treated as
> unsigned long by the compiler, but it shuts up sparse which treats this as
> a generic case (where the missing UL might be a problem), and totally
> pollutes the build output.
>
> Either we put the 'UL' there, or teach sparse about figuring out the
> 'closer bigger fitting type' for hexadecimal literals, which might be more
> tricky.

I don't have a problem with the patch:

Acked-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>

--
Kirill A. Shutemov

\
 
 \ /
  Last update: 2018-04-16 11:46    [W:0.056 / U:6.976 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site