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

[Xen-changelog] [qemu-xen master] hw/intc/arm_gic: reserved register addresses are RAZ/WI



commit 0af294d774a8fd7b79646d003124577f1798b585
Author:     Peter Maydell <peter.maydell@xxxxxxxxxx>
AuthorDate: Thu Jan 11 13:25:40 2018 +0000
Commit:     Michael Roth <mdroth@xxxxxxxxxxxxxxxxxx>
CommitDate: Thu Jan 11 15:10:57 2018 -0600

    hw/intc/arm_gic: reserved register addresses are RAZ/WI
    
    The GICv2 specification says that reserved register addresses
    must RAZ/WI; now that we implement external abort handling
    for Arm CPUs this means we must return MEMTX_OK rather than
    MEMTX_ERROR, to avoid generating a spurious guest data abort.
    
    Cc: qemu-stable@xxxxxxxxxx
    Signed-off-by: Peter Maydell <peter.maydell@xxxxxxxxxx>
    Message-id: 1513183941-24300-3-git-send-email-peter.maydell@xxxxxxxxxx
    Reviewed-by: Alistair Francis <alistair.francis@xxxxxxxxxx>
    (cherry picked from commit 0cf09852015e47a5fbb974ff7ac320366afd21ee)
    Signed-off-by: Michael Roth <mdroth@xxxxxxxxxxxxxxxxxx>
---
 hw/intc/arm_gic.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/hw/intc/arm_gic.c b/hw/intc/arm_gic.c
index 5a0e2a3..d701e49 100644
--- a/hw/intc/arm_gic.c
+++ b/hw/intc/arm_gic.c
@@ -1261,7 +1261,8 @@ static MemTxResult gic_cpu_read(GICState *s, int cpu, int 
offset,
     default:
         qemu_log_mask(LOG_GUEST_ERROR,
                       "gic_cpu_read: Bad offset %x\n", (int)offset);
-        return MEMTX_ERROR;
+        *data = 0;
+        break;
     }
     return MEMTX_OK;
 }
@@ -1329,7 +1330,7 @@ static MemTxResult gic_cpu_write(GICState *s, int cpu, 
int offset,
     default:
         qemu_log_mask(LOG_GUEST_ERROR,
                       "gic_cpu_write: Bad offset %x\n", (int)offset);
-        return MEMTX_ERROR;
+        return MEMTX_OK;
     }
     gic_update(s);
     return MEMTX_OK;
--
generated by git-patchbot for /home/xen/git/qemu-xen.git#master

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/xen-changelog

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.