[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v2 02/34] next-cube: remove overlap between next.dma and next
From: |
Thomas Huth |
Subject: |
Re: [PATCH v2 02/34] next-cube: remove overlap between next.dma and next.mmio memory regions |
Date: |
Fri, 13 Dec 2024 20:37:22 +0100 |
Hi Mark!
Am Thu, 12 Dec 2024 11:45:48 +0000
schrieb Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>:
> Change the start of the next.mmio memory region so that it follows on directly
> after the next.dma memory region. Increase the address offsets in
> next_mmio_read() and next_mmio_write(), and reduce the size of the next.mmio
> memory region accordingly.
>
> Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
> Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
> ---
> hw/m68k/next-cube.c | 28 ++++++++++++++--------------
> 1 file changed, 14 insertions(+), 14 deletions(-)
>
> diff --git a/hw/m68k/next-cube.c b/hw/m68k/next-cube.c
> index 0418fbc8aa..550e7f0b0a 100644
> --- a/hw/m68k/next-cube.c
> +++ b/hw/m68k/next-cube.c
> @@ -266,23 +266,23 @@ static uint64_t next_mmio_read(void *opaque, hwaddr
> addr, unsigned size)
> uint64_t val;
>
> switch (addr) {
> - case 0x7000:
> + case 0x2000: /* 0x2005000 */
> /* DPRINTF("Read INT status: %x\n", s->int_status); */
> val = s->int_status;
> break;
>
> - case 0x7800:
> + case 0x2800: /* 0x2007800 */
> DPRINTF("MMIO Read INT mask: %x\n", s->int_mask);
> val = s->int_mask;
> break;
>
> - case 0xc000 ... 0xc003:
> - val = extract32(s->scr1, (4 - (addr - 0xc000) - size) << 3,
> + case 0x7000 ... 0x7003: /* 0x200c000 */
> + val = extract32(s->scr1, (4 - (addr - 0x7000) - size) << 3,
> size << 3);
> break;
>
> - case 0xd000 ... 0xd003:
> - val = extract32(s->scr2, (4 - (addr - 0xd000) - size) << 3,
> + case 0x8000 ... 0x8003: /* 0x200d000 */
> + val = extract32(s->scr2, (4 - (addr - 0x8000) - size) << 3,
> size << 3);
> break;
>
> @@ -301,25 +301,25 @@ static void next_mmio_write(void *opaque, hwaddr addr,
> uint64_t val,
> NeXTPC *s = NEXT_PC(opaque);
>
> switch (addr) {
> - case 0x7000:
> + case 0x2000: /* 0x2005000 */
Comment should be /* 0x2007000 */ instead.
With that fixed:
Reviewed-by: Thomas Huth <huth@tuxfamily.org>
- [PATCH v2 00/34] next-cube: more tidy-ups and improvements, Mark Cave-Ayland, 2024/12/12
- [PATCH v2 01/34] next-cube: remove 0x14020 dummy value from next_mmio_read(), Mark Cave-Ayland, 2024/12/12
- [PATCH v2 03/34] next-cube: create new next.scsi container memory region, Mark Cave-Ayland, 2024/12/12
- [PATCH v2 02/34] next-cube: remove overlap between next.dma and next.mmio memory regions, Mark Cave-Ayland, 2024/12/12
- Re: [PATCH v2 02/34] next-cube: remove overlap between next.dma and next.mmio memory regions,
Thomas Huth <=
- [PATCH v2 04/34] next-cube: move next_scsi_init() to next_pc_realize(), Mark Cave-Ayland, 2024/12/12
- [PATCH v2 05/34] next-cube: introduce next_pc_init() object init function, Mark Cave-Ayland, 2024/12/12
- [PATCH v2 07/34] next-cube: move SCSI CSRs from next-pc to the next-scsi device, Mark Cave-Ayland, 2024/12/12
- [PATCH v2 09/34] next-cube: move floppy disk MMIO to separate memory region in next-pc, Mark Cave-Ayland, 2024/12/12
- [PATCH v2 08/34] next-cube: move SCSI 4020/4021 logic from next-pc device to next-scsi device, Mark Cave-Ayland, 2024/12/12
- [PATCH v2 06/34] next-cube: introduce next-scsi device, Mark Cave-Ayland, 2024/12/12
- [PATCH v2 12/34] next-cube: move timer MMIO to separate memory region on next-pc device, Mark Cave-Ayland, 2024/12/12