lkml.org 
[lkml]   [2021]   [Nov]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    Subject[toke:xdp-traffic-gen-01 8/10] net/bpf/test_run.c:160: undefined reference to `page_pool_create'
    tree:   https://git.kernel.org/pub/scm/linux/kernel/git/toke/linux.git xdp-traffic-gen-01
    head: a7f4d7f9e215d1e540f81f6cd3f5b46d970c5449
    commit: fcc7154eccb6e67d55d0cf407d4ce95c49042a5a [8/10] bpf: Add XDP_REDIRECT support to XDP for bpf_prog_run()
    config: x86_64-randconfig-a013-20211116 (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/toke/linux.git/commit/?id=fcc7154eccb6e67d55d0cf407d4ce95c49042a5a
    git remote add toke https://git.kernel.org/pub/scm/linux/kernel/git/toke/linux.git
    git fetch --no-tags toke xdp-traffic-gen-01
    git checkout fcc7154eccb6e67d55d0cf407d4ce95c49042a5a
    # 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@intel.com>

    All errors (new ones prefixed by >>):

    vmlinux.o: warning: objtool: do_machine_check()+0x6d1: call to queue_task_work() leaves .noinstr.text section
    vmlinux.o: warning: objtool: enter_from_user_mode()+0x4e: call to on_thread_stack() leaves .noinstr.text section
    vmlinux.o: warning: objtool: syscall_enter_from_user_mode()+0x53: call to on_thread_stack() leaves .noinstr.text section
    vmlinux.o: warning: objtool: syscall_enter_from_user_mode_prepare()+0x4e: call to on_thread_stack() leaves .noinstr.text section
    vmlinux.o: warning: objtool: irqentry_enter_from_user_mode()+0x4e: call to on_thread_stack() leaves .noinstr.text section
    ld: net/bpf/test_run.o: in function `bpf_test_run_xdp_setup':
    >> net/bpf/test_run.c:160: undefined reference to `page_pool_create'


    vim +160 net/bpf/test_run.c

    144
    145 static int bpf_test_run_xdp_setup(struct bpf_test_timer *t, struct xdp_buff *orig_ctx)
    146 {
    147 struct xdp_mem_info mem = {};
    148 struct page_pool *pp;
    149 int err;
    150 struct page_pool_params pp_params = {
    151 .order = 0,
    152 .flags = 0,
    153 .pool_size = NAPI_POLL_WEIGHT * 2,
    154 .nid = NUMA_NO_NODE,
    155 .max_len = TEST_XDP_FRAME_SIZE,
    156 .init_callback = bpf_test_run_xdp_init_page,
    157 .init_arg = t,
    158 };
    159
    > 160 pp = page_pool_create(&pp_params);
    161 if (IS_ERR(pp))
    162 return PTR_ERR(pp);
    163
    164 /* will copy 'mem->id' into pp->xdp_mem_id */
    165 err = xdp_reg_mem_model(&mem, MEM_TYPE_PAGE_POOL, pp);
    166 if (err) {
    167 page_pool_destroy(pp);
    168 return err;
    169 }
    170 t->xdp.pp = pp;
    171
    172 /* We create a 'fake' RXQ referencing the original dev, but with an
    173 * xdp_mem_info pointing to our page_pool
    174 */
    175 xdp_rxq_info_reg(&t->xdp.rxq, orig_ctx->rxq->dev, 0, 0);
    176 t->xdp.rxq.mem.type = MEM_TYPE_PAGE_POOL;
    177 t->xdp.rxq.mem.id = pp->xdp_mem_id;
    178 t->xdp.orig_ctx = orig_ctx;
    179
    180 return 0;
    181 }
    182

    ---
    0-DAY CI Kernel Test Service, Intel Corporation
    https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
    [unhandled content-type:application/gzip]
    \
     
     \ /
      Last update: 2021-11-17 07:18    [W:6.238 / U:1.148 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site