All of lore.kernel.org
 help / color / mirror / Atom feed
From: kbuild test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: [peterz-queue:x86/wip-rwx 4/10] arch/s390/kernel/module.c:438:8: error: too few arguments to function 'apply_rela'
Date: Mon, 20 Apr 2020 14:00:25 +0800	[thread overview]
Message-ID: <202004201415.RIVTPXgG%lkp@intel.com> (raw)

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

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git x86/wip-rwx
head:   f856355fba969168555e518db3906492f8ab5b03
commit: a1814c413b9cffdc5e4b3bd098c2ad0f8578dc5f [4/10] s390/module: Use s390_kernel_write() for relocations
config: s390-allyesconfig (attached as .config)
compiler: s390-linux-gcc (GCC) 9.3.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        git checkout a1814c413b9cffdc5e4b3bd098c2ad0f8578dc5f
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day GCC_VERSION=9.3.0 make.cross ARCH=s390 

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

All errors (new ones prefixed by >>):

   arch/s390/kernel/module.c: In function 'apply_rela_bits':
   arch/s390/kernel/module.c:199:9: warning: passing argument 1 of 'write' makes pointer from integer without a cast [-Wint-conversion]
     199 |   write(loc, &val, 1);
         |         ^~~
         |         |
         |         Elf64_Addr {aka long long unsigned int}
   arch/s390/kernel/module.c:199:9: note: expected 'void *' but argument is of type 'Elf64_Addr' {aka 'long long unsigned int'}
   arch/s390/kernel/module.c:203:9: warning: passing argument 1 of 'write' makes pointer from integer without a cast [-Wint-conversion]
     203 |   write(loc, &tmp, 2);
         |         ^~~
         |         |
         |         Elf64_Addr {aka long long unsigned int}
   arch/s390/kernel/module.c:203:9: note: expected 'void *' but argument is of type 'Elf64_Addr' {aka 'long long unsigned int'}
   arch/s390/kernel/module.c:205:9: warning: passing argument 1 of 'write' makes pointer from integer without a cast [-Wint-conversion]
     205 |   write(loc, &val, 2);
         |         ^~~
         |         |
         |         Elf64_Addr {aka long long unsigned int}
   arch/s390/kernel/module.c:205:9: note: expected 'void *' but argument is of type 'Elf64_Addr' {aka 'long long unsigned int'}
   arch/s390/kernel/module.c:209:9: warning: passing argument 1 of 'write' makes pointer from integer without a cast [-Wint-conversion]
     209 |   write(loc, &tmp, 4);
         |         ^~~
         |         |
         |         Elf64_Addr {aka long long unsigned int}
   arch/s390/kernel/module.c:209:9: note: expected 'void *' but argument is of type 'Elf64_Addr' {aka 'long long unsigned int'}
   arch/s390/kernel/module.c:211:9: warning: passing argument 1 of 'write' makes pointer from integer without a cast [-Wint-conversion]
     211 |   write(loc, &val, 4);
         |         ^~~
         |         |
         |         Elf64_Addr {aka long long unsigned int}
   arch/s390/kernel/module.c:211:9: note: expected 'void *' but argument is of type 'Elf64_Addr' {aka 'long long unsigned int'}
   arch/s390/kernel/module.c:213:9: warning: passing argument 1 of 'write' makes pointer from integer without a cast [-Wint-conversion]
     213 |   write(loc, &val, 8);
         |         ^~~
         |         |
         |         Elf64_Addr {aka long long unsigned int}
   arch/s390/kernel/module.c:213:9: note: expected 'void *' but argument is of type 'Elf64_Addr' {aka 'long long unsigned int'}
   arch/s390/kernel/module.c: In function '__apply_relocate_add':
