From: Athira Rajeev Date: Tue, 6 May 2025 13:52:32 +0000 (+0530) Subject: powerpc/pseries/htmdump: Include header file to get is_kvm_guest() definition X-Git-Tag: v6.16-rc1~200^2~8 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=2c54e431574f829ec0895d5104575b3f209eae28;p=thirdparty%2Fkernel%2Flinux.git powerpc/pseries/htmdump: Include header file to get is_kvm_guest() definition htmdump_init calls is_kvm_guest() to check for guest environment. is_kvm_guest() is defined in kvm_guest.h header file. Without including the header file, build hits error failing to find the function. arch/powerpc/platforms/pseries/htmdump.c: In function 'htmdump_init': arch/powerpc/platforms/pseries/htmdump.c:469:6: error: implicit declaration of function 'is_kvm_guest'; did you mean '__key_get'? [-Werror=implicit-function-declaration] if (is_kvm_guest()) { ^~~~~~~~~~~~ __key_get This is observed in configs where CONFIG_KVM_GUEST is disabled. Include header file explicitly to avoid the build error Reported-by: kernel test robot Closes: https://lore.kernel.org/oe-kbuild-all/202505061324.elUl4njU-lkp@intel.com/ Signed-off-by: Athira Rajeev Tested-by: Venkat Rao Bagalkote Signed-off-by: Madhavan Srinivasan Link: https://patch.msgid.link/20250506135232.69014-1-atrajeev@linux.ibm.com --- diff --git a/arch/powerpc/platforms/pseries/htmdump.c b/arch/powerpc/platforms/pseries/htmdump.c index af15d50c924b0..742ec52c9d4df 100644 --- a/arch/powerpc/platforms/pseries/htmdump.c +++ b/arch/powerpc/platforms/pseries/htmdump.c @@ -10,6 +10,7 @@ #include #include #include +#include static void *htm_buf; static void *htm_status_buf;