lkml.org 
[lkml]   [2012]   [Jul]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH] mm/slob: avoid type warning about alignment value
Date
On Wednesday 11 July 2012, David Rientjes wrote:
> Wouldn't it be better to avoid this problem more generally by casting the
> __alignof__ for ARCH_{KMALLOC,SLAB}_MINALIGN to int in slab.h? All
> architectures that define these themselves will be using plain integers,
> the problem is __alignof__ returning size_t when undefined.

I thought about it but I wasn't sure if that would cover all possible
cases. My version at least is known not to introduce a different type
mismatch on another architecture.

Also, size_t seems to be the correct type here, while the untyped
definition is just an int.

Arnd


\
 
 \ /
  Last update: 2012-07-11 09:21    [from the cache]
©2003-2011 Jasper Spaans