[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 7/8] esp-pci: Rename PCI_ESP to AM53C974
From: |
Eduardo Habkost |
Subject: |
[PATCH 7/8] esp-pci: Rename PCI_ESP to AM53C974 |
Date: |
Thu, 3 Sep 2020 14:01:27 -0400 |
Rename the type checking function to be consistent with the type
name constant (TYPE_AM53C974) and type name string ("am53c974").
Suggested-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Suggested-by: "Daniel P. Berrangé" <berrange@redhat.com>
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
---
Changes v1 -> v2:
* New patch added to series v2
---
Cc: Paolo Bonzini <pbonzini@redhat.com>
Cc: Fam Zheng <fam@euphon.net>
Cc: qemu-devel@nongnu.org
---
hw/scsi/esp-pci.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/hw/scsi/esp-pci.c b/hw/scsi/esp-pci.c
index e30a911b21..117383037e 100644
--- a/hw/scsi/esp-pci.c
+++ b/hw/scsi/esp-pci.c
@@ -38,7 +38,7 @@
#define TYPE_AM53C974 "am53c974"
typedef struct PCIESPState PCIESPState;
-DECLARE_INSTANCE_CHECKER(PCIESPState, PCI_ESP,
+DECLARE_INSTANCE_CHECKER(PCIESPState, AM53C974,
TYPE_AM53C974)
#define DMA_CMD 0x0
@@ -305,7 +305,7 @@ static const MemoryRegionOps esp_pci_io_ops = {
static void esp_pci_hard_reset(DeviceState *dev)
{
- PCIESPState *pci = PCI_ESP(dev);
+ PCIESPState *pci = AM53C974(dev);
esp_hard_reset(&pci->esp);
pci->dma_regs[DMA_CMD] &= ~(DMA_CMD_DIR | DMA_CMD_INTE_D | DMA_CMD_INTE_P
| DMA_CMD_MDL | DMA_CMD_DIAG | DMA_CMD_MASK);
@@ -352,7 +352,7 @@ static const struct SCSIBusInfo esp_pci_scsi_info = {
static void esp_pci_scsi_realize(PCIDevice *dev, Error **errp)
{
- PCIESPState *pci = PCI_ESP(dev);
+ PCIESPState *pci = AM53C974(dev);
DeviceState *d = DEVICE(dev);
ESPState *s = &pci->esp;
uint8_t *pci_conf;
@@ -377,7 +377,7 @@ static void esp_pci_scsi_realize(PCIDevice *dev, Error
**errp)
static void esp_pci_scsi_uninit(PCIDevice *d)
{
- PCIESPState *pci = PCI_ESP(d);
+ PCIESPState *pci = AM53C974(d);
qemu_free_irq(pci->esp.irq);
}
--
2.26.2
- [PATCH 2/8] i8254: Rename PIT to ISA_PIT, (continued)
- [PATCH 2/8] i8254: Rename PIT to ISA_PIT, Eduardo Habkost, 2020/09/03
- [PATCH 3/8] i8259: Rename TYPE_I8259 to TYPE_ISA_I8259, Eduardo Habkost, 2020/09/03
- [PATCH 4/8] i8259: Rename PIC to ISA_I8259, Eduardo Habkost, 2020/09/03
- [PATCH 5/8] i8259: Rename KVM_PIC to KVM_I8259, Eduardo Habkost, 2020/09/03
- [PATCH 6/8] esp-pci: Rename TYPE_AM53C974_DEVICE to TYPE_AM53C974, Eduardo Habkost, 2020/09/03
- [PATCH 7/8] esp-pci: Rename PCI_ESP to AM53C974,
Eduardo Habkost <=
- [PATCH 8/8] tusb6010: Rename TUSB to TUSB6010, Eduardo Habkost, 2020/09/03