>> arch/s390/kernel/module.c:438:8: error: too few arguments to function 'apply_rela'
     438 |   rc = apply_rela(rela, base, symtab, strtab, me);
         |        ^~~~~~~~~~
   arch/s390/kernel/module.c:218:12: note: declared here
     218 | static int apply_rela(Elf_Rela *rela, Elf_Addr base, Elf_Sym *symtab,
         |            ^~~~~~~~~~
   arch/s390/kernel/module.c: In function 'apply_relocate_add':
   arch/s390/kernel/module.c:453:24: warning: pointer type mismatch in conditional expression
     453 |         early ? memcpy : s390_kernel_write);
         |                        ^
   arch/s390/kernel/module.c:449:6: warning: unused variable 'ret' [-Wunused-variable]
     449 |  int ret;
         |      ^~~

vim +/apply_rela +438 arch/s390/kernel/module.c

^1da177e4c3f41 Linus Torvalds     2005-04-16  418  
a1814c413b9cff Peter Zijlstra     2020-04-14  419  static int __apply_relocate_add(Elf_Shdr *sechdrs, const char *strtab,
^1da177e4c3f41 Linus Torvalds     2005-04-16  420  		       unsigned int symindex, unsigned int relsec,
a1814c413b9cff Peter Zijlstra     2020-04-14  421  		       struct module *me,
a1814c413b9cff Peter Zijlstra     2020-04-14  422  		       void (*write)(void *dest, const void *src, size_t len))
^1da177e4c3f41 Linus Torvalds     2005-04-16  423  {
^1da177e4c3f41 Linus Torvalds     2005-04-16  424  	Elf_Addr base;
^1da177e4c3f41 Linus Torvalds     2005-04-16  425  	Elf_Sym *symtab;
^1da177e4c3f41 Linus Torvalds     2005-04-16  426  	Elf_Rela *rela;
^1da177e4c3f41 Linus Torvalds     2005-04-16  427  	unsigned long i, n;
^1da177e4c3f41 Linus Torvalds     2005-04-16  428  	int rc;
^1da177e4c3f41 Linus Torvalds     2005-04-16  429  
^1da177e4c3f41 Linus Torvalds     2005-04-16  430  	DEBUGP("Applying relocate section %u to %u\n",
^1da177e4c3f41 Linus Torvalds     2005-04-16  431  	       relsec, sechdrs[relsec].sh_info);
^1da177e4c3f41 Linus Torvalds     2005-04-16  432  	base = sechdrs[sechdrs[relsec].sh_info].sh_addr;
^1da177e4c3f41 Linus Torvalds     2005-04-16  433  	symtab = (Elf_Sym *) sechdrs[symindex].sh_addr;
^1da177e4c3f41 Linus Torvalds     2005-04-16  434  	rela = (Elf_Rela *) sechdrs[relsec].sh_addr;
^1da177e4c3f41 Linus Torvalds     2005-04-16  435  	n = sechdrs[relsec].sh_size / sizeof(Elf_Rela);
^1da177e4c3f41 Linus Torvalds     2005-04-16  436  
^1da177e4c3f41 Linus Torvalds     2005-04-16  437  	for (i = 0; i < n; i++, rela++) {
083e14c09b7ae0 Martin Schwidefsky 2013-01-11 @438  		rc = apply_rela(rela, base, symtab, strtab, me);
^1da177e4c3f41 Linus Torvalds     2005-04-16  439  		if (rc)
^1da177e4c3f41 Linus Torvalds     2005-04-16  440  			return rc;
^1da177e4c3f41 Linus Torvalds     2005-04-16  441  	}
^1da177e4c3f41 Linus Torvalds     2005-04-16  442  	return 0;
^1da177e4c3f41 Linus Torvalds     2005-04-16  443  }
^1da177e4c3f41 Linus Torvalds     2005-04-16  444  

:::::: The code@line 438 was first introduced by commit
:::::: 083e14c09b7ae0247b9944a386fdc32cd0719da1 s390/modules: add relocation overflow checking

:::::: TO: Martin Schwidefsky <schwidefsky@de.ibm.com>
:::::: CC: Martin Schwidefsky <schwidefsky@de.ibm.com>

---
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: 59254 bytes --]

                 reply	other threads:[~2020-04-20  6:00 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=202004201415.RIVTPXgG%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.