qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v1 1/2] target/arm: kvm64 make guest debug AA32


From: Alex Bennée
Subject: Re: [Qemu-devel] [PATCH v1 1/2] target/arm: kvm64 make guest debug AA32 break point aware
Date: Thu, 13 Dec 2018 14:55:10 +0000
User-agent: mu4e 1.1.0; emacs 26.1.90

Ard Biesheuvel <address@hidden> writes:

> Hi Alex,
>
> Thanks again for looking into this.
>
> On Thu, 13 Dec 2018 at 12:55, Alex Bennée <address@hidden> wrote:
<snip>
>
>>
>>  int kvm_arch_insert_sw_breakpoint(CPUState *cs, struct kvm_sw_breakpoint 
>> *bp)
>>  {
>> +    CPUARMState *env = &ARM_CPU(cs)->env;
>> +    int el = arm_current_el(env);
>> +    bool is_aa64 = arm_el_is_aa64(env, el);
>> +    const uint32_t *bpi = is_aa64 ? &brk_insn : &bkpt_insn;
>> +
>>      if (have_guest_debug) {
>>          if (cpu_memory_rw_debug(cs, bp->pc, (uint8_t *)&bp->saved_insn, 4, 
>> 0) ||
>> -            cpu_memory_rw_debug(cs, bp->pc, (uint8_t *)&brk_insn, 4, 1)) {
>> +            cpu_memory_rw_debug(cs, bp->pc, (uint8_t *)bpi, 4, 1)) {
>
> Should we be dealing with endianness here?
>
<snip>

I don't think so - everything eventually ends up (ld|st)n_p which deals
with the endianness details.

--
Alex Bennée



reply via email to

[Prev in Thread] Current Thread [Next in Thread]