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: <202206022035.IIZ3f4Uw-lkp@intel.com>
Date:   Thu, 2 Jun 2022 20:02:25 +0800
From:   kernel test robot <lkp@...el.com>
To:     Linus Walleij <linus.walleij@...aro.org>
Cc:     kbuild-all@...ts.01.org, linux-kernel@...r.kernel.org
Subject: [arm-integrator:kernel-in-vmalloc-v5.18-rc1 26/31]
 arch/riscv/include/asm/page.h:137:71: error: 'XIP_OFFSET' undeclared; did
 you mean

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-integrator.git kernel-in-vmalloc-v5.18-rc1
head:   9083f89a58302e92fad7f144986e307db2350aad
commit: b146654f1463caf323d67e17259aa1606330a701 [26/31] riscv: Make virt_to_pfn() a static inline
config: riscv-randconfig-r042-20220531 (https://download.01.org/0day-ci/archive/20220602/202206022035.IIZ3f4Uw-lkp@intel.com/config)
compiler: riscv64-linux-gcc (GCC) 11.3.0
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # https://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-integrator.git/commit/?id=b146654f1463caf323d67e17259aa1606330a701
        git remote add arm-integrator https://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-integrator.git
        git fetch --no-tags arm-integrator kernel-in-vmalloc-v5.18-rc1
        git checkout b146654f1463caf323d67e17259aa1606330a701
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.3.0 make.cross W=1 O=build_dir ARCH=riscv prepare

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

All errors (new ones prefixed by >>):

   WARNING: unmet direct dependencies detected for DRM_GEM_SHMEM_HELPER
   Depends on HAS_IOMEM && DRM && MMU
   Selected by
   - DRM_SSD130X && HAS_IOMEM && DRM
   In file included from arch/riscv/include/asm/page.h:12,
   from arch/riscv/include/asm/thread_info.h:11,
   from include/linux/thread_info.h:60,
   from include/asm-generic/preempt.h:5,
   from ./arch/riscv/include/generated/asm/preempt.h:1,
   from include/linux/preempt.h:78,
   from include/linux/spinlock.h:55,
   from include/linux/mmzone.h:8,
   from include/linux/gfp.h:6,
   from include/linux/mm.h:7,
   from arch/riscv/kernel/asm-offsets.c:10:
   arch/riscv/include/asm/page.h: In function 'virt_to_pfn':
   arch/riscv/include/asm/page.h:123:82: error: 'KERN_VIRT_SIZE' undeclared (first use in this function)
   123 | ((x) >= PAGE_OFFSET && (!IS_ENABLED(CONFIG_64BIT) || (x) < PAGE_OFFSET + KERN_VIRT_SIZE))
   | ^~~~~~~~~~~~~~
   include/linux/pfn.h:20:27: note: in definition of macro 'PFN_DOWN'
   20 | #define PFN_DOWN(x) ((x) >> PAGE_SHIFT)
   | ^
   arch/riscv/include/asm/page.h:165:16: note: in expansion of macro 'phys_to_pfn'
   165 | return phys_to_pfn(__pa(vaddr));
   | ^~~~~~~~~~~
   arch/riscv/include/asm/page.h:144:9: note: in expansion of macro 'is_linear_mapping'
   144 | is_linear_mapping(_x) | ^~~~~~~~~~~~~~~~~
   arch/riscv/include/asm/page.h:152:33: note: in expansion of macro '__va_to_pa_nodebug'
   152 | #define __virt_to_phys(x) __va_to_pa_nodebug(x)
   | ^~~~~~~~~~~~~~~~~~
   arch/riscv/include/asm/page.h:157:25: note: in expansion of macro '__virt_to_phys'
   157 | #define __pa(x) __virt_to_phys((unsigned long)(x))
   | ^~~~~~~~~~~~~~
   arch/riscv/include/asm/page.h:165:28: note: in expansion of macro '__pa'
   165 | return phys_to_pfn(__pa(vaddr));
   | ^~~~
   arch/riscv/include/asm/page.h:123:82: note: each undeclared identifier is reported only once for each function it appears in
   123 | ((x) >= PAGE_OFFSET && (!IS_ENABLED(CONFIG_64BIT) || (x) < PAGE_OFFSET + KERN_VIRT_SIZE))
   | ^~~~~~~~~~~~~~
   include/linux/pfn.h:20:27: note: in definition of macro 'PFN_DOWN'
   20 | #define PFN_DOWN(x) ((x) >> PAGE_SHIFT)
   | ^
   arch/riscv/include/asm/page.h:165:16: note: in expansion of macro 'phys_to_pfn'
   165 | return phys_to_pfn(__pa(vaddr));
   | ^~~~~~~~~~~
   arch/riscv/include/asm/page.h:144:9: note: in expansion of macro 'is_linear_mapping'
   144 | is_linear_mapping(_x) | ^~~~~~~~~~~~~~~~~
   arch/riscv/include/asm/page.h:152:33: note: in expansion of macro '__va_to_pa_nodebug'
   152 | #define __virt_to_phys(x) __va_to_pa_nodebug(x)
   | ^~~~~~~~~~~~~~~~~~
   arch/riscv/include/asm/page.h:157:25: note: in expansion of macro '__virt_to_phys'
   157 | #define __pa(x) __virt_to_phys((unsigned long)(x))
   | ^~~~~~~~~~~~~~
   arch/riscv/include/asm/page.h:165:28: note: in expansion of macro '__pa'
   165 | return phys_to_pfn(__pa(vaddr));
   | ^~~~
>> arch/riscv/include/asm/page.h:137:71: error: 'XIP_OFFSET' undeclared (first use in this function); did you mean
   137 | (IS_ENABLED(CONFIG_XIP_KERNEL) && _y < kernel_map.virt_addr + XIP_OFFSET) | ^~~~~~~~~~
   include/linux/pfn.h:20:27: note: in definition of macro 'PFN_DOWN'
   20 | #define PFN_DOWN(x) ((x) >> PAGE_SHIFT)
   | ^
   arch/riscv/include/asm/page.h:165:16: note: in expansion of macro 'phys_to_pfn'
   165 | return phys_to_pfn(__pa(vaddr));
   | ^~~~~~~~~~~
   arch/riscv/include/asm/page.h:145:47: note: in expansion of macro 'kernel_mapping_va_to_pa'
   145 | linear_mapping_va_to_pa(_x) : kernel_mapping_va_to_pa(_x); | ^~~~~~~~~~~~~~~~~~~~~~~
   arch/riscv/include/asm/page.h:152:33: note: in expansion of macro '__va_to_pa_nodebug'
   152 | #define __virt_to_phys(x) __va_to_pa_nodebug(x)
   | ^~~~~~~~~~~~~~~~~~
   arch/riscv/include/asm/page.h:157:25: note: in expansion of macro '__virt_to_phys'
   157 | #define __pa(x) __virt_to_phys((unsigned long)(x))
   | ^~~~~~~~~~~~~~
   arch/riscv/include/asm/page.h:165:28: note: in expansion of macro '__pa'
   165 | return phys_to_pfn(__pa(vaddr));
   | ^~~~
   Makefile arch block certs crypto drivers fs include init ipc kernel lib mm modules.builtin modules.builtin.modinfo modules.order nr_bisected scripts security sound source usr virt vmlinux.o vmlinux.symvers [scripts/Makefile.build:120: arch/riscv/kernel/asm-offsets.s] Error 1
   Target '__build' not remade because of errors.
   Makefile arch block certs crypto drivers fs include init ipc kernel lib mm modules.builtin modules.builtin.modinfo modules.order nr_bisected scripts security sound source usr virt vmlinux.o vmlinux.symvers [Makefile:1194: prepare0] Error 2
   Target 'prepare' not remade because of errors.
   make: Makefile arch block certs crypto drivers fs include init ipc kernel lib mm modules.builtin modules.builtin.modinfo modules.order nr_bisected scripts security sound source usr virt vmlinux.o vmlinux.symvers [Makefile:219: __sub-make] Error 2
   make: Target 'prepare' not remade because of errors.

Kconfig warnings: (for reference only)
   WARNING: unmet direct dependencies detected for DRM_GEM_SHMEM_HELPER
   Depends on HAS_IOMEM && DRM && MMU
   Selected by
   - DRM_SSD130X && HAS_IOMEM && DRM


vim +/XIP_OFFSET +137 arch/riscv/include/asm/page.h

2bfc6cd81bd17e Alexandre Ghiti 2021-04-11  133  
658e2c5125bbbc Alexandre Ghiti 2021-06-17  134  #define linear_mapping_va_to_pa(x)	((unsigned long)(x) - kernel_map.va_pa_offset)
44c922572952d8 Vitaly Wool     2021-04-13  135  #define kernel_mapping_va_to_pa(y) ({						\
44c922572952d8 Vitaly Wool     2021-04-13  136  	unsigned long _y = y;							\
59a27e11221338 Alexandre Ghiti 2021-07-21 @137  	(IS_ENABLED(CONFIG_XIP_KERNEL) && _y < kernel_map.virt_addr + XIP_OFFSET) ?	\
658e2c5125bbbc Alexandre Ghiti 2021-06-17  138  		((unsigned long)(_y) - kernel_map.va_kernel_xip_pa_offset) :		\
658e2c5125bbbc Alexandre Ghiti 2021-06-17  139  		((unsigned long)(_y) - kernel_map.va_kernel_pa_offset - XIP_OFFSET);	\
44c922572952d8 Vitaly Wool     2021-04-13  140  	})
7094e6acaf7ab8 Alexandre Ghiti 2021-06-04  141  

:::::: The code at line 137 was first introduced by commit
:::::: 59a27e1122133831111f9e2e40fec2307d742487 riscv: Optimize kernel virtual address conversion macro

:::::: TO: Alexandre Ghiti <alex@...ti.fr>
:::::: CC: Palmer Dabbelt <palmerdabbelt@...gle.com>

-- 
0-DAY CI Kernel Test Service
https://01.org/lkp

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