aboutsummaryrefslogtreecommitdiff
path: root/hw/lsi53c895a.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/lsi53c895a.c')
-rw-r--r--hw/lsi53c895a.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/lsi53c895a.c b/hw/lsi53c895a.c
index 0d8248ebe8..bf9f072fe9 100644
--- a/hw/lsi53c895a.c
+++ b/hw/lsi53c895a.c
@@ -1960,7 +1960,7 @@ static void lsi_mmio_mapfunc(PCIDevice *pci_dev, int region_num,
void lsi_scsi_attach(DeviceState *host, BlockDriverState *bd, int id)
{
- LSIState *s = (LSIState *)host;
+ LSIState *s = DO_UPCAST(LSIState, dev.qdev, host);
if (id < 0) {
for (id = 0; id < LSI_MAX_DEVS; id++) {