mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-05 16:53:55 -06:00
cpu: Introduce CPUClass::memory_rw_debug() for target_memory_rw_debug()
Make inline target_memory_rw_debug() always available and change its argument to CPUState. Let it check if CPUClass::memory_rw_debug provides a specialized callback and fall back to cpu_memory_rw_debug() otherwise. The only overriding implementation is for 32-bit sparc. This prepares for changing GDBState::g_cpu to CPUState. Signed-off-by: Andreas Färber <afaerber@suse.de>
This commit is contained in:
parent
f17ec444c3
commit
f3659eee05
5 changed files with 25 additions and 15 deletions
|
@ -353,10 +353,12 @@ void dump_mmu(FILE *f, fprintf_function cpu_fprintf, CPUSPARCState *env)
|
|||
* reads (and only reads) in stack frames as if windows were flushed. We assume
|
||||
* that the sparc ABI is followed.
|
||||
*/
|
||||
int target_memory_rw_debug(CPUSPARCState *env, target_ulong addr,
|
||||
uint8_t *buf, int len, int is_write)
|
||||
int sparc_cpu_memory_rw_debug(CPUState *cs, vaddr address,
|
||||
uint8_t *buf, int len, bool is_write)
|
||||
{
|
||||
CPUState *cs = CPU(sparc_env_get_cpu(env));
|
||||
SPARCCPU *cpu = SPARC_CPU(cs);
|
||||
CPUSPARCState *env = &cpu->env;
|
||||
target_ulong addr = address;
|
||||
int i;
|
||||
int len1;
|
||||
int cwp = env->cwp;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue