[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Stable-10.0.1 06/23] hw/core/cpu: gdb_arch_name string should not be fr
From: |
Michael Tokarev |
Subject: |
[Stable-10.0.1 06/23] hw/core/cpu: gdb_arch_name string should not be freed |
Date: |
Wed, 14 May 2025 22:00:18 +0300 |
From: Peter Maydell <peter.maydell@linaro.org>
The documentation for the CPUClass::gdb_arch_name method claims that
the returned string should be freed with g_free(). This is not
correct: in commit a650683871ba728 we changed this method to
instead return a simple constant string, but forgot to update
the documentation.
Make the documentation match the new semantics.
Fixes: a650683871ba728 ("hw/core/cpu: Return static value with gdb_arch_name()")
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-ID: <20250317142819.900029-2-peter.maydell@linaro.org>
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
(cherry picked from commit 56a9f0d4c4a483ce217e5290db69cb1788586787)
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
diff --git a/include/hw/core/cpu.h b/include/hw/core/cpu.h
index abd8764e83..e136b067cd 100644
--- a/include/hw/core/cpu.h
+++ b/include/hw/core/cpu.h
@@ -135,7 +135,8 @@ struct SysemuCPUOps;
* @gdb_stop_before_watchpoint: Indicates whether GDB expects the CPU to stop
* before the insn which triggers a watchpoint rather than after it.
* @gdb_arch_name: Optional callback that returns the architecture name known
- * to GDB. The caller must free the returned string with g_free.
+ * to GDB. The returned value is expected to be a simple constant string:
+ * the caller will not g_free() it.
* @disas_set_info: Setup architecture specific components of disassembly info
* @adjust_watchpoint_address: Perform a target-specific adjustment to an
* address before attempting to match it against watchpoints.
--
2.39.5
- [Stable-10.0.1 00/23] Patch Round-up for stable 10.0.1, freeze on 2025-05-24, Michael Tokarev, 2025/05/14
- [Stable-10.0.1 03/23] target/i386/hvf: fix lflags_to_rflags, Michael Tokarev, 2025/05/14
- [Stable-10.0.1 01/23] target/i386: Fix model number of Zhaoxin YongFeng vCPU template, Michael Tokarev, 2025/05/14
- [Stable-10.0.1 02/23] target/i386: Reset parked vCPUs together with the online ones, Michael Tokarev, 2025/05/14
- [Stable-10.0.1 05/23] hw/core: Get default_cpu_type calling machine_class_default_cpu_type(), Michael Tokarev, 2025/05/14
- [Stable-10.0.1 04/23] target/avr: Improve decode of LDS, STS, Michael Tokarev, 2025/05/14
- [Stable-10.0.1 07/23] target/mips: Fix MIPS16e translation, Michael Tokarev, 2025/05/14
- [Stable-10.0.1 06/23] hw/core/cpu: gdb_arch_name string should not be freed,
Michael Tokarev <=
- [Stable-10.0.1 08/23] meson: Use has_header_symbol() to check getcpu(), Michael Tokarev, 2025/05/14
- [Stable-10.0.1 09/23] meson: Remove CONFIG_STATX and CONFIG_STATX_MNT_ID, Michael Tokarev, 2025/05/14
- [Stable-10.0.1 10/23] meson: Share common C source prefixes, Michael Tokarev, 2025/05/14
- [Stable-10.0.1 11/23] meson: Use osdep_prefix for strchrnul(), Michael Tokarev, 2025/05/14
- [Stable-10.0.1 13/23] hw/arm/npcm8xx_boards: Correct valid_cpu_types setting of NPCM8XX SoC, Michael Tokarev, 2025/05/14
- [Stable-10.0.1 14/23] target/arm: Don't assert() for ISB/SB inside IT block, Michael Tokarev, 2025/05/14
- [Stable-10.0.1 12/23] accel/tcg: Don't use TARGET_LONG_BITS in decode_sleb128, Michael Tokarev, 2025/05/14
- [Stable-10.0.1 15/23] docs: Don't define duplicate label in qemu-block-drivers.rst.inc, Michael Tokarev, 2025/05/14
- [Stable-10.0.1 20/23] xen: mapcache: Split mapcache_grants by ro and rw, Michael Tokarev, 2025/05/14
- [Stable-10.0.1 18/23] target/i386: do not block singlestep for STI, Michael Tokarev, 2025/05/14