arm64: mm: Fix unused variable warning in zone_sizes_init
authorNathan Chancellor <natechancellor@gmail.com>
Wed, 16 Oct 2019 14:47:14 +0000 (07:47 -0700)
committerCatalin Marinas <catalin.marinas@arm.com>
Wed, 16 Oct 2019 15:06:27 +0000 (16:06 +0100)
commit4399d430700d3974ed6c5a1b1380bc6527f17e99
tree8aecd6124857b3cb091eb9e10fd5aace6dc6122c
parent734f9246e791d8da278957b2c326d7709b2a97c0
arm64: mm: Fix unused variable warning in zone_sizes_init

When building arm64 allnoconfig, CONFIG_ZONE_DMA and CONFIG_ZONE_DMA32
get disabled so there is a warning about max_dma being unused.

../arch/arm64/mm/init.c:215:16: warning: unused variable 'max_dma'
[-Wunused-variable]
        unsigned long max_dma = min;
                      ^
1 warning generated.

Add __maybe_unused to make this clear to the compiler.

Fixes: 1a8e1cef7603 ("arm64: use both ZONE_DMA and ZONE_DMA32")
Reviewed-by: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
arch/arm64/mm/init.c