From: Mark Rutland <mark.rutland@arm.com>
To: Gavin Shan <gshan@redhat.com>
Cc: catalin.marinas@arm.com, will@kernel.org,
kvmarm@lists.cs.columbia.edu,
linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH 1/2] kvm/arm64: Rename HSR to ESR
Date: Mon, 29 Jun 2020 12:05:13 +0100 [thread overview]
Message-ID: <20200629110513.GC59769@C02TD0UTHF1T.local> (raw)
In-Reply-To: <20200629103208.GA59769@C02TD0UTHF1T.local>
On Mon, Jun 29, 2020 at 11:32:08AM +0100, Mark Rutland wrote:
> On Mon, Jun 29, 2020 at 07:18:40PM +1000, Gavin Shan wrote:
> > kvm/arm32 isn't supported since commit 541ad0150ca4 ("arm: Remove
> > 32bit KVM host support"). So HSR isn't meaningful since then. This
> > renames HSR to ESR accordingly. This shouldn't cause any functional
> > changes:
> >
> > * Rename kvm_vcpu_get_hsr() to kvm_vcpu_get_esr() to make the
> > function names self-explanatory.
> > * Rename variables from @hsr to @esr to make them self-explanatory.
> >
> > Signed-off-by: Gavin Shan <gshan@redhat.com>
>
> At a high-level, I agree that we should move to the `esr` naming to
> match the architecture and minimize surprise. However, I think there are
> some ABI changes here, which *are* funcitonal changes, and those need to
> be avoided.
>
> [...]
>
> > diff --git a/arch/arm64/include/uapi/asm/kvm.h b/arch/arm64/include/uapi/asm/kvm.h
> > index ba85bb23f060..d54345573a88 100644
> > --- a/arch/arm64/include/uapi/asm/kvm.h
> > +++ b/arch/arm64/include/uapi/asm/kvm.h
> > @@ -140,7 +140,7 @@ struct kvm_guest_debug_arch {
> > };
> >
> > struct kvm_debug_exit_arch {
> > - __u32 hsr;
> > + __u32 esr;
> > __u64 far; /* used for watchpoints */
> > };
>
> This is userspace ABI, and changing this *will* break userspace. This
> *is* a functional change.
To be slightly clearer: while the structure isn't changed, any userspace
software consuming this header will fail to build after this change,
beacause there will no longer be a field called `hsr`.
Existing binaries will almost certianly not care, but regardless this is
a regression (when building userspce) that I don't think we can permit.
Thanks,
Mark.
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next prev parent reply other threads:[~2020-06-29 11:06 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-06-29 9:18 [PATCH 0/2] Refactor ESR related functions Gavin Shan
2020-06-29 9:18 ` [PATCH 1/2] kvm/arm64: Rename HSR to ESR Gavin Shan
2020-06-29 9:44 ` Andrew Scull
2020-06-29 10:32 ` Mark Rutland
2020-06-29 11:05 ` Mark Rutland [this message]
2020-06-29 17:00 ` Marc Zyngier
2020-06-29 23:14 ` Gavin Shan
2020-06-29 9:18 ` [PATCH 2/2] kvm/arm64: Detach ESR operator from vCPU struct Gavin Shan
2020-06-29 9:59 ` Andrew Scull
2020-06-30 0:28 ` Gavin Shan
2020-06-29 11:00 ` Mark Rutland
2020-06-30 0:16 ` Gavin Shan
2020-06-30 8:00 ` Mark Rutland
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=20200629110513.GC59769@C02TD0UTHF1T.local \
--to=mark.rutland@arm.com \
--cc=catalin.marinas@arm.com \
--cc=gshan@redhat.com \
--cc=kvmarm@lists.cs.columbia.edu \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=will@kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).