All of lore.kernel.org
 help / color / mirror / Atom feed
From: Peter Maydell <peter.maydell@linaro.org>
To: qemu-devel@nongnu.org
Subject: [PULL 8/8] target/arm: Don't advertise aarch64-pauth.xml to gdb
Date: Tue, 21 Mar 2023 13:20:36 +0000	[thread overview]
Message-ID: <20230321132036.1836617-9-peter.maydell@linaro.org> (raw)
In-Reply-To: <20230321132036.1836617-1-peter.maydell@linaro.org>

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



  parent reply	other threads:[~2023-03-21 13:21 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-21 13:20 [PULL 0/8] target-arm queue Peter Maydell
2023-03-21 13:20 ` [PULL 1/8] target/arm: Add Neoverse-N1 registers Peter Maydell
2023-03-21 13:20 ` [PULL 2/8] hw/char/cadence_uart: Fix guards on invalid BRGR/BDIV settings Peter Maydell
2023-03-21 13:20 ` [PULL 3/8] contrib/elf2dmp: fix code style Peter Maydell
2023-03-21 13:20 ` [PULL 4/8] contrib/elf2dmp: move PE dir search to pe_get_data_dir_entry Peter Maydell
2023-03-21 13:20 ` [PULL 5/8] contrib/elf2dmp: add PE name check and Windows Server 2022 support Peter Maydell
2023-03-21 13:20 ` [PULL 6/8] hw/usb/imx: Fix out of bounds access in imx_usbphy_read() Peter Maydell
2023-03-21 13:20 ` [PULL 7/8] docs/system/arm/cpu-features.rst: Fix formatting Peter Maydell
2023-03-21 13:20 ` Peter Maydell [this message]
2023-03-21 17:14 ` [PULL 0/8] target-arm queue Peter Maydell

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=20230321132036.1836617-9-peter.maydell@linaro.org \
    --to=peter.maydell@linaro.org \
    --cc=qemu-devel@nongnu.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.