Revision ca9c39fa hw/esp.c
b/hw/esp.c | ||
---|---|---|
63 | 63 |
uint8_t ti_buf[TI_BUFSZ]; |
64 | 64 |
uint32_t sense; |
65 | 65 |
uint32_t dma; |
66 |
SCSIBus *bus;
|
|
66 |
SCSIBus bus; |
|
67 | 67 |
SCSIDevice *current_dev; |
68 | 68 |
uint8_t cmdbuf[TI_BUFSZ]; |
69 | 69 |
uint32_t cmdlen; |
... | ... | |
191 | 191 |
s->async_len = 0; |
192 | 192 |
} |
193 | 193 |
|
194 |
if (target >= ESP_MAX_DEVS || !s->bus->devs[target]) {
|
|
194 |
if (target >= ESP_MAX_DEVS || !s->bus.devs[target]) {
|
|
195 | 195 |
// No such drive |
196 | 196 |
s->rregs[ESP_RSTAT] = 0; |
197 | 197 |
s->rregs[ESP_RINTR] = INTR_DC; |
... | ... | |
199 | 199 |
esp_raise_irq(s); |
200 | 200 |
return 0; |
201 | 201 |
} |
202 |
s->current_dev = s->bus->devs[target];
|
|
202 |
s->current_dev = s->bus.devs[target];
|
|
203 | 203 |
return dmalen; |
204 | 204 |
} |
205 | 205 |
|
... | ... | |
672 | 672 |
|
673 | 673 |
qdev_init_gpio_in(&dev->qdev, parent_esp_reset, 1); |
674 | 674 |
|
675 |
s->bus = scsi_bus_new(&dev->qdev, 0, ESP_MAX_DEVS, esp_command_complete);
|
|
676 |
scsi_bus_legacy_handle_cmdline(s->bus); |
|
675 |
scsi_bus_new(&s->bus, &dev->qdev, 0, ESP_MAX_DEVS, esp_command_complete);
|
|
676 |
scsi_bus_legacy_handle_cmdline(&s->bus);
|
|
677 | 677 |
return 0; |
678 | 678 |
} |
679 | 679 |
|
Also available in: Unified diff