linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Christophe Leroy <christophe.leroy@csgroup.eu>,
	Benjamin Herrenschmidt <benh@kernel.crashing.org>,
	Paul Mackerras <paulus@samba.org>,
	Michael Ellerman <mpe@ellerman.id.au>
Cc: kbuild-all@lists.01.org, linux-kernel@vger.kernel.org,
	linuxppc-dev@lists.ozlabs.org
Subject: Re: [PATCH v1 3/8] powerpc: Set user/kernel boundary at TASK_SIZE instead of PAGE_OFFSET
Date: Sat, 20 Jun 2020 19:25:26 +0800	[thread overview]
Message-ID: <202006201914.nHNvLo54%lkp@intel.com> (raw)
In-Reply-To: <c634cadd3ef2c9667838c4fe2bd425a72c8fcbd5.1592578278.git.christophe.leroy@csgroup.eu>

[-- Attachment #1: Type: text/plain, Size: 8599 bytes --]

Hi Christophe,

I love your patch! Yet something to improve:

[auto build test ERROR on powerpc/next]
[also build test ERROR on v5.8-rc1 next-20200618]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use  as documented in
https://git-scm.com/docs/git-format-patch]

url:    https://github.com/0day-ci/linux/commits/Christophe-Leroy/powerpc-32s-Allocate-modules-outside-of-vmalloc-space-for-STRICT_KERNEL_RWX/20200620-001346
base:   https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git next
config: powerpc64-randconfig-r023-20200619 (attached as .config)
compiler: powerpc64le-linux-gcc (GCC) 9.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
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=powerpc64 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All error/warnings (new ones prefixed by >>):

   In file included from arch/powerpc/include/asm/book3s/64/mmu-hash.h:22,
                    from arch/powerpc/include/asm/book3s/64/mmu.h:46,
                    from arch/powerpc/include/asm/mmu.h:348,
                    from arch/powerpc/include/asm/lppaca.h:47,
                    from arch/powerpc/include/asm/paca.h:17,
                    from arch/powerpc/include/asm/current.h:13,
                    from include/linux/thread_info.h:21,
                    from include/asm-generic/preempt.h:5,
                    from ./arch/powerpc/include/generated/asm/preempt.h:1,
                    from include/linux/preempt.h:78,
                    from include/linux/spinlock.h:51,
                    from include/linux/seqlock.h:36,
                    from include/linux/time.h:6,
                    from include/linux/compat.h:10,
                    from arch/powerpc/kernel/asm-offsets.c:14:
   arch/powerpc/include/asm/book3s/64/mmu-hash.h: In function 'get_kernel_vsid':
>> arch/powerpc/include/asm/task_size_64.h:48:3: error: implicit declaration of function 'test_tsk_thread_flag' [-Werror=implicit-function-declaration]
      48 |  (test_tsk_thread_flag(tsk, TIF_32BIT) ? TASK_SIZE_USER32 : \
         |   ^~~~~~~~~~~~~~~~~~~~
>> arch/powerpc/include/asm/task_size_64.h:51:19: note: in expansion of macro 'TASK_SIZE_OF'
      51 | #define TASK_SIZE TASK_SIZE_OF(current)
         |                   ^~~~~~~~~~~~
>> arch/powerpc/include/asm/page.h:259:35: note: in expansion of macro 'TASK_SIZE'
     259 | #define is_kernel_addr(x) ((x) >= TASK_SIZE)
         |                                   ^~~~~~~~~
>> arch/powerpc/include/asm/book3s/64/mmu-hash.h:836:7: note: in expansion of macro 'is_kernel_addr'
     836 |  if (!is_kernel_addr(ea))
         |       ^~~~~~~~~~~~~~
>> arch/powerpc/include/asm/task_size_64.h:51:32: error: 'current' undeclared (first use in this function)
      51 | #define TASK_SIZE TASK_SIZE_OF(current)
         |                                ^~~~~~~
   arch/powerpc/include/asm/task_size_64.h:48:24: note: in definition of macro 'TASK_SIZE_OF'
      48 |  (test_tsk_thread_flag(tsk, TIF_32BIT) ? TASK_SIZE_USER32 : \
         |                        ^~~
>> arch/powerpc/include/asm/page.h:259:35: note: in expansion of macro 'TASK_SIZE'
     259 | #define is_kernel_addr(x) ((x) >= TASK_SIZE)
         |                                   ^~~~~~~~~
>> arch/powerpc/include/asm/book3s/64/mmu-hash.h:836:7: note: in expansion of macro 'is_kernel_addr'
     836 |  if (!is_kernel_addr(ea))
         |       ^~~~~~~~~~~~~~
   arch/powerpc/include/asm/task_size_64.h:51:32: note: each undeclared identifier is reported only once for each function it appears in
      51 | #define TASK_SIZE TASK_SIZE_OF(current)
         |                                ^~~~~~~
   arch/powerpc/include/asm/task_size_64.h:48:24: note: in definition of macro 'TASK_SIZE_OF'
      48 |  (test_tsk_thread_flag(tsk, TIF_32BIT) ? TASK_SIZE_USER32 : \
         |                        ^~~
>> arch/powerpc/include/asm/page.h:259:35: note: in expansion of macro 'TASK_SIZE'
     259 | #define is_kernel_addr(x) ((x) >= TASK_SIZE)
         |                                   ^~~~~~~~~
>> arch/powerpc/include/asm/book3s/64/mmu-hash.h:836:7: note: in expansion of macro 'is_kernel_addr'
     836 |  if (!is_kernel_addr(ea))
         |       ^~~~~~~~~~~~~~
>> arch/powerpc/include/asm/task_size_64.h:48:29: error: 'TIF_32BIT' undeclared (first use in this function)
      48 |  (test_tsk_thread_flag(tsk, TIF_32BIT) ? TASK_SIZE_USER32 : \
         |                             ^~~~~~~~~
>> arch/powerpc/include/asm/task_size_64.h:51:19: note: in expansion of macro 'TASK_SIZE_OF'
      51 | #define TASK_SIZE TASK_SIZE_OF(current)
         |                   ^~~~~~~~~~~~
>> arch/powerpc/include/asm/page.h:259:35: note: in expansion of macro 'TASK_SIZE'
     259 | #define is_kernel_addr(x) ((x) >= TASK_SIZE)
         |                                   ^~~~~~~~~
>> arch/powerpc/include/asm/book3s/64/mmu-hash.h:836:7: note: in expansion of macro 'is_kernel_addr'
     836 |  if (!is_kernel_addr(ea))
         |       ^~~~~~~~~~~~~~
   In file included from include/linux/uaccess.h:5,
                    from include/linux/crypto.h:21,
                    from include/crypto/hash.h:11,
                    from include/linux/uio.h:10,
                    from include/linux/socket.h:8,
                    from include/linux/compat.h:15,
                    from arch/powerpc/kernel/asm-offsets.c:14:
   include/linux/sched.h: At top level:
>> include/linux/sched.h:1786:19: error: static declaration of 'test_tsk_thread_flag' follows non-static declaration
    1786 | static inline int test_tsk_thread_flag(struct task_struct *tsk, int flag)
         |                   ^~~~~~~~~~~~~~~~~~~~
   In file included from arch/powerpc/include/asm/book3s/64/mmu-hash.h:22,
                    from arch/powerpc/include/asm/book3s/64/mmu.h:46,
                    from arch/powerpc/include/asm/mmu.h:348,
                    from arch/powerpc/include/asm/lppaca.h:47,
                    from arch/powerpc/include/asm/paca.h:17,
                    from arch/powerpc/include/asm/current.h:13,
                    from include/linux/thread_info.h:21,
                    from include/asm-generic/preempt.h:5,
                    from ./arch/powerpc/include/generated/asm/preempt.h:1,
                    from include/linux/preempt.h:78,
                    from include/linux/spinlock.h:51,
                    from include/linux/seqlock.h:36,
                    from include/linux/time.h:6,
                    from include/linux/compat.h:10,
                    from arch/powerpc/kernel/asm-offsets.c:14:
   arch/powerpc/include/asm/task_size_64.h:48:3: note: previous implicit declaration of 'test_tsk_thread_flag' was here
      48 |  (test_tsk_thread_flag(tsk, TIF_32BIT) ? TASK_SIZE_USER32 : \
         |   ^~~~~~~~~~~~~~~~~~~~
>> arch/powerpc/include/asm/task_size_64.h:51:19: note: in expansion of macro 'TASK_SIZE_OF'
      51 | #define TASK_SIZE TASK_SIZE_OF(current)
         |                   ^~~~~~~~~~~~
>> arch/powerpc/include/asm/page.h:259:35: note: in expansion of macro 'TASK_SIZE'
     259 | #define is_kernel_addr(x) ((x) >= TASK_SIZE)
         |                                   ^~~~~~~~~
>> arch/powerpc/include/asm/book3s/64/mmu-hash.h:836:7: note: in expansion of macro 'is_kernel_addr'
     836 |  if (!is_kernel_addr(ea))
         |       ^~~~~~~~~~~~~~
   cc1: some warnings being treated as errors
   make[2]: *** [scripts/Makefile.build:114: arch/powerpc/kernel/asm-offsets.s] Error 1
   make[2]: Target '__build' not remade because of errors.
   make[1]: *** [Makefile:1188: prepare0] Error 2
   make[1]: Target 'prepare' not remade because of errors.
   make: *** [Makefile:185: __sub-make] Error 2
   make: Target 'prepare' not remade because of errors.

vim +/TASK_SIZE +259 arch/powerpc/include/asm/page.h

   251	
   252	/*
   253	 * Don't compare things with KERNELBASE or PAGE_OFFSET to test for
   254	 * "kernelness", use is_kernel_addr() - it should do what you want.
   255	 */
   256	#ifdef CONFIG_PPC_BOOK3E_64
   257	#define is_kernel_addr(x)	((x) >= 0x8000000000000000ul)
   258	#else
 > 259	#define is_kernel_addr(x)	((x) >= TASK_SIZE)
   260	#endif
   261	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 34730 bytes --]

  reply	other threads:[~2020-06-20 11:30 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-06-19 15:06 [PATCH v1 0/8] powerpc/32s: Allocate modules outside of vmalloc space for STRICT_KERNEL_RWX Christophe Leroy
2020-06-19 15:06 ` [PATCH v1 1/8] powerpc/ptdump: Refactor update of st->last_pa Christophe Leroy
2020-06-19 15:06 ` [PATCH v1 2/8] powerpc/ptdump: Refactor update of pg_state Christophe Leroy
2020-06-19 15:06 ` [PATCH v1 3/8] powerpc: Set user/kernel boundary at TASK_SIZE instead of PAGE_OFFSET Christophe Leroy
2020-06-20 11:25   ` kernel test robot [this message]
2020-06-20 11:33   ` kernel test robot
2020-06-19 15:06 ` [PATCH v1 4/8] powerpc/lib: Prepare code-patching for modules allocated outside vmalloc space Christophe Leroy
2020-06-19 15:06 ` [PATCH v1 5/8] powerpc: Use MODULES_VADDR if defined Christophe Leroy
2020-06-19 15:06 ` [PATCH v1 6/8] powerpc/32s: Only leave NX unset on segments used for modules Christophe Leroy
2020-06-19 15:06 ` [PATCH v1 7/8] powerpc/32s: Kernel space starts at TASK_SIZE Christophe Leroy
2020-06-19 15:06 ` [PATCH v1 8/8] powerpc/32s: Use dedicated segment for modules with STRICT_KERNEL_RWX Christophe Leroy

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=202006201914.nHNvLo54%lkp@intel.com \
    --to=lkp@intel.com \
    --cc=benh@kernel.crashing.org \
    --cc=christophe.leroy@csgroup.eu \
    --cc=kbuild-all@lists.01.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=mpe@ellerman.id.au \
    --cc=paulus@samba.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).