From: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
To: BALATON Zoltan <balaton@eik.bme.hu>,
qemu-devel@nongnu.org, qemu-ppc@nongnu.org
Subject: Re: [PATCH v2 09/13] hw/ppc/mac.h: Move macio specific parts out from shared header
Date: Thu, 29 Sep 2022 08:43:26 +0100 [thread overview]
Message-ID: <2a99a2b9-9b36-7867-cf21-a6dadcd96d70@ilande.co.uk> (raw)
In-Reply-To: <d9cecc9724c75f723572d67a0fd33adec3f44228.1664108862.git.balaton@eik.bme.hu>
On 25/09/2022 13:38, BALATON Zoltan wrote:
> Move the parts specific to and only used by macio out from the shared
> mac.h into macio.c where they better belong.
>
> Signed-off-by: BALATON Zoltan <balaton@eik.bme.hu>
> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
> ---
> hw/misc/macio/macio.c | 5 +++--
> hw/ppc/mac.h | 23 -----------------------
> include/hw/misc/macio/macio.h | 21 +++++++++++++++++++++
> 3 files changed, 24 insertions(+), 25 deletions(-)
>
> diff --git a/hw/misc/macio/macio.c b/hw/misc/macio/macio.c
> index c1fad43f6c..f9f0758b03 100644
> --- a/hw/misc/macio/macio.c
> +++ b/hw/misc/macio/macio.c
> @@ -37,8 +37,9 @@
> #include "hw/intc/heathrow_pic.h"
> #include "trace.h"
>
> -/* Note: this code is strongly inspirated from the corresponding code
> - * in PearPC */
> +#define ESCC_CLOCK 3686400
> +
> +/* Note: this code is strongly inspired by the corresponding code in PearPC */
>
> /*
> * The mac-io has two interfaces to the ESCC. One is called "escc-legacy",
> diff --git a/hw/ppc/mac.h b/hw/ppc/mac.h
> index e97087c7e7..55cb02c990 100644
> --- a/hw/ppc/mac.h
> +++ b/hw/ppc/mac.h
> @@ -35,29 +35,6 @@
> #define KERNEL_LOAD_ADDR 0x01000000
> #define KERNEL_GAP 0x00100000
>
> -#define ESCC_CLOCK 3686400
> -
> -/* Old World IRQs */
> -#define OLDWORLD_CUDA_IRQ 0x12
> -#define OLDWORLD_ESCCB_IRQ 0x10
> -#define OLDWORLD_ESCCA_IRQ 0xf
> -#define OLDWORLD_IDE0_IRQ 0xd
> -#define OLDWORLD_IDE0_DMA_IRQ 0x2
> -#define OLDWORLD_IDE1_IRQ 0xe
> -#define OLDWORLD_IDE1_DMA_IRQ 0x3
> -
> -/* New World IRQs */
> -#define NEWWORLD_CUDA_IRQ 0x19
> -#define NEWWORLD_PMU_IRQ 0x19
> -#define NEWWORLD_ESCCB_IRQ 0x24
> -#define NEWWORLD_ESCCA_IRQ 0x25
> -#define NEWWORLD_IDE0_IRQ 0xd
> -#define NEWWORLD_IDE0_DMA_IRQ 0x2
> -#define NEWWORLD_IDE1_IRQ 0xe
> -#define NEWWORLD_IDE1_DMA_IRQ 0x3
> -#define NEWWORLD_EXTING_GPIO1 0x2f
> -#define NEWWORLD_EXTING_GPIO9 0x37
> -
> /* Grackle PCI */
> #define TYPE_GRACKLE_PCI_HOST_BRIDGE "grackle-pcihost"
>
> diff --git a/include/hw/misc/macio/macio.h b/include/hw/misc/macio/macio.h
> index 6c05f3bfd2..26cf15b1ce 100644
> --- a/include/hw/misc/macio/macio.h
> +++ b/include/hw/misc/macio/macio.h
> @@ -38,6 +38,27 @@
> #include "hw/ppc/openpic.h"
> #include "qom/object.h"
>
> +/* Old World IRQs */
> +#define OLDWORLD_CUDA_IRQ 0x12
> +#define OLDWORLD_ESCCB_IRQ 0x10
> +#define OLDWORLD_ESCCA_IRQ 0xf
> +#define OLDWORLD_IDE0_IRQ 0xd
> +#define OLDWORLD_IDE0_DMA_IRQ 0x2
> +#define OLDWORLD_IDE1_IRQ 0xe
> +#define OLDWORLD_IDE1_DMA_IRQ 0x3
> +
> +/* New World IRQs */
> +#define NEWWORLD_CUDA_IRQ 0x19
> +#define NEWWORLD_PMU_IRQ 0x19
> +#define NEWWORLD_ESCCB_IRQ 0x24
> +#define NEWWORLD_ESCCA_IRQ 0x25
> +#define NEWWORLD_IDE0_IRQ 0xd
> +#define NEWWORLD_IDE0_DMA_IRQ 0x2
> +#define NEWWORLD_IDE1_IRQ 0xe
> +#define NEWWORLD_IDE1_DMA_IRQ 0x3
> +#define NEWWORLD_EXTING_GPIO1 0x2f
> +#define NEWWORLD_EXTING_GPIO9 0x37
> +
> /* MacIO virtual bus */
> #define TYPE_MACIO_BUS "macio-bus"
> OBJECT_DECLARE_SIMPLE_TYPE(MacIOBusState, MACIO_BUS)
At some point I'd like to review whether or not this wiring should be done at the
board level, however that's orthogonal to this series so:
Reviewed-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
ATB,
Mark.
next prev parent reply other threads:[~2022-09-29 7:54 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-09-25 12:38 [PATCH v2 00/13] Misc ppc/mac machines clean up BALATON Zoltan
2022-09-25 12:38 ` [PATCH v2 01/13] mac_newworld: Drop some variables BALATON Zoltan
2022-09-25 12:38 ` [PATCH v2 02/13] mac_oldworld: Drop some more variables BALATON Zoltan
2022-09-25 12:38 ` [PATCH v2 03/13] mac_{old|new}world: Set tbfreq at declaration BALATON Zoltan
2022-09-29 7:09 ` Mark Cave-Ayland
2022-09-25 12:38 ` [PATCH v2 04/13] mac_{old|new}world: Avoid else branch by setting default value BALATON Zoltan
2022-09-25 12:38 ` [PATCH v2 05/13] mac_oldworld: Do not open code sysbus_mmio_map() BALATON Zoltan
2022-09-29 7:28 ` Mark Cave-Ayland
2022-09-29 11:32 ` BALATON Zoltan
2022-10-03 7:54 ` Mark Cave-Ayland
2022-10-03 20:18 ` BALATON Zoltan
2022-09-25 12:38 ` [PATCH v2 06/13] mac_newworld: Simplify creation of Uninorth devices BALATON Zoltan
2022-09-29 7:39 ` Mark Cave-Ayland
2022-10-03 14:05 ` Philippe Mathieu-Daudé via
2022-10-04 6:39 ` Markus Armbruster
2022-10-04 8:00 ` Daniel P. Berrangé
2022-09-25 12:38 ` [PATCH v2 07/13] mac_{old|new}world: Reduce number of QOM casts BALATON Zoltan
2022-09-25 12:38 ` [PATCH v2 08/13] hw/ppc/mac.h: Move newworld specific parts out from shared header BALATON Zoltan
2022-09-25 12:38 ` [PATCH v2 09/13] hw/ppc/mac.h: Move macio " BALATON Zoltan
2022-09-29 7:43 ` Mark Cave-Ayland [this message]
2022-09-25 12:38 ` [PATCH v2 10/13] hw/ppc/mac.h: Move grackle-pcihost declaration " BALATON Zoltan
2022-09-29 7:44 ` Mark Cave-Ayland
2022-09-29 11:42 ` BALATON Zoltan
2022-10-03 7:57 ` Mark Cave-Ayland
2022-09-25 12:38 ` [PATCH v2 11/13] hw/ppc/mac.h: Move PROM and KERNEL defines to board code BALATON Zoltan
2022-09-25 12:38 ` [PATCH v2 12/13] hw/ppc/mac.h: Rename to include/hw/nvram/mac_nvram.h BALATON Zoltan
2022-09-25 12:38 ` [PATCH v2 13/13] mac_nvram: Use NVRAM_SIZE constant BALATON Zoltan
2022-09-29 7:45 ` Mark Cave-Ayland
2022-09-26 21:40 ` [PATCH v2 00/13] Misc ppc/mac machines clean up Daniel Henrique Barboza
2022-10-03 8:11 ` Mark Cave-Ayland
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=2a99a2b9-9b36-7867-cf21-a6dadcd96d70@ilande.co.uk \
--to=mark.cave-ayland@ilande.co.uk \
--cc=balaton@eik.bme.hu \
--cc=qemu-devel@nongnu.org \
--cc=qemu-ppc@nongnu.org \
/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).