All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: Re: [PATCH v20 08/12] landlock: Add syscall implementations
Date: Mon, 03 Aug 2020 07:58:03 +0800	[thread overview]
Message-ID: <202008030745.A4EINgdH%lkp@intel.com> (raw)
In-Reply-To: <20200802215903.91936-9-mic@digikod.net>

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

Hi "Mickaël,

I love your patch! Yet something to improve:

[auto build test ERROR on kselftest/next]
[also build test ERROR on pcmoore-selinux/next linus/master v5.8]
[cannot apply to security/next-testing next-20200731]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]

url:    https://github.com/0day-ci/linux/commits/Micka-l-Sala-n/Landlock-LSM/20200803-060154
base:   https://git.kernel.org/pub/scm/linux/kernel/git/shuah/linux-kselftest.git next
config: sh-allyesconfig (attached as .config)
compiler: sh4-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=sh 

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 >>):

   In file included from security/landlock/syscall.c:24:
   include/linux/syscalls.h:1008:50: warning: 'struct landlock_attr_features' declared inside parameter list will not be visible outside of this definition or declaration
    1008 | asmlinkage long sys_landlock_get_features(struct landlock_attr_features __user *features_ptr,
         |                                                  ^~~~~~~~~~~~~~~~~~~~~~
   include/linux/syscalls.h:1010:58: warning: 'struct landlock_attr_ruleset' declared inside parameter list will not be visible outside of this definition or declaration
    1010 | asmlinkage long sys_landlock_create_ruleset(const struct landlock_attr_ruleset __user *ruleset_ptr,
         |                                                          ^~~~~~~~~~~~~~~~~~~~~
   include/linux/syscalls.h:1012:60: warning: 'enum landlock_rule_type' declared inside parameter list will not be visible outside of this definition or declaration
    1012 | asmlinkage long sys_landlock_add_rule(int ruleset_fd, enum landlock_rule_type rule_type,
         |                                                            ^~~~~~~~~~~~~~~~~~
   include/linux/syscalls.h:1014:67: warning: 'enum landlock_target_type' declared inside parameter list will not be visible outside of this definition or declaration
    1014 | asmlinkage long sys_landlock_enforce_ruleset(int ruleset_fd, enum landlock_target_type target_type,
         |                                                                   ^~~~~~~~~~~~~~~~~~~~
   In file included from security/landlock/syscall.c:24:
>> include/linux/syscalls.h:239:18: error: conflicting types for 'sys_landlock_get_features'
     239 |  asmlinkage long sys##name(__MAP(x,__SC_DECL,__VA_ARGS__)) \
         |                  ^~~
   include/linux/syscalls.h:225:2: note: in expansion of macro '__SYSCALL_DEFINEx'
     225 |  __SYSCALL_DEFINEx(x, sname, __VA_ARGS__)
         |  ^~~~~~~~~~~~~~~~~
   include/linux/syscalls.h:216:36: note: in expansion of macro 'SYSCALL_DEFINEx'
     216 | #define SYSCALL_DEFINE3(name, ...) SYSCALL_DEFINEx(3, _##name, __VA_ARGS__)
         |                                    ^~~~~~~~~~~~~~~
   security/landlock/syscall.c:151:1: note: in expansion of macro 'SYSCALL_DEFINE3'
     151 | SYSCALL_DEFINE3(landlock_get_features,
         | ^~~~~~~~~~~~~~~
   In file included from security/landlock/syscall.c:24:
   include/linux/syscalls.h:1008:17: note: previous declaration of 'sys_landlock_get_features' was here
    1008 | asmlinkage long sys_landlock_get_features(struct landlock_attr_features __user *features_ptr,
         |                 ^~~~~~~~~~~~~~~~~~~~~~~~~
   In file included from security/landlock/syscall.c:24:
>> include/linux/syscalls.h:239:18: error: conflicting types for 'sys_landlock_create_ruleset'
     239 |  asmlinkage long sys##name(__MAP(x,__SC_DECL,__VA_ARGS__)) \
         |                  ^~~
   include/linux/syscalls.h:225:2: note: in expansion of macro '__SYSCALL_DEFINEx'
     225 |  __SYSCALL_DEFINEx(x, sname, __VA_ARGS__)
         |  ^~~~~~~~~~~~~~~~~
   include/linux/syscalls.h:216:36: note: in expansion of macro 'SYSCALL_DEFINEx'
     216 | #define SYSCALL_DEFINE3(name, ...) SYSCALL_DEFINEx(3, _##name, __VA_ARGS__)
         |                                    ^~~~~~~~~~~~~~~
   security/landlock/syscall.c:261:1: note: in expansion of macro 'SYSCALL_DEFINE3'
     261 | SYSCALL_DEFINE3(landlock_create_ruleset,
         | ^~~~~~~~~~~~~~~
   In file included from security/landlock/syscall.c:24:
   include/linux/syscalls.h:1010:17: note: previous declaration of 'sys_landlock_create_ruleset' was here
    1010 | asmlinkage long sys_landlock_create_ruleset(const struct landlock_attr_ruleset __user *ruleset_ptr,
         |                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~
   In file included from security/landlock/syscall.c:24:
>> include/linux/syscalls.h:239:18: error: conflicting types for 'sys_landlock_add_rule'
     239 |  asmlinkage long sys##name(__MAP(x,__SC_DECL,__VA_ARGS__)) \
         |                  ^~~
   include/linux/syscalls.h:225:2: note: in expansion of macro '__SYSCALL_DEFINEx'
     225 |  __SYSCALL_DEFINEx(x, sname, __VA_ARGS__)
         |  ^~~~~~~~~~~~~~~~~
   include/linux/syscalls.h:218:36: note: in expansion of macro 'SYSCALL_DEFINEx'
     218 | #define SYSCALL_DEFINE5(name, ...) SYSCALL_DEFINEx(5, _##name, __VA_ARGS__)
         |                                    ^~~~~~~~~~~~~~~
   security/landlock/syscall.c:397:1: note: in expansion of macro 'SYSCALL_DEFINE5'
     397 | SYSCALL_DEFINE5(landlock_add_rule,
         | ^~~~~~~~~~~~~~~
   In file included from security/landlock/syscall.c:24:
   include/linux/syscalls.h:1012:17: note: previous declaration of 'sys_landlock_add_rule' was here
    1012 | asmlinkage long sys_landlock_add_rule(int ruleset_fd, enum landlock_rule_type rule_type,
         |                 ^~~~~~~~~~~~~~~~~~~~~
   In file included from security/landlock/syscall.c:24:
>> include/linux/syscalls.h:239:18: error: conflicting types for 'sys_landlock_enforce_ruleset'
     239 |  asmlinkage long sys##name(__MAP(x,__SC_DECL,__VA_ARGS__)) \
         |                  ^~~
   include/linux/syscalls.h:225:2: note: in expansion of macro '__SYSCALL_DEFINEx'
     225 |  __SYSCALL_DEFINEx(x, sname, __VA_ARGS__)
         |  ^~~~~~~~~~~~~~~~~
   include/linux/syscalls.h:217:36: note: in expansion of macro 'SYSCALL_DEFINEx'
     217 | #define SYSCALL_DEFINE4(name, ...) SYSCALL_DEFINEx(4, _##name, __VA_ARGS__)
         |                                    ^~~~~~~~~~~~~~~
   security/landlock/syscall.c:484:1: note: in expansion of macro 'SYSCALL_DEFINE4'
     484 | SYSCALL_DEFINE4(landlock_enforce_ruleset,
         | ^~~~~~~~~~~~~~~
   In file included from security/landlock/syscall.c:24:
   include/linux/syscalls.h:1014:17: note: previous declaration of 'sys_landlock_enforce_ruleset' was here
    1014 | asmlinkage long sys_landlock_enforce_ruleset(int ruleset_fd, enum landlock_target_type target_type,
         |                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~~

vim +/sys_landlock_get_features +239 include/linux/syscalls.h

1bd21c6c21e848 Dominik Brodowski   2018-04-05  228  
e145242ea0df6b Dominik Brodowski   2018-04-09  229  /*
e145242ea0df6b Dominik Brodowski   2018-04-09  230   * The asmlinkage stub is aliased to a function named __se_sys_*() which
e145242ea0df6b Dominik Brodowski   2018-04-09  231   * sign-extends 32-bit ints to longs whenever needed. The actual work is
e145242ea0df6b Dominik Brodowski   2018-04-09  232   * done within __do_sys_*().
e145242ea0df6b Dominik Brodowski   2018-04-09  233   */
1bd21c6c21e848 Dominik Brodowski   2018-04-05  234  #ifndef __SYSCALL_DEFINEx
bed1ffca022cc8 Frederic Weisbecker 2009-03-13  235  #define __SYSCALL_DEFINEx(x, name, ...)					\
bee20031772af3 Arnd Bergmann       2018-06-19  236  	__diag_push();							\
bee20031772af3 Arnd Bergmann       2018-06-19  237  	__diag_ignore(GCC, 8, "-Wattribute-alias",			\
bee20031772af3 Arnd Bergmann       2018-06-19  238  		      "Type aliasing is used to sanitize syscall arguments");\
83460ec8dcac14 Andi Kleen          2013-11-12 @239  	asmlinkage long sys##name(__MAP(x,__SC_DECL,__VA_ARGS__))	\
e145242ea0df6b Dominik Brodowski   2018-04-09  240  		__attribute__((alias(__stringify(__se_sys##name))));	\
c9a211951c7c79 Howard McLauchlan   2018-03-21  241  	ALLOW_ERROR_INJECTION(sys##name, ERRNO);			\
e145242ea0df6b Dominik Brodowski   2018-04-09  242  	static inline long __do_sys##name(__MAP(x,__SC_DECL,__VA_ARGS__));\
e145242ea0df6b Dominik Brodowski   2018-04-09  243  	asmlinkage long __se_sys##name(__MAP(x,__SC_LONG,__VA_ARGS__));	\
e145242ea0df6b Dominik Brodowski   2018-04-09  244  	asmlinkage long __se_sys##name(__MAP(x,__SC_LONG,__VA_ARGS__))	\
1a94bc34768e46 Heiko Carstens      2009-01-14  245  	{								\
e145242ea0df6b Dominik Brodowski   2018-04-09  246  		long ret = __do_sys##name(__MAP(x,__SC_CAST,__VA_ARGS__));\
07fe6e00f6cca6 Al Viro             2013-01-21  247  		__MAP(x,__SC_TEST,__VA_ARGS__);				\
2cf0966683430b Al Viro             2013-01-21  248  		__PROTECT(x, ret,__MAP(x,__SC_ARGS,__VA_ARGS__));	\
2cf0966683430b Al Viro             2013-01-21  249  		return ret;						\
1a94bc34768e46 Heiko Carstens      2009-01-14  250  	}								\
bee20031772af3 Arnd Bergmann       2018-06-19  251  	__diag_pop();							\
e145242ea0df6b Dominik Brodowski   2018-04-09  252  	static inline long __do_sys##name(__MAP(x,__SC_DECL,__VA_ARGS__))
1bd21c6c21e848 Dominik Brodowski   2018-04-05  253  #endif /* __SYSCALL_DEFINEx */
1a94bc34768e46 Heiko Carstens      2009-01-14  254  

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

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

  reply	other threads:[~2020-08-02 23:58 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-08-02 21:58 [PATCH v20 00/12] Landlock LSM Mickaël Salaün
2020-08-02 21:58 ` Mickaël Salaün
2020-08-02 21:58 ` [PATCH v20 01/12] landlock: Add object management Mickaël Salaün
2020-08-02 21:58   ` Mickaël Salaün
2020-08-02 21:58 ` [PATCH v20 02/12] landlock: Add ruleset and domain management Mickaël Salaün
2020-08-02 21:58   ` Mickaël Salaün
2020-08-02 21:58 ` [PATCH v20 03/12] landlock: Set up the security framework and manage credentials Mickaël Salaün
2020-08-02 21:58   ` Mickaël Salaün
2020-08-02 21:58 ` [PATCH v20 04/12] landlock: Add ptrace restrictions Mickaël Salaün
2020-08-02 21:58 ` [PATCH v20 05/12] LSM: Infrastructure management of the superblock Mickaël Salaün
2020-08-02 21:58   ` Mickaël Salaün
2020-08-12 19:16   ` Stephen Smalley
2020-08-13 14:15     ` Mickaël Salaün
2020-08-13 18:39       ` Stephen Smalley
2020-08-13 18:39         ` Stephen Smalley
2020-09-04 14:06         ` Stephen Smalley
2020-09-04 14:06           ` Stephen Smalley
2020-09-16 13:42           ` Mickaël Salaün
2020-08-02 21:58 ` [PATCH v20 06/12] fs,security: Add sb_delete hook Mickaël Salaün
2020-08-02 21:58   ` Mickaël Salaün
2020-08-02 21:58 ` [PATCH v20 07/12] landlock: Support filesystem access-control Mickaël Salaün
2020-08-02 21:58   ` Mickaël Salaün
2020-08-02 21:58 ` [PATCH v20 08/12] landlock: Add syscall implementations Mickaël Salaün
2020-08-02 21:58   ` Mickaël Salaün
2020-08-02 23:58   ` kernel test robot [this message]
2020-08-03  0:44   ` kernel test robot
2020-08-13 20:29   ` Mickaël Salaün
2020-08-02 21:59 ` [PATCH v20 09/12] arch: Wire up Landlock syscalls Mickaël Salaün
2020-08-02 21:59   ` Mickaël Salaün
2020-08-03  2:35   ` kernel test robot
2020-08-02 21:59 ` [PATCH v20 10/12] selftests/landlock: Add initial tests Mickaël Salaün
2020-08-02 21:59   ` Mickaël Salaün
2020-08-02 21:59 ` [PATCH v20 11/12] samples/landlock: Add a sandbox manager example Mickaël Salaün
2020-08-02 21:59   ` Mickaël Salaün
2020-08-02 21:59 ` [PATCH v20 12/12] landlock: Add user and kernel documentation Mickaël Salaün
2020-08-02 21:59   ` Mickaël Salaün

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=202008030745.A4EINgdH%lkp@intel.com \
    --to=lkp@intel.com \
    --cc=kbuild-all@lists.01.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.