[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v3 10/33] next-cube: map ESCC registers as a subregion of the nex
From: |
Mark Cave-Ayland |
Subject: |
[PATCH v3 10/33] next-cube: map ESCC registers as a subregion of the next.scr memory region |
Date: |
Sun, 22 Dec 2024 12:59:49 +0000 |
Since the ESCC device exists within the memory range of the next.scr memory
region, map
the ESCC device registers as a subregion of the next.scr memory region instead
of
directly to the system address space.
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Reviewed-by: Thomas Huth <huth@tuxfamily.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
---
hw/m68k/next-cube.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/hw/m68k/next-cube.c b/hw/m68k/next-cube.c
index 9c0ddf91f8..4b175cd9ab 100644
--- a/hw/m68k/next-cube.c
+++ b/hw/m68k/next-cube.c
@@ -980,6 +980,7 @@ static const MemoryRegionOps next_floppy_ops = {
static void next_escc_init(DeviceState *pcdev)
{
+ NeXTPC *next_pc = NEXT_PC(pcdev);
DeviceState *dev;
SysBusDevice *s;
@@ -997,7 +998,9 @@ static void next_escc_init(DeviceState *pcdev)
sysbus_realize_and_unref(s, &error_fatal);
sysbus_connect_irq(s, 0, qdev_get_gpio_in(pcdev, NEXT_SCC_I));
sysbus_connect_irq(s, 1, qdev_get_gpio_in(pcdev, NEXT_SCC_DMA_I));
- sysbus_mmio_map(s, 0, 0x2118000);
+
+ memory_region_add_subregion(&next_pc->scrmem, 0x18000,
+ sysbus_mmio_get_region(s, 0));
}
static void next_pc_reset(DeviceState *dev)
--
2.39.5
- [PATCH v3 08/33] next-cube: move SCSI 4020/4021 logic from next-pc device to next-scsi device, (continued)
- [PATCH v3 08/33] next-cube: move SCSI 4020/4021 logic from next-pc device to next-scsi device, Mark Cave-Ayland, 2024/12/22
- [PATCH v3 12/33] next-cube: move timer MMIO to separate memory region on next-pc device, Mark Cave-Ayland, 2024/12/22
- [PATCH v3 15/33] next-cube: remove unused next.scr memory region, Mark Cave-Ayland, 2024/12/22
- [PATCH v3 17/33] next-cube: convert next-pc device to use Resettable interface, Mark Cave-Ayland, 2024/12/22
- [PATCH v3 20/33] next-cube: separate rtc read and write shift logic, Mark Cave-Ayland, 2024/12/22
- [PATCH v3 22/33] next-cube: use named gpio to set RTC data bit in scr2, Mark Cave-Ayland, 2024/12/22
- [PATCH v3 29/33] next-cube: add rtc-cmd-reset named gpio to reset the rtc state machine, Mark Cave-Ayland, 2024/12/22
- [PATCH v3 32/33] next-cube: rename old_scr2 and scr2_2 in next_scr2_rtc_update(), Mark Cave-Ayland, 2024/12/22
- [PATCH v3 19/33] next-cube: use qemu_irq to drive int_status in next_scr2_rtc_update(), Mark Cave-Ayland, 2024/12/22
- [PATCH v3 30/33] next-cube: add rtc-power-out named gpio to trigger the NEXT_PWR_I interrupt, Mark Cave-Ayland, 2024/12/22
- [PATCH v3 10/33] next-cube: map ESCC registers as a subregion of the next.scr memory region,
Mark Cave-Ayland <=
- [PATCH v3 09/33] next-cube: move floppy disk MMIO to separate memory region in next-pc, Mark Cave-Ayland, 2024/12/22
- [PATCH v3 16/33] next-cube: rearrange NeXTState declarations to improve readability, Mark Cave-Ayland, 2024/12/22
- [PATCH v3 23/33] next-cube: use named gpio to read RTC data bit in scr2, Mark Cave-Ayland, 2024/12/22
- [PATCH v3 24/33] next-cube: don't use rtc phase value of -1, Mark Cave-Ayland, 2024/12/22
- [PATCH v3 27/33] next-cube: move rtc-data-in gpio from next-pc to next-rtc device, Mark Cave-Ayland, 2024/12/22
- [PATCH v3 28/33] next-cube: use named gpio output for next-rtc data, Mark Cave-Ayland, 2024/12/22
- [PATCH v3 31/33] next-cube: move next_rtc_cmd_is_write() and next_rtc_data_in_irq() functions, Mark Cave-Ayland, 2024/12/22
- [PATCH v3 25/33] next-cube: QOMify NeXTRTC, Mark Cave-Ayland, 2024/12/22
- [PATCH v3 33/33] next-cube: add my copyright to the top of the file, Mark Cave-Ayland, 2024/12/22
- [PATCH v3 07/33] next-cube: move SCSI CSRs from next-pc to the next-scsi device, Mark Cave-Ayland, 2024/12/22