lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <202107150013.SrWF8skX-lkp@intel.com>
Date:   Thu, 15 Jul 2021 00:27:21 +0800
From:   kernel test robot <lkp@...el.com>
To:     Michael Kelley <mikelley@...rosoft.com>
Cc:     kbuild-all@...ts.01.org, linux-kernel@...r.kernel.org,
        Wei Liu <wei.liu@...nel.org>
Subject: [hyperv-linux:hyperv-next 3/5] arch/x86/kernel/cpu/mshyperv.c:262:
 undefined reference to `ms_hyperv'

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/hyperv/linux.git hyperv-next
head:   0d9f8d427756841b79df5da8bed98dc113299637
commit: 325d7a85e1ea52c5ca82b246c332e08939b085df [3/5] Drivers: hv: Make portions of Hyper-V init code be arch neutral
config: x86_64-kexec (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce (this is a W=1 build):
        # https://git.kernel.org/pub/scm/linux/kernel/git/hyperv/linux.git/commit/?id=325d7a85e1ea52c5ca82b246c332e08939b085df
        git remote add hyperv-linux https://git.kernel.org/pub/scm/linux/kernel/git/hyperv/linux.git
        git fetch --no-tags hyperv-linux hyperv-next
        git checkout 325d7a85e1ea52c5ca82b246c332e08939b085df
        # save the attached .config to linux build tree
        mkdir build_dir
        make W=1 O=build_dir ARCH=x86_64 SHELL=/bin/bash

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@...el.com>

All errors (new ones prefixed by >>):

   ld: arch/x86/kernel/cpu/mshyperv.o: in function `ms_hyperv_init_platform':
>> arch/x86/kernel/cpu/mshyperv.c:262: undefined reference to `ms_hyperv'
>> ld: arch/x86/kernel/cpu/mshyperv.c:263: undefined reference to `ms_hyperv'
   ld: arch/x86/kernel/cpu/mshyperv.c:264: undefined reference to `ms_hyperv'
   ld: arch/x86/kernel/cpu/mshyperv.c:265: undefined reference to `ms_hyperv'
   ld: arch/x86/kernel/cpu/mshyperv.c:269: undefined reference to `ms_hyperv'
   ld: arch/x86/kernel/cpu/mshyperv.o:arch/x86/kernel/cpu/mshyperv.c:269: more undefined references to `ms_hyperv' follow
   ld: arch/x86/kernel/cpu/mshyperv.o: in function `ms_hyperv_init_platform':
>> arch/x86/kernel/cpu/mshyperv.c:291: undefined reference to `hv_root_partition'
   ld: arch/x86/kernel/cpu/mshyperv.c:310: undefined reference to `ms_hyperv'
   ld: arch/x86/kernel/cpu/mshyperv.c:310: undefined reference to `ms_hyperv'
   ld: arch/x86/kernel/cpu/mshyperv.c:316: undefined reference to `ms_hyperv'
   ld: arch/x86/kernel/cpu/mshyperv.c:317: undefined reference to `ms_hyperv'
   ld: arch/x86/kernel/cpu/mshyperv.c:320: undefined reference to `ms_hyperv'
   ld: arch/x86/kernel/cpu/mshyperv.o:arch/x86/kernel/cpu/mshyperv.c:318: more undefined references to `ms_hyperv' follow


vim +262 arch/x86/kernel/cpu/mshyperv.c

