Message ID | 1346747105-658-1-git-send-email-sachin.kamat@linaro.org |
---|---|
State | Accepted |
Headers | show |
On Tue, Sep 04, 2012 at 01:55:05PM +0530, Sachin Kamat wrote: > Silences the following sparse warning: > mm/memblock.c:249:49: warning: Using plain integer as NULL pointer > > Cc: Tejun Heo <tj@kernel.org> > Cc: Andrew Morton <akpm@linux-foundation.org> > Cc: Ingo Molnar <mingo@kernel.org> > Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Acked-by: Tejun Heo <tj@kernel.org> Thanks.
diff --git a/mm/memblock.c b/mm/memblock.c index 4d9393c..82aa349 100644 --- a/mm/memblock.c +++ b/mm/memblock.c @@ -246,7 +246,7 @@ static int __init_memblock memblock_double_array(struct memblock_type *type, min(new_area_start, memblock.current_limit), new_alloc_size, PAGE_SIZE); - new_array = addr ? __va(addr) : 0; + new_array = addr ? __va(addr) : NULL; } if (!addr) { pr_err("memblock: Failed to double %s array from %ld to %ld entries !\n",
Silences the following sparse warning: mm/memblock.c:249:49: warning: Using plain integer as NULL pointer Cc: Tejun Heo <tj@kernel.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Ingo Molnar <mingo@kernel.org> Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> --- mm/memblock.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)