* [PATCH for-8.0] target/arm: Don't advertise aarch64-pauth.xml to gdb
@ 2023-03-17 16:50 Peter Maydell
2023-03-17 17:23 ` Alex Bennée
0 siblings, 1 reply; 3+ messages in thread
From: Peter Maydell @ 2023-03-17 16:50 UTC (permalink / raw)
To: qemu-arm, qemu-devel; +Cc: Alex Bennée, Richard Henderson, Luis Machado
Unfortunately a bug in older versions of gdb means that they will
crash if QEMU sends them the aarch64-pauth.xml. This bug is fixed in
gdb commit 1ba3a3222039eb25, and there are plans to backport that to
affected gdb release branches, but since the bug affects gdb 9
through 12 it is very widely deployed (for instance by distros).
It is not currently clear what the best way to deal with this is; it
has been proposed to define a new XML feature name that old gdb will
ignore but newer gdb can handle. Since QEMU's 8.0 release is
imminent and at least one of our CI runners is now falling over this,
disable the pauth XML for the moment. We can follow up with a more
considered fix either in time for 8.0 or else for the 8.1 release.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
---
target/arm/gdbstub.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/target/arm/gdbstub.c b/target/arm/gdbstub.c
index 78105b8078b..3bd86cee979 100644
--- a/target/arm/gdbstub.c
+++ b/target/arm/gdbstub.c
@@ -520,11 +520,18 @@ void arm_cpu_register_gdb_regs_for_features(ARMCPU *cpu)
aarch64_gdb_set_fpu_reg,
34, "aarch64-fpu.xml", 0);
}
+#if 0
+ /*
+ * GDB versions 9 through 12 have a bug which means they will
+ * crash if they see this XML from QEMU; disable it for the 8.0
+ * release, pending a better solution.
+ */
if (isar_feature_aa64_pauth(&cpu->isar)) {
gdb_register_coprocessor(cs, aarch64_gdb_get_pauth_reg,
aarch64_gdb_set_pauth_reg,
4, "aarch64-pauth.xml", 0);
}
+#endif
#endif
} else {
if (arm_feature(env, ARM_FEATURE_NEON)) {
--
2.34.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH for-8.0] target/arm: Don't advertise aarch64-pauth.xml to gdb
2023-03-17 16:50 [PATCH for-8.0] target/arm: Don't advertise aarch64-pauth.xml to gdb Peter Maydell
@ 2023-03-17 17:23 ` Alex Bennée
2023-03-17 17:26 ` Peter Maydell
0 siblings, 1 reply; 3+ messages in thread
From: Alex Bennée @ 2023-03-17 17:23 UTC (permalink / raw)
To: Peter Maydell; +Cc: qemu-arm, qemu-devel, Richard Henderson, Luis Machado
Peter Maydell <peter.maydell@linaro.org> writes:
> Unfortunately a bug in older versions of gdb means that they will
> crash if QEMU sends them the aarch64-pauth.xml. This bug is fixed in
> gdb commit 1ba3a3222039eb25, and there are plans to backport that to
> affected gdb release branches, but since the bug affects gdb 9
> through 12 it is very widely deployed (for instance by distros).
>
> It is not currently clear what the best way to deal with this is; it
> has been proposed to define a new XML feature name that old gdb will
> ignore but newer gdb can handle. Since QEMU's 8.0 release is
> imminent and at least one of our CI runners is now falling over this,
> disable the pauth XML for the moment. We can follow up with a more
> considered fix either in time for 8.0 or else for the 8.1 release.
>
> Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Queued to pr/170323-for-8.0-1, thanks.
--
Alex Bennée
Virtualisation Tech Lead @ Linaro
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH for-8.0] target/arm: Don't advertise aarch64-pauth.xml to gdb
2023-03-17 17:23 ` Alex Bennée
@ 2023-03-17 17:26 ` Peter Maydell
0 siblings, 0 replies; 3+ messages in thread
From: Peter Maydell @ 2023-03-17 17:26 UTC (permalink / raw)
To: Alex Bennée; +Cc: qemu-arm, qemu-devel, Richard Henderson, Luis Machado
On Fri, 17 Mar 2023 at 17:23, Alex Bennée <alex.bennee@linaro.org> wrote:
>
>
> Peter Maydell <peter.maydell@linaro.org> writes:
>
> > Unfortunately a bug in older versions of gdb means that they will
> > crash if QEMU sends them the aarch64-pauth.xml. This bug is fixed in
> > gdb commit 1ba3a3222039eb25, and there are plans to backport that to
> > affected gdb release branches, but since the bug affects gdb 9
> > through 12 it is very widely deployed (for instance by distros).
> >
> > It is not currently clear what the best way to deal with this is; it
> > has been proposed to define a new XML feature name that old gdb will
> > ignore but newer gdb can handle. Since QEMU's 8.0 release is
> > imminent and at least one of our CI runners is now falling over this,
> > disable the pauth XML for the moment. We can follow up with a more
> > considered fix either in time for 8.0 or else for the 8.1 release.
> >
> > Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
>
> Queued to pr/170323-for-8.0-1, thanks.
I'll take this via target-arm.next, so please unqueue this one.
-- PMM
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2023-03-17 17:27 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-03-17 16:50 [PATCH for-8.0] target/arm: Don't advertise aarch64-pauth.xml to gdb Peter Maydell
2023-03-17 17:23 ` Alex Bennée
2023-03-17 17:26 ` Peter Maydell
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).