of: unittest: Fix build on architectures without CONFIG_OF_ADDRESS
authorCatalin Marinas <catalin.marinas@arm.com>
Tue, 1 Dec 2020 12:47:25 +0000 (12:47 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 9 Mar 2021 10:11:15 +0000 (11:11 +0100)
commit4645271c32b440d1e0031e979a39dad46f396401
treebe01184e5d293179f3db13df1cca34d9e3cf048e
parentb70e6aacbe3207abfc32e923036bd2667f96aee4
of: unittest: Fix build on architectures without CONFIG_OF_ADDRESS

commit aed5041ef9a3f594ed9dc0bb5ee7e1bbccfd3366 upstream.

of_dma_get_max_cpu_address() is not defined if !CONFIG_OF_ADDRESS, so
return early in of_unittest_dma_get_max_cpu_address().

Fixes: 07d13a1d6120 ("of: unittest: Add test for of_dma_get_max_cpu_address()")
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Cc: Jing Xiangfeng <jingxiangfeng@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/of/unittest.c