All of lore.kernel.org
 help / color / mirror / Atom feed
From: kbuild test robot <lkp@intel.com>
To: Oleg Nesterov <oleg@redhat.com>
Cc: Madhavan Srinivasan <maddy@linux.vnet.ibm.com>,
	linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org,
	Paul Mackerras <paulus@samba.org>,
	kbuild-all@01.org, Jan Kratochvil <jan.kratochvil@redhat.com>
Subject: Re: [PATCH?] powerpc: Hard wire PT_SOFTE value to 1 in gpr_get() too
Date: Tue, 17 Sep 2019 22:09:51 +0800	[thread overview]
Message-ID: <201909172136.PFaGLD1z%lkp@intel.com> (raw)
In-Reply-To: <20190917121256.GA8659@redhat.com>

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

Hi Oleg,

I love your patch! Yet something to improve:

[auto build test ERROR on linus/master]
[cannot apply to v5.3 next-20190916]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Oleg-Nesterov/powerpc-Hard-wire-PT_SOFTE-value-to-1-in-gpr_get-too/20190917-201613
config: powerpc-allmodconfig (attached as .config)
compiler: powerpc64-linux-gcc (GCC) 7.4.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
        GCC_VERSION=7.4.0 make.cross ARCH=powerpc 

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

All errors (new ones prefixed by >>):

   arch/powerpc/kernel/ptrace.c: In function 'gpr_get':
>> arch/powerpc/kernel/ptrace.c:375:58: error: 'msr' undeclared (first use in this function)
      ret = user_regset_copyout(&pos, &count, &kbuf, &ubuf, &msr,
                                                             ^~~
   arch/powerpc/kernel/ptrace.c:375:58: note: each undeclared identifier is reported only once for each function it appears in

vim +/msr +375 arch/powerpc/kernel/ptrace.c

   336	
   337	static int gpr_get(struct task_struct *target, const struct user_regset *regset,
   338			   unsigned int pos, unsigned int count,
   339			   void *kbuf, void __user *ubuf)
   340	{
   341		int i, ret;
   342	
   343		if (target->thread.regs == NULL)
   344			return -EIO;
   345	
   346		if (!FULL_REGS(target->thread.regs)) {
   347			/* We have a partial register set.  Fill 14-31 with bogus values */
   348			for (i = 14; i < 32; i++)
   349				target->thread.regs->gpr[i] = NV_REG_POISON;
   350		}
   351	
   352		ret = user_regset_copyout(&pos, &count, &kbuf, &ubuf,
   353					  target->thread.regs,
   354					  0, offsetof(struct pt_regs, msr));
   355		if (!ret) {
   356			unsigned long msr = get_user_msr(target);
   357			ret = user_regset_copyout(&pos, &count, &kbuf, &ubuf, &msr,
   358						  offsetof(struct pt_regs, msr),
   359						  offsetof(struct pt_regs, msr) +
   360						  sizeof(msr));
   361		}
   362	
   363		BUILD_BUG_ON(offsetof(struct pt_regs, orig_gpr3) !=
   364			     offsetof(struct pt_regs, msr) + sizeof(long));
   365	
   366	#ifdef CONFIG_PPC64
   367		if (!ret)
   368			ret = user_regset_copyout(&pos, &count, &kbuf, &ubuf,
   369						  &target->thread.regs->orig_gpr3,
   370						  offsetof(struct pt_regs, orig_gpr3),
   371						  offsetof(struct pt_regs, softe));
   372	
   373		if (!ret) {
   374			unsigned long softe = 0x1;
 > 375			ret = user_regset_copyout(&pos, &count, &kbuf, &ubuf, &msr,
   376						  offsetof(struct pt_regs, softe),
   377						  offsetof(struct pt_regs, softe) +
   378						  sizeof(softe));
   379		}
   380	
   381		BUILD_BUG_ON(offsetof(struct pt_regs, trap) !=
   382			     offsetof(struct pt_regs, softe) + sizeof(long));
   383	
   384		if (!ret)
   385			ret = user_regset_copyout(&pos, &count, &kbuf, &ubuf,
   386						  &target->thread.regs->trap,
   387						  offsetof(struct pt_regs, trap),
   388						  sizeof(struct user_pt_regs));
   389	#else
   390		if (!ret)
   391			ret = user_regset_copyout(&pos, &count, &kbuf, &ubuf,
   392						  &target->thread.regs->orig_gpr3,
   393						  offsetof(struct pt_regs, orig_gpr3),
   394						  sizeof(struct user_pt_regs));
   395	#endif
   396		if (!ret)
   397			ret = user_regset_copyout_zero(&pos, &count, &kbuf, &ubuf,
   398						       sizeof(struct user_pt_regs), -1);
   399	
   400		return ret;
   401	}
   402	

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

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

WARNING: multiple messages have this Message-ID (diff)
From: kbuild test robot <lkp@intel.com>
To: Oleg Nesterov <oleg@redhat.com>
Cc: kbuild-all@01.org,
	Benjamin Herrenschmidt <benh@kernel.crashing.org>,
	Madhavan Srinivasan <maddy@linux.vnet.ibm.com>,
	Michael Ellerman <mpe@ellerman.id.au>,
	Paul Mackerras <paulus@samba.org>,
	Jan Kratochvil <jan.kratochvil@redhat.com>,
	linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH?] powerpc: Hard wire PT_SOFTE value to 1 in gpr_get() too
