From: Andrew Jones <drjones@redhat.com>
To: Pavel Fedin <p.fedin@samsung.com>
Cc: kvmarm@lists.cs.columbia.edu, kvm@vger.kernel.org,
"'Marc Zyngier'" <marc.zyngier@arm.com>
Subject: Re: [PATCH v4 0/4] KVM: arm64: BUG FIX: Correctly handle zero register transfers
Date: Tue, 8 Dec 2015 08:48:31 -0600 [thread overview]
Message-ID: <20151208144831.GD4453@hawk.localdomain> (raw)
In-Reply-To: <009501d13185$b02d1150$108733f0$@samsung.com>
On Tue, Dec 08, 2015 at 09:57:21AM +0300, Pavel Fedin wrote:
> Hello!
>
> > I messed up the "load into xzr" test royally in the last attached patch.
> > It was quite wrong.
>
> Yes, because "mov %0, xzr" is not trapped.
>
> > I have now tested
> >
> > asm volatile(
> > "str %3, [%1]\n\t"
> > "ldr wzr, [%1]\n\t"
> > "str wzr, [%2]\n\t"
> > "ldr %0, [%2]\n\t"
> > :"=r"(val):"r"(addr), "r"(addr2), "r"(0x55555555):"memory");
> > report("mmio: 'ldr wzr' check: read 0x%08lx", val != 0x55555555, val);
> >
> > which passes
>
> I guess i forgot to mention that both addr and addr2 have to be MMIO registers. If they are plain memory, then of course everything
> will work because they are not trapped.
Yes, my round two (which still didn't fail) used mmio for both addr and
addr2.
>
> > Anyway, I
> > probably won't clean this test up and post it. I don't think we really
> > need to add it as a regression test, unless others disagree and would
> > like to see it added.
>
> Considering how difficult it was to find this problem, and how tricky and unobvious it is, i would ask to add this test. Especially
> considering you've already written it. At least it will serve as a reminder about the problem.
OK. I need to wrap up some other work right now, but then I'll clean
this patch up and send it properly.
Thanks,
drew
>
> Kind regards,
> Pavel Fedin
> Expert Engineer
> Samsung Electronics Research center Russia
>
>
> --
> To unsubscribe from this list: send the line "unsubscribe kvm" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2015-12-08 14:48 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-12-04 12:03 [PATCH v4 0/4] KVM: arm64: BUG FIX: Correctly handle zero register transfers Pavel Fedin
2015-12-04 12:03 ` [PATCH v4 1/4] KVM: arm64: Correctly handle zero register during MMIO Pavel Fedin
2015-12-04 15:33 ` Marc Zyngier
2015-12-04 12:03 ` [PATCH v4 2/4] KVM: arm64: Remove const from struct sys_reg_params Pavel Fedin
2015-12-04 13:00 ` Marc Zyngier
2015-12-04 12:03 ` [PATCH v4 3/4] KVM: arm64: Correctly handle zero register in system register accesses Pavel Fedin
2015-12-04 12:03 ` [PATCH v4 4/4] KVM: arm64: Get rid of old vcpu_reg() Pavel Fedin
2015-12-05 0:33 ` [PATCH v4 0/4] KVM: arm64: BUG FIX: Correctly handle zero register transfers Andrew Jones
2015-12-07 8:36 ` Pavel Fedin
2015-12-07 22:36 ` Andrew Jones
2015-12-07 23:45 ` Andrew Jones
2015-12-08 6:57 ` Pavel Fedin
2015-12-08 14:48 ` Andrew Jones [this message]
2015-12-07 8:47 ` Pavel Fedin
2015-12-07 21:50 ` Andrew Jones
2015-12-07 9:48 ` Pavel Fedin
2015-12-07 21:58 ` Andrew Jones
2015-12-07 22:25 ` Andrew Jones
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=20151208144831.GD4453@hawk.localdomain \
--to=drjones@redhat.com \
--cc=kvm@vger.kernel.org \
--cc=kvmarm@lists.cs.columbia.edu \
--cc=marc.zyngier@arm.com \
--cc=p.fedin@samsung.com \
/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