mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-12-17 21:26:13 -07:00
gdbstub: introduce gdb_get_max_cpus
This is needed for handling vcont packets as the way of calculating max cpus vhanges between user and softmmu mode. Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Signed-off-by: Alex Bennée <alex.bennee@linaro.org> Message-Id: <20230302190846.2593720-17-alex.bennee@linaro.org> Message-Id: <20230303025805.625589-17-richard.henderson@linaro.org>
This commit is contained in:
parent
589a58672e
commit
7ea0c33def
4 changed files with 28 additions and 10 deletions
|
|
@ -440,6 +440,15 @@ int gdb_target_memory_rw_debug(CPUState *cpu, hwaddr addr,
|
|||
return cpu_memory_rw_debug(cpu, addr, buf, len, is_write);
|
||||
}
|
||||
|
||||
/*
|
||||
* cpu helpers
|
||||
*/
|
||||
|
||||
unsigned int gdb_get_max_cpus(void)
|
||||
{
|
||||
MachineState *ms = MACHINE(qdev_get_machine());
|
||||
return ms->smp.max_cpus;
|
||||
}
|
||||
|
||||
/*
|
||||
* Softmmu specific command helpers
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue