aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilippe Mathieu-Daudé <philmd@linaro.org>2023-02-14 16:33:38 +0100
committerPhilippe Mathieu-Daudé <philmd@linaro.org>2023-02-27 22:29:02 +0100
commite29b124610f9b92c315e4655f52dec36d23de247 (patch)
tree5821851e4fad35be4f4bb03f3b84207b93b8679a
parentb6a5ab27fbc42731877b0297062dccd4239874ff (diff)
downloadqemu-e29b124610f9b92c315e4655f52dec36d23de247.zip
qemu-e29b124610f9b92c315e4655f52dec36d23de247.tar.gz
qemu-e29b124610f9b92c315e4655f52dec36d23de247.tar.bz2
hw/ide: Rename ide_register_restart_cb -> ide_bus_register_restart_cb
ide_register_restart_cb() operates on a IDEBus; rename it as ide_bus_register_restart_cb() to emphasize its first argument is a IDEBus. Mechanical change using: $ sed -i -e 's/ide_register_restart_cb/ide_bus_register_restart_cb/g' \ $(git grep -l ide_register_restart_cb) Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org> Message-Id: <20230215112712.23110-13-philmd@linaro.org> Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
-rw-r--r--hw/ide/ahci.c2
-rw-r--r--hw/ide/cmd646.c2
-rw-r--r--hw/ide/core.c2
-rw-r--r--hw/ide/isa.c2
-rw-r--r--hw/ide/piix.c2
-rw-r--r--hw/ide/sii3112.c2
-rw-r--r--hw/ide/via.c2
-rw-r--r--include/hw/ide/internal.h2
8 files changed, 8 insertions, 8 deletions
diff --git a/hw/ide/ahci.c b/hw/ide/ahci.c
index f338a55..316dbb9 100644
--- a/hw/ide/ahci.c
+++ b/hw/ide/ahci.c
@@ -1560,7 +1560,7 @@ void ahci_realize(AHCIState *s, DeviceState *qdev, AddressSpace *as, int ports)
ad->port_no = i;
ad->port.dma = &ad->dma;
ad->port.dma->ops = &ahci_dma_ops;
- ide_register_restart_cb(&ad->port);
+ ide_bus_register_restart_cb(&ad->port);
}
g_free(irqs);
}
diff --git a/hw/ide/cmd646.c b/hw/ide/cmd646.c
index 94c5762..2865bc2 100644
--- a/hw/ide/cmd646.c
+++ b/hw/ide/cmd646.c
@@ -298,7 +298,7 @@ static void pci_cmd646_ide_realize(PCIDevice *dev, Error **errp)
bmdma_init(&d->bus[i], &d->bmdma[i], d);
d->bmdma[i].bus = &d->bus[i];
- ide_register_restart_cb(&d->bus[i]);
+ ide_bus_register_restart_cb(&d->bus[i]);
}
}
diff --git a/hw/ide/core.c b/hw/ide/core.c
index 117e26c..5897411 100644
--- a/hw/ide/core.c
+++ b/hw/ide/core.c
@@ -2759,7 +2759,7 @@ static void ide_restart_cb(void *opaque, bool running, RunState state)
}
}
-void ide_register_restart_cb(IDEBus *bus)
+void ide_bus_register_restart_cb(IDEBus *bus)
{
if (bus->dma->ops->restart_dma) {
bus->vmstate = qemu_add_vm_change_state_handler(ide_restart_cb, bus);
diff --git a/hw/ide/isa.c b/hw/ide/isa.c
index 74f7b43..f8ed26b 100644
--- a/hw/ide/isa.c
+++ b/hw/ide/isa.c
@@ -74,7 +74,7 @@ static void isa_ide_realizefn(DeviceState *dev, Error **errp)
ide_init_ioport(&s->bus, isadev, s->iobase, s->iobase2);
ide_init2(&s->bus, isa_get_irq(isadev, s->irqnum));
vmstate_register(VMSTATE_IF(dev), 0, &vmstate_ide_isa, s);
- ide_register_restart_cb(&s->bus);
+ ide_bus_register_restart_cb(&s->bus);
}
ISADevice *isa_ide_init(ISABus *bus, int iobase, int iobase2, int irqnum,
diff --git a/hw/ide/piix.c b/hw/ide/piix.c
index 267dbf3..daeb9b6 100644
--- a/hw/ide/piix.c
+++ b/hw/ide/piix.c
@@ -149,7 +149,7 @@ static int pci_piix_init_ports(PCIIDEState *d)
bmdma_init(&d->bus[i], &d->bmdma[i], d);
d->bmdma[i].bus = &d->bus[i];
- ide_register_restart_cb(&d->bus[i]);
+ ide_bus_register_restart_cb(&d->bus[i]);
}
return 0;
diff --git a/hw/ide/sii3112.c b/hw/ide/sii3112.c
index 46204f1..c918370 100644
--- a/hw/ide/sii3112.c
+++ b/hw/ide/sii3112.c
@@ -288,7 +288,7 @@ static void sii3112_pci_realize(PCIDevice *dev, Error **errp)
bmdma_init(&s->bus[i], &s->bmdma[i], s);
s->bmdma[i].bus = &s->bus[i];
- ide_register_restart_cb(&s->bus[i]);
+ ide_bus_register_restart_cb(&s->bus[i]);
}
}
diff --git a/hw/ide/via.c b/hw/ide/via.c
index e1a4294..fd39822 100644
--- a/hw/ide/via.c
+++ b/hw/ide/via.c
@@ -195,7 +195,7 @@ static void via_ide_realize(PCIDevice *dev, Error **errp)
bmdma_init(&d->bus[i], &d->bmdma[i], d);
d->bmdma[i].bus = &d->bus[i];
- ide_register_restart_cb(&d->bus[i]);
+ ide_bus_register_restart_cb(&d->bus[i]);
}
}
diff --git a/include/hw/ide/internal.h b/include/hw/ide/internal.h
index ccfe064..cc95cd4 100644
--- a/include/hw/ide/internal.h
+++ b/include/hw/ide/internal.h
@@ -620,7 +620,7 @@ void ide_init2(IDEBus *bus, qemu_irq irq);
void ide_exit(IDEState *s);
int ide_init_ioport(IDEBus *bus, ISADevice *isa, int iobase, int iobase2);
void ide_bus_set_irq(IDEBus *bus);
-void ide_register_restart_cb(IDEBus *bus);
+void ide_bus_register_restart_cb(IDEBus *bus);
void ide_exec_cmd(IDEBus *bus, uint32_t val);