Messages in this thread Patch in this message | | | From | Tiezhu Yang <> | Subject | [PATCH v2 2/2] clk: Remove CONFIG_ARCH_HISI check for subdir hisilicon in Makefile | Date | Wed, 27 May 2020 15:15:43 +0800 |
| |
If CONFIG_ARCH_HISI is not set but COMPILE_TEST is set, some files in the subdir hisilicon can not be built due to CONFIG_ARCH_HISI check in drivers/clk/Makefile.
Since the related configs in drivers/clk/hisilicon/Kconfig depend on ARCH_HISI, so remove CONFIG_ARCH_HISI check for subdir hisilicon in drivers/clk/Makefile.
At the same time, we should add CONFIG_ARCH_HISI check for the common files in drivers/clk/hisilicon/Makefile, otherwise there exists build failure about undefined reference function when both CONFIG_ARCH_HISI and COMPILE_TEST are not set.
Link: https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org/thread/AVXZQX33S7ZVVK7D5VKLTTH7MOBEEBNB/ Reported-by: kbuild test robot <lkp@intel.com> Signed-off-by: Tiezhu Yang <yangtiezhu@loongson.cn> ---
v2: - Fix the build failure reported by kbuild test robot
drivers/clk/Makefile | 2 +- drivers/clk/hisilicon/Makefile | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/clk/Makefile b/drivers/clk/Makefile index f4169cc..81045ec 100644 --- a/drivers/clk/Makefile +++ b/drivers/clk/Makefile @@ -79,7 +79,7 @@ obj-y += bcm/ obj-$(CONFIG_ARCH_BERLIN) += berlin/ obj-$(CONFIG_ARCH_DAVINCI) += davinci/ obj-$(CONFIG_H8300) += h8300/ -obj-$(CONFIG_ARCH_HISI) += hisilicon/ +obj-y += hisilicon/ obj-y += imgtec/ obj-y += imx/ obj-y += ingenic/ diff --git a/drivers/clk/hisilicon/Makefile b/drivers/clk/hisilicon/Makefile index b2441b9..4695d6c 100644 --- a/drivers/clk/hisilicon/Makefile +++ b/drivers/clk/hisilicon/Makefile @@ -3,7 +3,7 @@ # Hisilicon Clock specific Makefile # -obj-y += clk.o clkgate-separated.o clkdivider-hi6220.o clk-hisi-phase.o +obj-$(CONFIG_ARCH_HISI) += clk.o clkgate-separated.o clkdivider-hi6220.o clk-hisi-phase.o obj-$(CONFIG_ARCH_HI3xxx) += clk-hi3620.o obj-$(CONFIG_ARCH_HIP04) += clk-hip04.o -- 2.1.0
| |