diff options
author | Kamil Rytarowski <n54@gmx.com> | 2017-09-09 16:21:16 +0200 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2017-09-19 14:09:33 +0200 |
commit | 80cac47e951f2d94e7f7b9b112612acb2af9c3ca (patch) | |
tree | c16b8a4305745e0164830ec6508fea2b097ab68e | |
parent | a16878d224657b245892b4f6c93c6ea75f12ef00 (diff) |
scsi/esp: Rename the ESP macro to ESP_STATE
SunOS defines ESP (x86 register) in <sys/regset.h> as 7.
This fixes build on SmartOS (Joyent).
Signed-off-by: Kamil Rytarowski <n54@gmx.com>
Message-Id: <20170909142116.26816-1-n54@gmx.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
-rw-r--r-- | hw/scsi/esp.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/hw/scsi/esp.c b/hw/scsi/esp.c index eee831efeb..22c2d91e39 100644 --- a/hw/scsi/esp.c +++ b/hw/scsi/esp.c @@ -593,7 +593,7 @@ const VMStateDescription vmstate_esp = { }; #define TYPE_ESP "esp" -#define ESP(obj) OBJECT_CHECK(SysBusESPState, (obj), TYPE_ESP) +#define ESP_STATE(obj) OBJECT_CHECK(SysBusESPState, (obj), TYPE_ESP) typedef struct { /*< private >*/ @@ -644,7 +644,7 @@ void esp_init(hwaddr espaddr, int it_shift, ESPState *esp; dev = qdev_create(NULL, TYPE_ESP); - sysbus = ESP(dev); + sysbus = ESP_STATE(dev); esp = &sysbus->esp; esp->dma_memory_read = dma_memory_read; esp->dma_memory_write = dma_memory_write; @@ -672,7 +672,7 @@ static const struct SCSIBusInfo esp_scsi_info = { static void sysbus_esp_gpio_demux(void *opaque, int irq, int level) { - SysBusESPState *sysbus = ESP(opaque); + SysBusESPState *sysbus = ESP_STATE(opaque); ESPState *s = &sysbus->esp; switch (irq) { @@ -688,7 +688,7 @@ static void sysbus_esp_gpio_demux(void *opaque, int irq, int level) static void sysbus_esp_realize(DeviceState *dev, Error **errp) { SysBusDevice *sbd = SYS_BUS_DEVICE(dev); - SysBusESPState *sysbus = ESP(dev); + SysBusESPState *sysbus = ESP_STATE(dev); ESPState *s = &sysbus->esp; sysbus_init_irq(sbd, &s->irq); @@ -706,7 +706,7 @@ static void sysbus_esp_realize(DeviceState *dev, Error **errp) static void sysbus_esp_hard_reset(DeviceState *dev) { - SysBusESPState *sysbus = ESP(dev); + SysBusESPState *sysbus = ESP_STATE(dev); esp_hard_reset(&sysbus->esp); } |