public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: Shuah Khan <skhan@linuxfoundation.org>
Cc: cgel.zte@gmail.com, pbonzini@redhat.com, shuah@kernel.org,
	seanjc@google.com, dmatlack@google.com, jmattson@google.com,
	peterx@redhat.com, oupton@google.com, kvm@vger.kernel.org,
	linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org,
	Jinpeng Cui <cui.jinpeng2@zte.com.cn>,
	Zeal Robot <zealci@zte.com.cn>
Subject: Re: [PATCH linux-next] KVM: selftests: remove redundant variable tsc_val
Date: Fri, 23 Sep 2022 08:28:20 +0200	[thread overview]
Message-ID: <Yy1SBF2c4oH84sEl@kroah.com> (raw)
In-Reply-To: <b9044b55-1498-3309-4db5-70ca2c20b3f7@linuxfoundation.org>

On Thu, Sep 22, 2022 at 12:45:22PM -0600, Shuah Khan wrote:
> On 8/31/22 08:31, cgel.zte@gmail.com wrote:
> > From: Jinpeng Cui <cui.jinpeng2@zte.com.cn>
> > 
> > Return value directly from expression instead of
> > getting value from redundant variable tsc_val.
> > 
> > Reported-by: Zeal Robot <zealci@zte.com.cn>
> > Signed-off-by: Jinpeng Cui <cui.jinpeng2@zte.com.cn>
> > ---
> >   tools/testing/selftests/kvm/include/x86_64/processor.h | 5 ++---
> >   1 file changed, 2 insertions(+), 3 deletions(-)
> > 
> > diff --git a/tools/testing/selftests/kvm/include/x86_64/processor.h b/tools/testing/selftests/kvm/include/x86_64/processor.h
> > index 0cbc71b7af50..75920678f34d 100644
> > --- a/tools/testing/selftests/kvm/include/x86_64/processor.h
> > +++ b/tools/testing/selftests/kvm/include/x86_64/processor.h
> > @@ -237,7 +237,6 @@ static inline uint64_t get_desc64_base(const struct desc64 *desc)
> >   static inline uint64_t rdtsc(void)
> >   {
> >   	uint32_t eax, edx;
> > -	uint64_t tsc_val;
> >   	/*
> >   	 * The lfence is to wait (on Intel CPUs) until all previous
> >   	 * instructions have been executed. If software requires RDTSC to be
> > @@ -245,8 +244,8 @@ static inline uint64_t rdtsc(void)
> >   	 * execute LFENCE immediately after RDTSC
> >   	 */
> >   	__asm__ __volatile__("lfence; rdtsc; lfence" : "=a"(eax), "=d"(edx));
> > -	tsc_val = ((uint64_t)edx) << 32 | eax;
> > -	return tsc_val;
> > +
> > +	return ((uint64_t)edx) << 32 | eax;
> >   }
> >   static inline uint64_t rdtscp(uint32_t *aux)
> 
> My understanding is that this patch isn't coming from individuals that work
> for ZTE. We won't be able to accept these patches. Refer to the following
> for reasons why we can't accept these patches.
> 
> https://patchwork.kernel.org/project/linux-kselftest/patch/20220920063202.215088-1-ye.xingchen@zte.com.cn/

Thanks for catching this.

Also this address has now been banned from the kernel mailing lists, so
watch out for patches sent to maintainers that do not show up on
lore.kernel.org.

thanks,

greg k-h

      parent reply	other threads:[~2022-09-23  6:29 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-31 14:31 [PATCH linux-next] KVM: selftests: remove redundant variable tsc_val cgel.zte
2022-08-31 16:17 ` Jim Mattson
2022-09-20 19:30   ` Sean Christopherson
2022-09-22 18:45 ` Shuah Khan
2022-09-22 19:41   ` Sean Christopherson
2022-09-23  6:28   ` Greg Kroah-Hartman [this message]

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=Yy1SBF2c4oH84sEl@kroah.com \
    --to=gregkh@linuxfoundation.org \
    --cc=cgel.zte@gmail.com \
    --cc=cui.jinpeng2@zte.com.cn \
    --cc=dmatlack@google.com \
    --cc=jmattson@google.com \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=oupton@google.com \
    --cc=pbonzini@redhat.com \
    --cc=peterx@redhat.com \
    --cc=seanjc@google.com \
    --cc=shuah@kernel.org \
    --cc=skhan@linuxfoundation.org \
    --cc=zealci@zte.com.cn \
    /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