aboutsummaryrefslogtreecommitdiff
path: root/include/hw
diff options
context:
space:
mode:
authorXiaojuan Yang <yangxiaojuan@loongson.cn>2022-07-29 15:30:18 +0800
committerRichard Henderson <richard.henderson@linaro.org>2022-07-29 15:07:55 -0700
commit74725231d6fd1605d8b60c5afc2c0aec2f0b1e67 (patch)
treed1d61e002dc917bdc59f8f48b230dc711228b002 /include/hw
parent587858ed0dd4833eadb3894d03d687fa461c6915 (diff)
hw/loongarch: Change macro name 'LS7A_XXX' to 'VIRT_XXX'
Change macro name 'LS7A_XXX' to 'VIRT_XXX', as the loongarch virt machinue use the GPEX bridge instead of LS7A bridge. So the macro name should keep consistency. Signed-off-by: Xiaojuan Yang <yangxiaojuan@loongson.cn> Message-Id: <20220729073018.27037-3-yangxiaojuan@loongson.cn> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Diffstat (limited to 'include/hw')
-rw-r--r--include/hw/loongarch/virt.h8
-rw-r--r--include/hw/pci-host/ls7a.h43
2 files changed, 24 insertions, 27 deletions
diff --git a/include/hw/loongarch/virt.h b/include/hw/loongarch/virt.h
index f4f24df428..92b84de1c5 100644
--- a/include/hw/loongarch/virt.h
+++ b/include/hw/loongarch/virt.h
@@ -15,8 +15,8 @@
#define LOONGARCH_MAX_VCPUS 4
-#define LOONGARCH_ISA_IO_BASE 0x18000000UL
-#define LOONGARCH_ISA_IO_SIZE 0x0004000
+#define VIRT_ISA_IO_BASE 0x18000000UL
+#define VIRT_ISA_IO_SIZE 0x0004000
#define VIRT_FWCFG_BASE 0x1e020000UL
#define VIRT_BIOS_BASE 0x1c000000UL
#define VIRT_BIOS_SIZE (4 * MiB)
@@ -28,8 +28,8 @@
#define VIRT_GED_MEM_ADDR (VIRT_GED_EVT_ADDR + ACPI_GED_EVT_SEL_LEN)
#define VIRT_GED_REG_ADDR (VIRT_GED_MEM_ADDR + MEMORY_HOTPLUG_IO_LEN)
-#define LA_FDT_BASE 0x1c400000
-#define LA_FDT_SIZE 0x100000
+#define VIRT_FDT_BASE 0x1c400000
+#define VIRT_FDT_SIZE 0x100000
struct LoongArchMachineState {
/*< private >*/
diff --git a/include/hw/pci-host/ls7a.h b/include/hw/pci-host/ls7a.h
index 0fdc86b973..cdde0af1f8 100644
--- a/include/hw/pci-host/ls7a.h
+++ b/include/hw/pci-host/ls7a.h
@@ -15,34 +15,31 @@
#include "qemu/range.h"
#include "qom/object.h"
-#define LS7A_PCI_MEM_BASE 0x40000000UL
-#define LS7A_PCI_MEM_SIZE 0x40000000UL
-#define LS7A_PCI_IO_OFFSET 0x4000
-#define LS_PCIECFG_BASE 0x20000000
-#define LS_PCIECFG_SIZE 0x08000000
-#define LS7A_PCI_IO_BASE 0x18004000UL
-#define LS7A_PCI_IO_SIZE 0xC000
+#define VIRT_PCI_MEM_BASE 0x40000000UL
+#define VIRT_PCI_MEM_SIZE 0x40000000UL
+#define VIRT_PCI_IO_OFFSET 0x4000
+#define VIRT_PCI_CFG_BASE 0x20000000
+#define VIRT_PCI_CFG_SIZE 0x08000000
+#define VIRT_PCI_IO_BASE 0x18004000UL
+#define VIRT_PCI_IO_SIZE 0xC000
-#define LS7A_PCI_MEM_BASE 0x40000000UL
-#define LS7A_PCI_MEM_SIZE 0x40000000UL
-
-#define LS7A_PCH_REG_BASE 0x10000000UL
-#define LS7A_IOAPIC_REG_BASE (LS7A_PCH_REG_BASE)
-#define LS7A_PCH_MSI_ADDR_LOW 0x2FF00000UL
+#define VIRT_PCH_REG_BASE 0x10000000UL
+#define VIRT_IOAPIC_REG_BASE (VIRT_PCH_REG_BASE)
+#define VIRT_PCH_MSI_ADDR_LOW 0x2FF00000UL
/*
* According to the kernel pch irq start from 64 offset
* 0 ~ 16 irqs used for non-pci device while 16 ~ 64 irqs
* used for pci device.
*/
-#define PCH_PIC_IRQ_OFFSET 64
-#define LS7A_DEVICE_IRQS 16
-#define LS7A_PCI_IRQS 48
-#define LS7A_UART_IRQ (PCH_PIC_IRQ_OFFSET + 2)
-#define LS7A_UART_BASE 0x1fe001e0
-#define LS7A_RTC_IRQ (PCH_PIC_IRQ_OFFSET + 3)
-#define LS7A_MISC_REG_BASE (LS7A_PCH_REG_BASE + 0x00080000)
-#define LS7A_RTC_REG_BASE (LS7A_MISC_REG_BASE + 0x00050100)
-#define LS7A_RTC_LEN 0x100
-#define LS7A_SCI_IRQ (PCH_PIC_IRQ_OFFSET + 4)
+#define PCH_PIC_IRQ_OFFSET 64
+#define VIRT_DEVICE_IRQS 16
+#define VIRT_PCI_IRQS 48
+#define VIRT_UART_IRQ (PCH_PIC_IRQ_OFFSET + 2)
+#define VIRT_UART_BASE 0x1fe001e0
+#define VIRT_RTC_IRQ (PCH_PIC_IRQ_OFFSET + 3)
+#define VIRT_MISC_REG_BASE (VIRT_PCH_REG_BASE + 0x00080000)
+#define VIRT_RTC_REG_BASE (VIRT_MISC_REG_BASE + 0x00050100)
+#define VIRT_RTC_LEN 0x100
+#define VIRT_SCI_IRQ (PCH_PIC_IRQ_OFFSET + 4)
#endif