lkml.org 
[lkml]   [2008]   [Feb]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] fix sparse warning from include/linux/mmzone.h

* Linus Torvalds <torvalds@linux-foundation.org> wrote:

> Heh, yeah. That's a very odd way to write it.
>
> It would probably make more sense to just write it as something like
>
> struct zone *base = zone->zone_pgdat->node_zones;
>
> if (zone == base + ZONE_HIGHMEM ||
> (zone == base + ZONE_MOVABLE && zone_movable_is_highmem());
>
> instead.

missing closing parenthesis ;-)

btw., doesnt this look even nicer?:

if (zone == base + ZONE_HIGHMEM ||
(zone == base + ZONE_MOVABLE && zone_movable_is_highmem()));
[ i guess it must be Friday... ;-) ]

Ingo


\
 
 \ /
  Last update: 2008-02-08 23:31    [from the cache]
©2003-2014 Jasper Spaans. Advertise on this site