On Thu, 4 Jun 2026 at 06:27, Daniel Henrique Barboza <[email protected]> wrote: > > > > On 6/1/2026 1:04 AM, Chao Liu wrote: > > Hi Daniel, > > > > On Thu, May 28, 2026 at 10:12:14AM +0800, Daniel Henrique Barboza wrote: > >> Starting on commit f31ba686a9 ("target/riscv/cpu.c: add 'sdtrig' in > >> riscv,isa') the 'debug' flag has been used as an alias for 'sdtrig' that > >> is, for now, compliant with Debug 0.13 that was ratified 8 years go. > >> > >> We're going to add more debug trigger extensions, e.g. 'sdext' [1]. > >> Thing is that 'sdext' and all other extensions that will follow are now > >> adherent to Debug 1.0, ratified Dec 2022. And so it happens that Debug > >> 1.0 and 0.13 are not compatible with each other. This makes support new > >> Debug 1.0 extensions like 'sdext' harder because we would need two > >> independent code bases for each. > >> > >> We consider that most of the RVI ecosystem already moved on to Debug > >> 1.0 and is now going towards the extended Debug 1.0 extensions, and we > >> should follow suit. And the best way to do that is to leave Debug 0.13 > >> behind, by deprecating its 'debug' flag and making it an alias for > >> 'sdtrig' that will eventually move on to Debug 1.0. > >> > >> The following changes are made: > >> > >> - 'ext_sdtrig' flag was added in cpu->cfg. 'debug' flag was removed from > >> cpu->cfg; > >> - All occurrences of cpu->cfg.debug were replaced to 'ext_sdtrig'; > >> - Two explicit getters and setters for the 'debug' property were added. > >> The property will simply get/set ext_sdtrig; > >> - vmstate_debug was renamed to vmstate_sdtrig. We're aware that this > >> will impact migration between QEMU 10.2 to newer versions, but we're > >> still in a point where the migration break cost isn't big enough to > >> justify adding migration compatibility scaffolding. > >> > >> Finally, deprecated.rst was updated to deprecate 'debug' and inform that > >> it will be now interpreted as an alias of 'sdtrig', which is now going > >> to be compliant with Debug 1.0. > >> > > > > This patch conflicts with Alistair's riscv-to-apply.next branch. > > > > f71708fedf target/riscv/tcg: disable svnapot if satp_mode < sv39 > > Based on recent discussions with Alistair (check the "QEMU RISC-V Call" > thread) > seems like we're postponing this change because there seems to be interest > in keeping the 'debug' flag around, together with the 'sdtrig' extension that > we need for your 'sdext' extension (and for the riscv-server-ref board). > Seems > like someone is going to send patches making it possible.
I think this was a reference to Nick's work (I got credit for a bunch of things Nick said on the call, so swap out "Joel" for "Nick" in some places): [RFC PATCH 00/25] target/riscv/debug: Sdtrig fixes and TT Ascalon support https://lore.kernel.org/qemu-devel/[email protected]/ I encouraged Nick to get it out on the list early, to make others aware of the work that had been done. He mentioned there's some further improvements to make, I'll let him fill you in. Cheers, Joel