Date: Tue, 17 Sep 2019 22:09:51 +0800	[thread overview]
Message-ID: <201909172136.PFaGLD1z%lkp@intel.com> (raw)
In-Reply-To: <20190917121256.GA8659@redhat.com>

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

Hi Oleg,

I love your patch! Yet something to improve:

[auto build test ERROR on linus/master]
[cannot apply to v5.3 next-20190916]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Oleg-Nesterov/powerpc-Hard-wire-PT_SOFTE-value-to-1-in-gpr_get-too/20190917-201613
config: powerpc-allmodconfig (attached as .config)
compiler: powerpc64-linux-gcc (GCC) 7.4.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
        GCC_VERSION=7.4.0 make.cross ARCH=powerpc 

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

All errors (new ones prefixed by >>):

   arch/powerpc/kernel/ptrace.c: In function 'gpr_get':
>> arch/powerpc/kernel/ptrace.c:375:58: error: 'msr' undeclared (first use in this function)
      ret = user_regset_copyout(&pos, &count, &kbuf, &ubuf, &msr,
                                                             ^~~
   arch/powerpc/kernel/ptrace.c:375:58: note: each undeclared identifier is reported only once for each function it appears in

vim +/msr +375 arch/powerpc/kernel/ptrace.c

   336	
   337	static int gpr_get(struct task_struct *target, const struct user_regset *regset,
   338			   unsigned int pos, unsigned int count,
   339			   void *kbuf, void __user *ubuf)
   340	{
   341		int i, ret;
   342	
   343		if (target->thread.regs == NULL)
   344			return -EIO;
   345	
   346		if (!FULL_REGS(target->thread.regs)) {
   347			/* We have a partial register set.  Fill 14-31 with bogus values */
   348			for (i = 14; i < 32; i++)
   349				target->thread.regs->gpr[i] = NV_REG_POISON;
   350		}
   351	
   352		ret = user_regset_copyout(&pos, &count, &kbuf, &ubuf,
   353					  target->thread.regs,
   354					  0, offsetof(struct pt_regs, msr));
   355		if (!ret) {
   356			unsigned long msr = get_user_msr(target);
   357			ret = user_regset_copyout(&pos, &count, &kbuf, &ubuf, &msr,
   358						  offsetof(struct pt_regs, msr),
   359						  offsetof(struct pt_regs, msr) +
   360						  sizeof(msr));
   361		}
   362	
   363		BUILD_BUG_ON(offsetof(struct pt_regs, orig_gpr3) !=
   364			     offsetof(struct pt_regs, msr) + sizeof(long));
   365	
   366	#ifdef CONFIG_PPC64
   367		if (!ret)
   368			ret = user_regset_copyout(&pos, &count, &kbuf, &ubuf,
   369						  &target->thread.regs->orig_gpr3,
   370						  offsetof(struct pt_regs, orig_gpr3),
   371						  offsetof(struct pt_regs, softe));
   372	
   373		if (!ret) {
   374			unsigned long softe = 0x1;
 > 375			ret = user_regset_copyout(&pos, &count, &kbuf, &ubuf, &msr,
   376						  offsetof(struct pt_regs, softe),
   377						  offsetof(struct pt_regs, softe) +
   378						  sizeof(softe));
   379		}
   380	
   381		BUILD_BUG_ON(offsetof(struct pt_regs, trap) !=
   382			     offsetof(struct pt_regs, softe) + sizeof(long));
   383	
   384		if (!ret)
   385			ret = user_regset_copyout(&pos, &count, &kbuf, &ubuf,
   386						  &target->thread.regs->trap,
   387						  offsetof(struct pt_regs, trap),
   388						  sizeof(struct user_pt_regs));
   389	#else
   390		if (!ret)
   391			ret = user_regset_copyout(&pos, &count, &kbuf, &ubuf,
   392						  &target->thread.regs->orig_gpr3,
   393						  offsetof(struct pt_regs, orig_gpr3),
   394						  sizeof(struct user_pt_regs));
   395	#endif
   396		if (!ret)
   397			ret = user_regset_copyout_zero(&pos, &count, &kbuf, &ubuf,
   398						       sizeof(struct user_pt_regs), -1);
   399	
   400		return ret;
   401	}
   402	

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

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

  reply	other threads:[~2019-09-17 14:16 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-09-17 12:12 [PATCH?] powerpc: Hard wire PT_SOFTE value to 1 in gpr_get() too Oleg Nesterov
2019-09-17 12:12 ` Oleg Nesterov
2019-09-17 14:09 ` kbuild test robot [this message]
2019-09-17 14:09   ` kbuild test robot
2019-09-17 14:37 ` [PATCH? v2] " Oleg Nesterov
2019-09-17 14:37   ` Oleg Nesterov
2020-06-10 15:07   ` Oleg Nesterov
2020-06-10 15:07     ` Oleg Nesterov
2020-06-11  8:52     ` Madhavan Srinivasan
2020-06-11  8:52       ` Madhavan Srinivasan
2020-06-11 10:58       ` Oleg Nesterov
2020-06-11 10:58         ` Oleg Nesterov
2020-06-11 11:11         ` Jan Kratochvil
2020-06-11 11:11           ` Jan Kratochvil
2019-09-19  7:52 ` [PATCH?] " Michael Ellerman
2019-09-19  7:52   ` Michael Ellerman

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=201909172136.PFaGLD1z%lkp@intel.com \
    --to=lkp@intel.com \
    --cc=jan.kratochvil@redhat.com \
    --cc=kbuild-all@01.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=maddy@linux.vnet.ibm.com \
    --cc=oleg@redhat.com \
    --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 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.