All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Vadim Fedorenko <vadfed@meta.com>,
	Alexei Starovoitov <ast@kernel.org>,
	Daniel Borkmann <daniel@iogearbox.net>,
	Andrii Nakryiko <andrii@kernel.org>,
	Eduard Zingerman <eddyz87@gmail.com>,
	Thomas Gleixner <tglx@linutronix.de>,
	Vadim Fedorenko <vadim.fedorenko@linux.dev>,
	Mykola Lysenko <mykolal@fb.com>
Cc: oe-kbuild-all@lists.linux.dev, x86@kernel.org,
	bpf@vger.kernel.org, Martin KaFai Lau <martin.lau@linux.dev>
Subject: Re: [PATCH bpf-next v6 1/4] bpf: add bpf_get_cpu_cycles kfunc
Date: Mon, 18 Nov 2024 06:55:17 +0800	[thread overview]
Message-ID: <202411180657.c0eoNysc-lkp@intel.com> (raw)
In-Reply-To: <20241115194841.2108634-2-vadfed@meta.com>

Hi Vadim,

kernel test robot noticed the following build errors:

[auto build test ERROR on bpf-next/master]

url:    https://github.com/intel-lab-lkp/linux/commits/Vadim-Fedorenko/bpf-add-bpf_get_cpu_cycles-kfunc/20241117-002106
base:   https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next.git master
patch link:    https://lore.kernel.org/r/20241115194841.2108634-2-vadfed%40meta.com
patch subject: [PATCH bpf-next v6 1/4] bpf: add bpf_get_cpu_cycles kfunc
config: x86_64-randconfig-075-20241117 (https://download.01.org/0day-ci/archive/20241118/202411180657.c0eoNysc-lkp@intel.com/config)
compiler: gcc-12 (Debian 12.2.0-14) 12.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20241118/202411180657.c0eoNysc-lkp@intel.com/reproduce)

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/202411180657.c0eoNysc-lkp@intel.com/

All errors (new ones prefixed by >>):

   ld: vmlinux.o: in function `vread_pvclock':
>> arch/x86/include/asm/vdso/gettimeofday.h:198: undefined reference to `pvclock_page'
>> ld: arch/x86/include/asm/vdso/gettimeofday.h:198: undefined reference to `pvclock_page'
   ld: vmlinux.o: in function `pvclock_read_begin':
