[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 42/53] lasi: move from hw/hppa to hw/misc
From: |
Mark Cave-Ayland |
Subject: |
[PULL 42/53] lasi: move from hw/hppa to hw/misc |
Date: |
Sun, 8 May 2022 20:56:39 +0100 |
Move the LASI device implementation from hw/hppa to hw/misc so that it is
located with all the other miscellaneous devices.
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Acked-by: Helge Deller <deller@gmx.de>
Message-Id: <20220504092600.10048-43-mark.cave-ayland@ilande.co.uk>
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
---
MAINTAINERS | 2 ++
hw/hppa/Kconfig | 1 +
hw/hppa/machine.c | 2 +-
hw/hppa/meson.build | 2 +-
hw/hppa/trace-events | 5 -----
hw/misc/Kconfig | 3 +++
hw/{hppa => misc}/lasi.c | 3 +--
hw/misc/meson.build | 3 +++
hw/misc/trace-events | 5 +++++
{hw/hppa => include/hw/misc}/lasi.h | 0
10 files changed, 17 insertions(+), 9 deletions(-)
rename hw/{hppa => misc}/lasi.c (99%)
rename {hw/hppa => include/hw/misc}/lasi.h (100%)
diff --git a/MAINTAINERS b/MAINTAINERS
index 59210b093a..662ec47246 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -1113,7 +1113,9 @@ S: Odd Fixes
F: configs/devices/hppa-softmmu/default.mak
F: hw/hppa/
F: hw/net/*i82596*
+F: hw/misc/lasi.c
F: hw/pci-host/dino.c
+F: include/hw/misc/lasi.h
F: include/hw/net/lasi_82596.h
F: include/hw/pci-host/dino.h
F: pc-bios/hppa-firmware.img
diff --git a/hw/hppa/Kconfig b/hw/hppa/Kconfig
index 724380ecec..5dd8b5b21e 100644
--- a/hw/hppa/Kconfig
+++ b/hw/hppa/Kconfig
@@ -4,6 +4,7 @@ config HPPA_B160L
imply E1000_PCI
imply VIRTIO_VGA
select DINO
+ select LASI
select SERIAL
select ISA_BUS
select I8259
diff --git a/hw/hppa/machine.c b/hw/hppa/machine.c
index 9d904b7a60..f3d72b4c35 100644
--- a/hw/hppa/machine.c
+++ b/hw/hppa/machine.c
@@ -22,7 +22,7 @@
#include "hw/nmi.h"
#include "hw/pci/pci.h"
#include "hw/pci-host/dino.h"
-#include "lasi.h"
+#include "hw/misc/lasi.h"
#include "hppa_sys.h"
#include "qemu/units.h"
#include "qapi/error.h"
diff --git a/hw/hppa/meson.build b/hw/hppa/meson.build
index a6f9db455c..bd5a1fb1d2 100644
--- a/hw/hppa/meson.build
+++ b/hw/hppa/meson.build
@@ -1,4 +1,4 @@
hppa_ss = ss.source_set()
-hppa_ss.add(when: 'CONFIG_HPPA_B160L', if_true: files('pci.c', 'machine.c',
'lasi.c'))
+hppa_ss.add(when: 'CONFIG_HPPA_B160L', if_true: files('pci.c', 'machine.c'))
hw_arch += {'hppa': hppa_ss}
diff --git a/hw/hppa/trace-events b/hw/hppa/trace-events
index 871a473771..1a4fbe2fa8 100644
--- a/hw/hppa/trace-events
+++ b/hw/hppa/trace-events
@@ -2,8 +2,3 @@
# pci.c
hppa_pci_iack_write(void) ""
-
-# lasi.c
-lasi_chip_mem_valid(uint64_t addr, uint32_t val) "access to addr 0x%"PRIx64"
is %d"
-lasi_chip_read(uint64_t addr, uint32_t val) "addr 0x%"PRIx64" val 0x%08x"
-lasi_chip_write(uint64_t addr, uint32_t val) "addr 0x%"PRIx64" val 0x%08x"
diff --git a/hw/misc/Kconfig b/hw/misc/Kconfig
index 507058d8bf..cbabe9f78c 100644
--- a/hw/misc/Kconfig
+++ b/hw/misc/Kconfig
@@ -171,4 +171,7 @@ config SIFIVE_U_PRCI
config VIRT_CTRL
bool
+config LASI
+ bool
+
source macio/Kconfig
diff --git a/hw/hppa/lasi.c b/hw/misc/lasi.c
similarity index 99%
rename from hw/hppa/lasi.c
rename to hw/misc/lasi.c
index 5ef36f3f58..23a7634a8c 100644
--- a/hw/hppa/lasi.c
+++ b/hw/misc/lasi.c
@@ -17,10 +17,9 @@
#include "hw/irq.h"
#include "sysemu/sysemu.h"
#include "sysemu/runstate.h"
-#include "hppa_sys.h"
#include "migration/vmstate.h"
#include "qom/object.h"
-#include "lasi.h"
+#include "hw/misc/lasi.h"
static bool lasi_chip_mem_valid(void *opaque, hwaddr addr,
diff --git a/hw/misc/meson.build b/hw/misc/meson.build
index 2ff05c7afa..132b7b7344 100644
--- a/hw/misc/meson.build
+++ b/hw/misc/meson.build
@@ -134,3 +134,6 @@ specific_ss.add(when: 'CONFIG_MIPS_CPS', if_true:
files('mips_cmgcr.c', 'mips_cp
specific_ss.add(when: 'CONFIG_MIPS_ITU', if_true: files('mips_itu.c'))
specific_ss.add(when: 'CONFIG_SBSA_REF', if_true: files('sbsa_ec.c'))
+
+# HPPA devices
+softmmu_ss.add(when: 'CONFIG_LASI', if_true: files('lasi.c'))
diff --git a/hw/misc/trace-events b/hw/misc/trace-events
index 4e0c7973a4..c5e37b0154 100644
--- a/hw/misc/trace-events
+++ b/hw/misc/trace-events
@@ -263,3 +263,8 @@ virt_ctrl_write(void *dev, unsigned int addr, unsigned int
size, uint64_t value)
virt_ctrl_reset(void *dev) "ctrl: %p"
virt_ctrl_realize(void *dev) "ctrl: %p"
virt_ctrl_instance_init(void *dev) "ctrl: %p"
+
+# lasi.c
+lasi_chip_mem_valid(uint64_t addr, uint32_t val) "access to addr 0x%"PRIx64"
is %d"
+lasi_chip_read(uint64_t addr, uint32_t val) "addr 0x%"PRIx64" val 0x%08x"
+lasi_chip_write(uint64_t addr, uint32_t val) "addr 0x%"PRIx64" val 0x%08x"
diff --git a/hw/hppa/lasi.h b/include/hw/misc/lasi.h
similarity index 100%
rename from hw/hppa/lasi.h
rename to include/hw/misc/lasi.h
--
2.20.1
- [PULL 29/53] lasi: define IRQ inputs as qdev GPIOs, (continued)
- [PULL 29/53] lasi: define IRQ inputs as qdev GPIOs, Mark Cave-Ayland, 2022/05/08
- [PULL 28/53] lasi: replace lasi_get_irq() with defined constants, Mark Cave-Ayland, 2022/05/08
- [PULL 31/53] lasi: fix serial port initialisation, Mark Cave-Ayland, 2022/05/08
- [PULL 30/53] lasi: use qdev GPIOs to wire up IRQs in lasi_initfn(), Mark Cave-Ayland, 2022/05/08
- [PULL 32/53] lasi: update lasi_initfn() to return LASIState, Mark Cave-Ayland, 2022/05/08
- [PULL 37/53] lasi: remove address space parameter from lasi_initfn(), Mark Cave-Ayland, 2022/05/08
- [PULL 33/53] lasi: move LAN initialisation to machine.c, Mark Cave-Ayland, 2022/05/08
- [PULL 36/53] lasi: move PS2 initialisation to machine.c, Mark Cave-Ayland, 2022/05/08
- [PULL 34/53] lasi: move parallel port initialisation to machine.c, Mark Cave-Ayland, 2022/05/08
- [PULL 41/53] hppa: move device headers from hppa_sys.h into individual .c files, Mark Cave-Ayland, 2022/05/08
- [PULL 42/53] lasi: move from hw/hppa to hw/misc,
Mark Cave-Ayland <=
- [PULL 38/53] lasi: move lasi_initfn() to machine.c, Mark Cave-Ayland, 2022/05/08
- [PULL 35/53] lasi: move second serial port initialisation to machine.c, Mark Cave-Ayland, 2022/05/08
- [PULL 39/53] lasi: use constants for device register offsets, Mark Cave-Ayland, 2022/05/08
- [PULL 40/53] lasi: use numerical constant for iar reset value, Mark Cave-Ayland, 2022/05/08
- [PULL 43/53] hppa: move hppa_pci_ignore_ops from pci.c to machine.c, Mark Cave-Ayland, 2022/05/08
- [PULL 44/53] hppa: remove hw/hppa/pci.c, Mark Cave-Ayland, 2022/05/08
- [PULL 45/53] hppa: remove unused trace-events from from hw/hppa, Mark Cave-Ayland, 2022/05/08
- [PULL 46/53] hppa: move enable_lan() define from hppa_sys.h to machine.c, Mark Cave-Ayland, 2022/05/08
- [PULL 47/53] hppa: remove the empty hppa_sys.h file, Mark Cave-Ayland, 2022/05/08
- [PULL 48/53] hppa: use MACHINE QOM macros for defining the hppa machine, Mark Cave-Ayland, 2022/05/08