f7c0f50f1857c1 Andrea Parri             2019-10-15  258  
a2a47c6c3d1a7c Ky Srinivasan            2010-05-06  259  	/*
e08cae4181af94 H. Peter Anvin           2010-05-07  260  	 * Extract the features and hints
a2a47c6c3d1a7c Ky Srinivasan            2010-05-06  261  	 */
e08cae4181af94 H. Peter Anvin           2010-05-07 @262  	ms_hyperv.features = cpuid_eax(HYPERV_CPUID_FEATURES);
6dc2a774cb4fdb Sunil Muthuswamy         2021-03-23 @263  	ms_hyperv.priv_high = cpuid_ebx(HYPERV_CPUID_FEATURES);
cc2dd4027a43bb Denis V. Lunev           2015-08-01  264  	ms_hyperv.misc_features = cpuid_edx(HYPERV_CPUID_FEATURES);
e08cae4181af94 H. Peter Anvin           2010-05-07  265  	ms_hyperv.hints    = cpuid_eax(HYPERV_CPUID_ENLIGHTMENT_INFO);
a2a47c6c3d1a7c Ky Srinivasan            2010-05-06  266  
a6c776a952175e Vineeth Pillai           2021-06-03  267  	hv_max_functions_eax = cpuid_eax(HYPERV_CPUID_VENDOR_AND_MAX_FUNCTIONS);
a6c776a952175e Vineeth Pillai           2021-06-03  268  
6dc2a774cb4fdb Sunil Muthuswamy         2021-03-23  269  	pr_info("Hyper-V: privilege flags low 0x%x, high 0x%x, hints 0x%x, misc 0x%x\n",
6dc2a774cb4fdb Sunil Muthuswamy         2021-03-23  270  		ms_hyperv.features, ms_hyperv.priv_high, ms_hyperv.hints,
6dc2a774cb4fdb Sunil Muthuswamy         2021-03-23  271  		ms_hyperv.misc_features);
6f4151c89b7d03 K. Y. Srinivasan         2011-09-07  272  
415bd1cd3a4289 Vitaly Kuznetsov         2018-03-20  273  	ms_hyperv.max_vp_index = cpuid_eax(HYPERV_CPUID_IMPLEMENT_LIMITS);
415bd1cd3a4289 Vitaly Kuznetsov         2018-03-20  274  	ms_hyperv.max_lp_index = cpuid_ebx(HYPERV_CPUID_IMPLEMENT_LIMITS);
dd018597a074bc Vitaly Kuznetsov         2017-06-25  275  
dd018597a074bc Vitaly Kuznetsov         2017-06-25  276  	pr_debug("Hyper-V: max %u virtual processors, %u logical processors\n",
dd018597a074bc Vitaly Kuznetsov         2017-06-25  277  		 ms_hyperv.max_vp_index, ms_hyperv.max_lp_index);
dd018597a074bc Vitaly Kuznetsov         2017-06-25  278  
e997720202b363 Wei Liu                  2021-02-03  279  	/*
e997720202b363 Wei Liu                  2021-02-03  280  	 * Check CPU management privilege.
e997720202b363 Wei Liu                  2021-02-03  281  	 *
e997720202b363 Wei Liu                  2021-02-03  282  	 * To mirror what Windows does we should extract CPU management
e997720202b363 Wei Liu                  2021-02-03  283  	 * features and use the ReservedIdentityBit to detect if Linux is the
e997720202b363 Wei Liu                  2021-02-03  284  	 * root partition. But that requires negotiating CPU management
e997720202b363 Wei Liu                  2021-02-03  285  	 * interface (a process to be finalized).
e997720202b363 Wei Liu                  2021-02-03  286  	 *
e997720202b363 Wei Liu                  2021-02-03  287  	 * For now, use the privilege flag as the indicator for running as
e997720202b363 Wei Liu                  2021-02-03  288  	 * root.
e997720202b363 Wei Liu                  2021-02-03  289  	 */
e997720202b363 Wei Liu                  2021-02-03  290  	if (cpuid_ebx(HYPERV_CPUID_FEATURES) & HV_CPU_MANAGEMENT) {
e997720202b363 Wei Liu                  2021-02-03 @291  		hv_root_partition = true;
e997720202b363 Wei Liu                  2021-02-03  292  		pr_info("Hyper-V: running as root partition\n");
e997720202b363 Wei Liu                  2021-02-03  293  	}
e997720202b363 Wei Liu                  2021-02-03  294  
8de8af7e0873c4 K. Y. Srinivasan         2017-01-19  295  	/*
8de8af7e0873c4 K. Y. Srinivasan         2017-01-19  296  	 * Extract host information.
8de8af7e0873c4 K. Y. Srinivasan         2017-01-19  297  	 */
a6c776a952175e Vineeth Pillai           2021-06-03  298  	if (hv_max_functions_eax >= HYPERV_CPUID_VERSION) {
415bd1cd3a4289 Vitaly Kuznetsov         2018-03-20  299  		hv_host_info_eax = cpuid_eax(HYPERV_CPUID_VERSION);
415bd1cd3a4289 Vitaly Kuznetsov         2018-03-20  300  		hv_host_info_ebx = cpuid_ebx(HYPERV_CPUID_VERSION);
415bd1cd3a4289 Vitaly Kuznetsov         2018-03-20  301  		hv_host_info_ecx = cpuid_ecx(HYPERV_CPUID_VERSION);
415bd1cd3a4289 Vitaly Kuznetsov         2018-03-20  302  		hv_host_info_edx = cpuid_edx(HYPERV_CPUID_VERSION);
8de8af7e0873c4 K. Y. Srinivasan         2017-01-19  303  
8de8af7e0873c4 K. Y. Srinivasan         2017-01-19  304  		pr_info("Hyper-V Host Build:%d-%d.%d-%d-%d.%d\n",
8de8af7e0873c4 K. Y. Srinivasan         2017-01-19  305  			hv_host_info_eax, hv_host_info_ebx >> 16,
8de8af7e0873c4 K. Y. Srinivasan         2017-01-19  306  			hv_host_info_ebx & 0xFFFF, hv_host_info_ecx,
8de8af7e0873c4 K. Y. Srinivasan         2017-01-19  307  			hv_host_info_edx >> 24, hv_host_info_edx & 0xFFFFFF);
8de8af7e0873c4 K. Y. Srinivasan         2017-01-19  308  	}
8de8af7e0873c4 K. Y. Srinivasan         2017-01-19  309  
e1471463180ddc Joseph Salisbury         2020-09-26  310  	if (ms_hyperv.features & HV_ACCESS_FREQUENCY_MSRS &&
71c2a2d0a81f09 Vitaly Kuznetsov         2017-06-22  311  	    ms_hyperv.misc_features & HV_FEATURE_FREQUENCY_MSRS_AVAILABLE) {
71c2a2d0a81f09 Vitaly Kuznetsov         2017-06-22  312  		x86_platform.calibrate_tsc = hv_get_tsc_khz;
71c2a2d0a81f09 Vitaly Kuznetsov         2017-06-22  313  		x86_platform.calibrate_cpu = hv_get_tsc_khz;
71c2a2d0a81f09 Vitaly Kuznetsov         2017-06-22  314  	}
71c2a2d0a81f09 Vitaly Kuznetsov         2017-06-22  315  
6dc2a774cb4fdb Sunil Muthuswamy         2021-03-23  316  	if (ms_hyperv.priv_high & HV_ISOLATION) {
a6c76bb08dc7f7 Andrea Parri (Microsoft  2021-02-01  317) 		ms_hyperv.isolation_config_a = cpuid_eax(HYPERV_CPUID_ISOLATION_CONFIG);
a6c76bb08dc7f7 Andrea Parri (Microsoft  2021-02-01  318) 		ms_hyperv.isolation_config_b = cpuid_ebx(HYPERV_CPUID_ISOLATION_CONFIG);
a6c76bb08dc7f7 Andrea Parri (Microsoft  2021-02-01  319) 
a6c76bb08dc7f7 Andrea Parri (Microsoft  2021-02-01  320) 		pr_info("Hyper-V: Isolation Config: Group A 0x%x, Group B 0x%x\n",
a6c76bb08dc7f7 Andrea Parri (Microsoft  2021-02-01  321) 			ms_hyperv.isolation_config_a, ms_hyperv.isolation_config_b);
a6c76bb08dc7f7 Andrea Parri (Microsoft  2021-02-01  322) 	}
a6c76bb08dc7f7 Andrea Parri (Microsoft  2021-02-01  323) 
a6c776a952175e Vineeth Pillai           2021-06-03  324  	if (hv_max_functions_eax >= HYPERV_CPUID_NESTED_FEATURES) {
5431390b303962 Vitaly Kuznetsov         2018-03-20  325  		ms_hyperv.nested_features =
5431390b303962 Vitaly Kuznetsov         2018-03-20  326  			cpuid_eax(HYPERV_CPUID_NESTED_FEATURES);
a6c776a952175e Vineeth Pillai           2021-06-03  327  		pr_info("Hyper-V: Nested features: 0x%x\n",
a6c776a952175e Vineeth Pillai           2021-06-03  328  			ms_hyperv.nested_features);
5431390b303962 Vitaly Kuznetsov         2018-03-20  329  	}
5431390b303962 Vitaly Kuznetsov         2018-03-20  330  
a11589563e96bf Tianyu Lan               2020-04-06  331  	/*
a11589563e96bf Tianyu Lan               2020-04-06  332  	 * Hyper-V expects to get crash register data or kmsg when
a11589563e96bf Tianyu Lan               2020-04-06  333  	 * crash enlightment is available and system crashes. Set
a11589563e96bf Tianyu Lan               2020-04-06  334  	 * crash_kexec_post_notifiers to be true to make sure that
a11589563e96bf Tianyu Lan               2020-04-06  335  	 * calling crash enlightment interface before running kdump
a11589563e96bf Tianyu Lan               2020-04-06  336  	 * kernel.
a11589563e96bf Tianyu Lan               2020-04-06  337  	 */
a11589563e96bf Tianyu Lan               2020-04-06  338  	if (ms_hyperv.misc_features & HV_FEATURE_GUEST_CRASH_MSR_AVAILABLE)
a11589563e96bf Tianyu Lan               2020-04-06  339  		crash_kexec_post_notifiers = true;
a11589563e96bf Tianyu Lan               2020-04-06  340  

:::::: The code at line 262 was first introduced by commit
:::::: e08cae4181af9483b04ecfac48f01c8e5a5f27bf x86: Clean up the hypervisor layer

:::::: TO: H. Peter Anvin <hpa@...or.com>
:::::: CC: H. Peter Anvin <hpa@...or.com>

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

Download attachment ".config.gz" of type "application/gzip" (28988 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