>> arch/x86/include/asm/pvclock.h:25: undefined reference to `pvclock_page'
   ld: vmlinux.o: in function `vread_pvclock':
   arch/x86/include/asm/vdso/gettimeofday.h:228: undefined reference to `pvclock_page'
   ld: vmlinux.o: in function `__pvclock_read_cycles':
   arch/x86/include/asm/pvclock.h:86: undefined reference to `pvclock_page'
   ld: vmlinux.o:arch/x86/include/asm/pvclock.h:88: more undefined references to `pvclock_page' follow
   ld: .tmp_vmlinux1: hidden symbol `pvclock_page' isn't defined
   ld: final link failed: bad value


vim +198 arch/x86/include/asm/vdso/gettimeofday.h

7ac8707479886c Vincenzo Frascino 2019-06-21  195  
7ac8707479886c Vincenzo Frascino 2019-06-21  196  #ifdef CONFIG_PARAVIRT_CLOCK
7ac8707479886c Vincenzo Frascino 2019-06-21  197  static u64 vread_pvclock(void)
7ac8707479886c Vincenzo Frascino 2019-06-21 @198  {
ecf9db3d1f1a8f Andy Lutomirski   2019-06-22  199  	const struct pvclock_vcpu_time_info *pvti = &pvclock_page.pvti;
7ac8707479886c Vincenzo Frascino 2019-06-21  200  	u32 version;
7ac8707479886c Vincenzo Frascino 2019-06-21  201  	u64 ret;
7ac8707479886c Vincenzo Frascino 2019-06-21  202  
7ac8707479886c Vincenzo Frascino 2019-06-21  203  	/*
7ac8707479886c Vincenzo Frascino 2019-06-21  204  	 * Note: The kernel and hypervisor must guarantee that cpu ID
7ac8707479886c Vincenzo Frascino 2019-06-21  205  	 * number maps 1:1 to per-CPU pvclock time info.
7ac8707479886c Vincenzo Frascino 2019-06-21  206  	 *
7ac8707479886c Vincenzo Frascino 2019-06-21  207  	 * Because the hypervisor is entirely unaware of guest userspace
7ac8707479886c Vincenzo Frascino 2019-06-21  208  	 * preemption, it cannot guarantee that per-CPU pvclock time
7ac8707479886c Vincenzo Frascino 2019-06-21  209  	 * info is updated if the underlying CPU changes or that that
7ac8707479886c Vincenzo Frascino 2019-06-21  210  	 * version is increased whenever underlying CPU changes.
7ac8707479886c Vincenzo Frascino 2019-06-21  211  	 *
7ac8707479886c Vincenzo Frascino 2019-06-21  212  	 * On KVM, we are guaranteed that pvti updates for any vCPU are
7ac8707479886c Vincenzo Frascino 2019-06-21  213  	 * atomic as seen by *all* vCPUs.  This is an even stronger
7ac8707479886c Vincenzo Frascino 2019-06-21  214  	 * guarantee than we get with a normal seqlock.
7ac8707479886c Vincenzo Frascino 2019-06-21  215  	 *
7ac8707479886c Vincenzo Frascino 2019-06-21  216  	 * On Xen, we don't appear to have that guarantee, but Xen still
7ac8707479886c Vincenzo Frascino 2019-06-21  217  	 * supplies a valid seqlock using the version field.
7ac8707479886c Vincenzo Frascino 2019-06-21  218  	 *
7ac8707479886c Vincenzo Frascino 2019-06-21  219  	 * We only do pvclock vdso timing at all if
7ac8707479886c Vincenzo Frascino 2019-06-21  220  	 * PVCLOCK_TSC_STABLE_BIT is set, and we interpret that bit to
7ac8707479886c Vincenzo Frascino 2019-06-21  221  	 * mean that all vCPUs have matching pvti and that the TSC is
7ac8707479886c Vincenzo Frascino 2019-06-21  222  	 * synced, so we can just look at vCPU 0's pvti.
7ac8707479886c Vincenzo Frascino 2019-06-21  223  	 */
7ac8707479886c Vincenzo Frascino 2019-06-21  224  
7ac8707479886c Vincenzo Frascino 2019-06-21  225  	do {
7ac8707479886c Vincenzo Frascino 2019-06-21  226  		version = pvclock_read_begin(pvti);
7ac8707479886c Vincenzo Frascino 2019-06-21  227  
7ac8707479886c Vincenzo Frascino 2019-06-21  228  		if (unlikely(!(pvti->flags & PVCLOCK_TSC_STABLE_BIT)))
7ac8707479886c Vincenzo Frascino 2019-06-21  229  			return U64_MAX;
7ac8707479886c Vincenzo Frascino 2019-06-21  230  
7ac8707479886c Vincenzo Frascino 2019-06-21  231  		ret = __pvclock_read_cycles(pvti, rdtsc_ordered());
7ac8707479886c Vincenzo Frascino 2019-06-21  232  	} while (pvclock_read_retry(pvti, version));
7ac8707479886c Vincenzo Frascino 2019-06-21  233  
77750f78b0b324 Peter Zijlstra    2023-05-19  234  	return ret & S64_MAX;
7ac8707479886c Vincenzo Frascino 2019-06-21  235  }
7ac8707479886c Vincenzo Frascino 2019-06-21  236  #endif
7ac8707479886c Vincenzo Frascino 2019-06-21  237  

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

  parent reply	other threads:[~2024-11-17 22:55 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-11-15 19:48 [PATCH bpf-next v6 0/4] bpf: add cpu cycles kfuncss Vadim Fedorenko
2024-11-15 19:48 ` [PATCH bpf-next v6 1/4] bpf: add bpf_get_cpu_cycles kfunc Vadim Fedorenko
2024-11-15 21:54   ` Yonghong Song
2024-11-17 18:11     ` Vadim Fedorenko
2024-11-17 21:58       ` Yonghong Song
2024-11-17  5:58   ` kernel test robot
2024-11-17 22:55   ` kernel test robot [this message]
2024-11-15 19:48 ` [PATCH bpf-next v6 2/4] bpf: add bpf_cpu_cycles_to_ns helper Vadim Fedorenko
2024-11-15 19:48 ` [PATCH bpf-next v6 3/4] selftests/bpf: add selftest to check rdtsc jit Vadim Fedorenko
2024-11-15 19:48 ` [PATCH bpf-next v6 4/4] selftests/bpf: add usage example for cpu cycles kfuncs Vadim Fedorenko
2024-11-15 20:15 ` [PATCH bpf-next v6 0/4] bpf: add cpu cycles kfuncss Borislav Petkov
2024-11-15 20:30   ` Vadim Fedorenko
2024-11-15 22:21 ` Andrii Nakryiko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=202411180657.c0eoNysc-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=andrii@kernel.org \
    --cc=ast@kernel.org \
    --cc=bpf@vger.kernel.org \
    --cc=daniel@iogearbox.net \
    --cc=eddyz87@gmail.com \
    --cc=martin.lau@linux.dev \
    --cc=mykolal@fb.com \
    --cc=oe-kbuild-all@lists.linux.dev \
    --cc=tglx@linutronix.de \
    --cc=vadfed@meta.com \
    --cc=vadim.fedorenko@linux.dev \
    --cc=x86@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.