[PATCH v4 02/10] include: Move compat_timespec/ timeval to compat_time.h

kbuild test robot lkp at intel.com
Tue Mar 13 15:30:51 UTC 2018


Hi Deepa,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on ]

url:    https://github.com/0day-ci/linux/commits/Deepa-Dinamani/posix_clocks-Prepare-syscalls-for-64-bit-time_t-conversion/20180313-203305
base:    
config: powerpc-iss476-smp_defconfig (attached as .config)
compiler: powerpc-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0
reproduce:
        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
        make.cross ARCH=powerpc 

All errors (new ones prefixed by >>):

   arch/powerpc/oprofile/backtrace.c: In function 'user_getsp32':
>> arch/powerpc/oprofile/backtrace.c:31:19: error: implicit declaration of function 'compat_ptr'; did you mean 'complete'? [-Werror=implicit-function-declaration]
     void __user *p = compat_ptr(sp);
                      ^~~~~~~~~~
                      complete
>> arch/powerpc/oprofile/backtrace.c:31:19: error: initialization makes pointer from integer without a cast [-Werror=int-conversion]
   cc1: all warnings being treated as errors

vim +31 arch/powerpc/oprofile/backtrace.c

6c6bd754 Brian Rogan 2006-03-27  27  
6c6bd754 Brian Rogan 2006-03-27  28  static unsigned int user_getsp32(unsigned int sp, int is_first)
6c6bd754 Brian Rogan 2006-03-27  29  {
6c6bd754 Brian Rogan 2006-03-27  30  	unsigned int stack_frame[2];
62034f03 Al Viro     2006-09-23 @31  	void __user *p = compat_ptr(sp);
6c6bd754 Brian Rogan 2006-03-27  32  
62034f03 Al Viro     2006-09-23  33  	if (!access_ok(VERIFY_READ, p, sizeof(stack_frame)))
6c6bd754 Brian Rogan 2006-03-27  34  		return 0;
6c6bd754 Brian Rogan 2006-03-27  35  
6c6bd754 Brian Rogan 2006-03-27  36  	/*
6c6bd754 Brian Rogan 2006-03-27  37  	 * The most likely reason for this is that we returned -EFAULT,
6c6bd754 Brian Rogan 2006-03-27  38  	 * which means that we've done all that we can do from
6c6bd754 Brian Rogan 2006-03-27  39  	 * interrupt context.
6c6bd754 Brian Rogan 2006-03-27  40  	 */
62034f03 Al Viro     2006-09-23  41  	if (__copy_from_user_inatomic(stack_frame, p, sizeof(stack_frame)))
6c6bd754 Brian Rogan 2006-03-27  42  		return 0;
6c6bd754 Brian Rogan 2006-03-27  43  
6c6bd754 Brian Rogan 2006-03-27  44  	if (!is_first)
6c6bd754 Brian Rogan 2006-03-27  45  		oprofile_add_trace(STACK_LR32(stack_frame));
6c6bd754 Brian Rogan 2006-03-27  46  
6c6bd754 Brian Rogan 2006-03-27  47  	/*
6c6bd754 Brian Rogan 2006-03-27  48  	 * We do not enforce increasing stack addresses here because
6c6bd754 Brian Rogan 2006-03-27  49  	 * we may transition to a different stack, eg a signal handler.
6c6bd754 Brian Rogan 2006-03-27  50  	 */
6c6bd754 Brian Rogan 2006-03-27  51  	return STACK_SP(stack_frame);
6c6bd754 Brian Rogan 2006-03-27  52  }
6c6bd754 Brian Rogan 2006-03-27  53  

:::::: The code at line 31 was first introduced by commit
:::::: 62034f03380a64c0144b6721f4a2aa55d65346c1 [POWERPC] powerpc oprofile __user annotations

:::::: TO: Al Viro <viro at ftp.linux.org.uk>
:::::: CC: Paul Mackerras <paulus at samba.org>

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation
-------------- next part --------------
A non-text attachment was scrubbed...
Name: .config.gz
Type: application/gzip
Size: 9648 bytes
Desc: not available
URL: <http://driverdev.linuxdriverproject.org/pipermail/driverdev-devel/attachments/20180313/f43b4d27/attachment.bin>


More information about the devel mailing list