From: "Philippe Mathieu-Daudé" <philmd@linaro.org>
To: qemu-devel@nongnu.org
Cc: qemu-arm@nongnu.org, qemu-block@nongnu.org, qemu-ppc@nongnu.org,
"Philippe Mathieu-Daudé" <philmd@linaro.org>,
"Thomas Huth" <thuth@redhat.com>,
"Paolo Bonzini" <pbonzini@redhat.com>,
"Nicholas Piggin" <npiggin@gmail.com>,
"Daniel Henrique Barboza" <danielhb413@gmail.com>,
"Cédric Le Goater" <clg@kaod.org>
Subject: [PULL 05/25] hw/ppc/ppc4xx_pci: Move ppc4xx_pci.c to hw/pci-host/
Date: Wed, 21 Feb 2024 22:16:05 +0100 [thread overview]
Message-ID: <20240221211626.48190-6-philmd@linaro.org> (raw)
In-Reply-To: <20240221211626.48190-1-philmd@linaro.org>
ppc4xx_pci.c is moved from the target specific ppc_ss[] meson
source set to pci_ss[] which is common to all targets: the
object is built once.
Declare PPC4XX_PCI selector in pci-host/Kconfig.
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Message-Id: <20240215105017.57748-4-philmd@linaro.org>
---
MAINTAINERS | 1 +
hw/{ppc => pci-host}/ppc4xx_pci.c | 0
hw/pci-host/ppce500.c | 2 +-
hw/pci-host/Kconfig | 4 ++++
hw/pci-host/meson.build | 1 +
hw/pci-host/trace-events | 4 ++++
hw/ppc/Kconfig | 2 +-
hw/ppc/meson.build | 1 -
hw/ppc/trace-events | 4 ----
9 files changed, 12 insertions(+), 7 deletions(-)
rename hw/{ppc => pci-host}/ppc4xx_pci.c (100%)
diff --git a/MAINTAINERS b/MAINTAINERS
index 9b6ce9a934..8d9ccd5073 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -1423,6 +1423,7 @@ Bamboo
L: qemu-ppc@nongnu.org
S: Orphan
F: hw/ppc/ppc440_bamboo.c
+F: hw/pci-host/ppc4xx_pci.c
F: tests/avocado/ppc_bamboo.py
e500
diff --git a/hw/ppc/ppc4xx_pci.c b/hw/pci-host/ppc4xx_pci.c
similarity index 100%
rename from hw/ppc/ppc4xx_pci.c
rename to hw/pci-host/ppc4xx_pci.c
diff --git a/hw/pci-host/ppce500.c b/hw/pci-host/ppce500.c
index fa0d67b342..95b983b2b3 100644
--- a/hw/pci-host/ppce500.c
+++ b/hw/pci-host/ppce500.c
@@ -5,7 +5,7 @@
*
* Author: Yu Liu, <yu.liu@freescale.com>
*
- * This file is derived from hw/ppc4xx_pci.c,
+ * This file is derived from ppc4xx_pci.c,
* the copyright for that material belongs to the original owners.
*
* This is free software; you can redistribute it and/or modify
diff --git a/hw/pci-host/Kconfig b/hw/pci-host/Kconfig
index f046d76a68..0a221e719e 100644
--- a/hw/pci-host/Kconfig
+++ b/hw/pci-host/Kconfig
@@ -6,6 +6,10 @@ config XEN_IGD_PASSTHROUGH
default y
depends on XEN && PCI_I440FX
+config PPC4XX_PCI
+ bool
+ select PCI
+
config RAVEN_PCI
bool
select PCI
diff --git a/hw/pci-host/meson.build b/hw/pci-host/meson.build
index 36d5ab756f..eb6dc71c88 100644
--- a/hw/pci-host/meson.build
+++ b/hw/pci-host/meson.build
@@ -14,6 +14,7 @@ pci_ss.add(when: 'CONFIG_REMOTE_PCIHOST', if_true: files('remote.c'))
pci_ss.add(when: 'CONFIG_SH_PCI', if_true: files('sh_pci.c'))
# PPC devices
+pci_ss.add(when: 'CONFIG_PPC4XX_PCI', if_true: files('ppc4xx_pci.c'))
pci_ss.add(when: 'CONFIG_RAVEN_PCI', if_true: files('raven.c'))
pci_ss.add(when: 'CONFIG_GRACKLE_PCI', if_true: files('grackle.c'))
# NewWorld PowerMac
diff --git a/hw/pci-host/trace-events b/hw/pci-host/trace-events
index b2f47e6335..90a37ebff0 100644
--- a/hw/pci-host/trace-events
+++ b/hw/pci-host/trace-events
@@ -37,6 +37,10 @@ unin_data_read(uint64_t addr, unsigned len, uint64_t val) "read addr 0x%"PRIx64
unin_write(uint64_t addr, uint64_t value) "addr=0x%" PRIx64 " val=0x%"PRIx64
unin_read(uint64_t addr, uint64_t value) "addr=0x%" PRIx64 " val=0x%"PRIx64
+# ppc4xx_pci.c
+ppc4xx_pci_map_irq(int32_t devfn, int irq_num, int slot) "devfn 0x%x irq %d -> %d"
+ppc4xx_pci_set_irq(int irq_num) "PCI irq %d"
+
# pnv_phb4.c
pnv_phb4_xive_notify(uint64_t notif_port, uint64_t data) "notif=@0x%"PRIx64" data=0x%"PRIx64
pnv_phb4_xive_notify_ic(uint64_t addr, uint64_t data) "addr=@0x%"PRIx64" data=0x%"PRIx64
diff --git a/hw/ppc/Kconfig b/hw/ppc/Kconfig
index 44263a58c4..82e847d22c 100644
--- a/hw/ppc/Kconfig
+++ b/hw/ppc/Kconfig
@@ -53,7 +53,7 @@ config PPC440
config PPC4XX
bool
select BITBANG_I2C
- select PCI
+ select PPC4XX_PCI
select PPC_UIC
config SAM460EX
diff --git a/hw/ppc/meson.build b/hw/ppc/meson.build
index eba3406e7f..d0efc0aba5 100644
--- a/hw/ppc/meson.build
+++ b/hw/ppc/meson.build
@@ -63,7 +63,6 @@ ppc_ss.add(when: 'CONFIG_PPC440', if_true: files(
'ppc440_pcix.c', 'ppc440_uc.c'))
ppc_ss.add(when: 'CONFIG_PPC4XX', if_true: files(
'ppc4xx_devs.c',
- 'ppc4xx_pci.c',
'ppc4xx_sdram.c'))
ppc_ss.add(when: 'CONFIG_SAM460EX', if_true: files('sam460ex.c'))
# PReP
diff --git a/hw/ppc/trace-events b/hw/ppc/trace-events
index f670e8906c..b59fbf340f 100644
--- a/hw/ppc/trace-events
+++ b/hw/ppc/trace-events
@@ -146,10 +146,6 @@ rs6000mc_size_read(uint32_t addr, uint32_t val) "read addr=0x%x val=0x%x"
rs6000mc_size_write(uint32_t addr, uint32_t val) "write addr=0x%x val=0x%x"
rs6000mc_parity_read(uint32_t addr, uint32_t val) "read addr=0x%x val=0x%x"
-# ppc4xx_pci.c
-ppc4xx_pci_map_irq(int32_t devfn, int irq_num, int slot) "devfn 0x%x irq %d -> %d"
-ppc4xx_pci_set_irq(int irq_num) "PCI irq %d"
-
# ppc440_pcix.c
ppc440_pcix_map_irq(int32_t devfn, int irq_num, int slot) "devfn 0x%x irq %d -> %d"
ppc440_pcix_set_irq(int irq_num) "PCI irq %d"
--
2.41.0
next prev parent reply other threads:[~2024-02-21 21:23 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-02-21 21:16 [PULL 00/25] Misc HW patches for 2024-02-21 Philippe Mathieu-Daudé
2024-02-21 21:16 ` [PULL 01/25] hw/input/pckbd: Open-code i8042_setup_a20_line() wrapper Philippe Mathieu-Daudé
2024-02-21 21:16 ` [PULL 02/25] hw/sysbus: Inline and remove sysbus_add_io() Philippe Mathieu-Daudé
2024-02-21 21:16 ` [PULL 03/25] hw/ppc/ppc4xx_pci: Remove unused "hw/ppc/ppc.h" header Philippe Mathieu-Daudé
2024-02-21 21:16 ` [PULL 04/25] hw/ppc/ppc4xx_pci: Extract PCI host definitions to hw/pci-host/ppc4xx.h Philippe Mathieu-Daudé
2024-02-21 21:16 ` Philippe Mathieu-Daudé [this message]
2024-02-21 21:16 ` [PULL 06/25] hw/ppc/ppc440_pcix: Move ppc440_pcix.c to hw/pci-host/ Philippe Mathieu-Daudé
2024-02-21 21:16 ` [PULL 07/25] hw/i2c/smbus_slave: Add object path on error prints Philippe Mathieu-Daudé
2024-02-21 21:16 ` [PULL 08/25] hw/i386/pc_piix: Share pc_cmos_init() invocation between pc and isapc machines Philippe Mathieu-Daudé
2024-02-21 21:16 ` [PULL 09/25] hw/i386/pc: Store pointers to IDE buses in PCMachineState Philippe Mathieu-Daudé
2024-02-21 21:16 ` [PULL 10/25] hw/i386/pc: Do pc_cmos_init_late() from pc_machine_done() Philippe Mathieu-Daudé
2024-02-21 21:16 ` [PULL 11/25] hw/i386/x86: Turn apic_xrupt_override into class attribute Philippe Mathieu-Daudé
2024-02-21 21:16 ` [PULL 12/25] hw/i386/pc: Merge pc_guest_info_init() into pc_machine_initfn() Philippe Mathieu-Daudé
2024-02-21 21:16 ` [PULL 13/25] hw/i386/pc: Defer smbios_set_defaults() to machine_done Philippe Mathieu-Daudé
2024-02-21 21:16 ` [PULL 14/25] hw/i386/pc: Confine system flash handling to pc_sysfw Philippe Mathieu-Daudé
2024-02-25 13:03 ` Volker Rümelin
2024-02-25 19:39 ` Bernhard Beschow
2024-02-21 21:16 ` [PULL 15/25] hw/i386/pc_sysfw: Inline pc_system_flash_create() and remove it Philippe Mathieu-Daudé
2024-02-21 21:16 ` [PULL 16/25] hw/i386/pc_q35: Populate interrupt handlers before realizing LPC PCI function Philippe Mathieu-Daudé
2024-02-21 21:16 ` [PULL 17/25] hw/isa/meson.build: Sort alphabetically Philippe Mathieu-Daudé
2024-02-21 21:16 ` [PULL 18/25] hw/ide: Add the possibility to disable the CompactFlash device in the build Philippe Mathieu-Daudé
2024-02-21 21:16 ` [PULL 19/25] hw/ide: Split qdev.c into ide-bus.c and ide-dev.c Philippe Mathieu-Daudé
2024-02-21 21:16 ` [PULL 20/25] hw/ide: Move IDE DMA related definitions to a separate header ide-dma.h Philippe Mathieu-Daudé
2024-02-21 21:16 ` [PULL 21/25] hw/ide: Move IDE device related definitions to ide-dev.h Philippe Mathieu-Daudé
2024-02-21 21:16 ` [PULL 22/25] hw/ide: Move IDE bus related definitions to a new header ide-bus.h Philippe Mathieu-Daudé
2024-02-21 21:16 ` [PULL 23/25] hw/ide: Remove the include/hw/ide.h legacy file Philippe Mathieu-Daudé
2024-02-21 21:16 ` [PULL 24/25] hw/ide: Stop exposing internal.h to non-IDE files Philippe Mathieu-Daudé
2024-02-21 21:16 ` [PULL 25/25] hw/sparc/leon3: Fix wrong usage of DO_UPCAST macro Philippe Mathieu-Daudé
2024-02-22 10:22 ` [PULL 00/25] Misc HW patches for 2024-02-21 Philippe Mathieu-Daudé
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240221211626.48190-6-philmd@linaro.org \
--to=philmd@linaro.org \
--cc=clg@kaod.org \
--cc=danielhb413@gmail.com \
--cc=npiggin@gmail.com \
--cc=pbonzini@redhat.com \
--cc=qemu-arm@nongnu.org \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
--cc=qemu-ppc@nongnu.org \
--cc=thuth@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).