xpmem icon indicating copy to clipboard operation
xpmem copied to clipboard

Fail to build on 5.8/x86_64: implicit declaration of function 'flush_tlb_mm_range'

Open tzafrir-mellanox opened this issue 4 years ago • 2 comments

I tried building xpmem with kernel 5.11 and got the following error:

  CC [M]  /home/tzafrirc/Proj/Packs/xpmem/xpmem/kernel/xpmem_mmu_notifier.o
In file included from /home/tzafrirc/Proj/Packs/xpmem/xpmem/kernel/xpmem_mmu_notifier.c:20:
./arch/x86/include/asm/tlb.h: In function ‘tlb_flush’:
./arch/x86/include/asm/tlb.h:24:2: error: implicit declaration of function ‘flush_tlb_mm_range’; did you mean ‘flush_icache_range’? [-Werror=implicit-function-declaration]
   24 |  flush_tlb_mm_range(tlb->mm, start, end, stride_shift, tlb->freed_tables);
      |  ^~~~~~~~~~~~~~~~~~
      |  flush_icache_range

Kernel 5.7 is OK but kernel 5.8 onwards break. I tried changing the order of includes to place asm/tlbflush.h before asm/tlb.h but I see that this function does not seem to be available for modules.

tzafrir-mellanox avatar Feb 23 '21 10:02 tzafrir-mellanox

I'm seeing this issue as well.

rzambre avatar Jun 10 '21 21:06 rzambre

how to fix?Fixes issue https://github.com/hpc/xpmem/issues/43 of implicit decleration of flush_tlb_mm_range from ./arch/x86/include/asm/tlb.

12rookie21 avatar Apr 23 '24 06:04 12rookie21