
tree: https://gitee.com/openeuler/kernel.git OLK-6.6 head: e1106320058bf1d983657f80490249b4f919ebad commit: 462dd429f52a7659ea1c74f02f7134a43fccccc8 [2220/2220] LoongArch: Add pv ipi support on guest kernel side config: loongarch-randconfig-001-20250512 (https://download.01.org/0day-ci/archive/20250512/202505122209.a4CThmkS-lkp@i...) compiler: loongarch64-linux-gcc (GCC) 13.3.0 reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250512/202505122209.a4CThmkS-lkp@i...) If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags | Reported-by: kernel test robot <lkp@intel.com> | Closes: https://lore.kernel.org/oe-kbuild-all/202505122209.a4CThmkS-lkp@intel.com/ All errors (new ones prefixed by >>): loongarch64-linux-ld: arch/loongarch/kernel/paravirt.o: in function `pv_send_ipi_mask':
arch/loongarch/kernel/paravirt.c:57:(.text+0x1f4): undefined reference to `__ashlti3'
vim +57 arch/loongarch/kernel/paravirt.c 33 34 #define KVM_IPI_CLUSTER_SIZE (2 * BITS_PER_LONG) 35 static void pv_send_ipi_mask(const struct cpumask *mask, unsigned int action) 36 { 37 unsigned int cpu, i, min = 0, max = 0, old; 38 __uint128_t bitmap = 0; 39 irq_cpustat_t *info; 40 41 if (cpumask_empty(mask)) 42 return; 43 44 action = BIT(action); 45 for_each_cpu(i, mask) { 46 info = &per_cpu(irq_stat, i); 47 old = atomic_fetch_or(action, &info->message); 48 if (old) 49 continue; 50 51 cpu = cpu_logical_map(i); 52 if (!bitmap) { 53 min = max = cpu; 54 } else if (cpu > min && cpu < min + KVM_IPI_CLUSTER_SIZE) { 55 max = cpu > max ? cpu : max; 56 } else if (cpu < min && (max - cpu) < KVM_IPI_CLUSTER_SIZE) {
57 bitmap <<= min - cpu; 58 min = cpu; 59 } else { 60 /* 61 * Physical cpuid is sorted in ascending order ascend 62 * for the next mask calculation, send IPI here 63 * directly and skip the remainding cpus 64 */ 65 kvm_hypercall3(KVM_HCALL_FUNC_PV_IPI, 66 (unsigned long)bitmap, 67 (unsigned long)(bitmap >> BITS_PER_LONG), min); 68 min = max = cpu; 69 bitmap = 0; 70 } 71 __set_bit(cpu - min, (unsigned long *)&bitmap); 72 } 73 74 if (bitmap) 75 kvm_hypercall3(KVM_HCALL_FUNC_PV_IPI, (unsigned long)bitmap, 76 (unsigned long)(bitmap >> BITS_PER_LONG), min); 77 } 78
-- 0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki