From fdfba1a298ae26dd44bcfdb0429314139a0bc55a Mon Sep 17 00:00:00 2001 From: "Edgar E. Iglesias" Date: Fri, 15 Nov 2013 14:46:38 +0100 Subject: exec: Make ldl_*_phys input an AddressSpace Reviewed-by: Peter Maydell Signed-off-by: Edgar E. Iglesias --- hw/scsi/megasas.c | 4 ++-- hw/scsi/vmw_pvscsi.c | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) (limited to 'hw/scsi') diff --git a/hw/scsi/megasas.c b/hw/scsi/megasas.c index 7c5a1a2..a655980 100644 --- a/hw/scsi/megasas.c +++ b/hw/scsi/megasas.c @@ -602,8 +602,8 @@ static int megasas_init_firmware(MegasasState *s, MegasasCmd *cmd) pa_lo = le32_to_cpu(initq->pi_addr_lo); pa_hi = le32_to_cpu(initq->pi_addr_hi); s->producer_pa = ((uint64_t) pa_hi << 32) | pa_lo; - s->reply_queue_head = ldl_le_phys(s->producer_pa); - s->reply_queue_tail = ldl_le_phys(s->consumer_pa); + s->reply_queue_head = ldl_le_phys(&address_space_memory, s->producer_pa); + s->reply_queue_tail = ldl_le_phys(&address_space_memory, s->consumer_pa); flags = le32_to_cpu(initq->flags); if (flags & MFI_QUEUE_FLAG_CONTEXT64) { s->flags |= MEGASAS_MASK_USE_QUEUE64; diff --git a/hw/scsi/vmw_pvscsi.c b/hw/scsi/vmw_pvscsi.c index 94b328f..6cc6c1b 100644 --- a/hw/scsi/vmw_pvscsi.c +++ b/hw/scsi/vmw_pvscsi.c @@ -43,7 +43,8 @@ (sizeof(PVSCSICmdDescSetupRings)/sizeof(uint32_t)) #define RS_GET_FIELD(rs_pa, field) \ - (ldl_le_phys(rs_pa + offsetof(struct PVSCSIRingsState, field))) + (ldl_le_phys(&address_space_memory, \ + rs_pa + offsetof(struct PVSCSIRingsState, field))) #define RS_SET_FIELD(rs_pa, field, val) \ (stl_le_phys(rs_pa + offsetof(struct PVSCSIRingsState, field), val)) -- cgit v1.1