All of lore.kernel.org
 help / color / mirror / Atom feed
From: BALATON Zoltan <balaton@eik.bme.hu>
To: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Cc: qemu-devel@nongnu.org, laurent@vivier.eu
Subject: Re: [PATCH v2 20/20] q800: configure nubus available slots for Quadra 800
Date: Wed, 15 Sep 2021 12:50:08 +0200 (CEST)	[thread overview]
Message-ID: <34dbcdd0-c328-b6e5-c6da-dcc22cdb58f0@eik.bme.hu> (raw)
In-Reply-To: <20210915101026.25174-21-mark.cave-ayland@ilande.co.uk>

On Wed, 15 Sep 2021, Mark Cave-Ayland wrote:
> Slot 0x9 is reserved for use by the in-built framebuffer whilst only slots
> 0xc, 0xd and 0xe physically exist on the Quadra 800.
>
> Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
> ---
> hw/m68k/q800.c | 9 +++++++++
> 1 file changed, 9 insertions(+)
>
> diff --git a/hw/m68k/q800.c b/hw/m68k/q800.c
> index fbc45a301f..65c80421c6 100644
> --- a/hw/m68k/q800.c
> +++ b/hw/m68k/q800.c
> @@ -78,6 +78,13 @@
>
> #define MAC_CLOCK  3686418
>
> +/*
> + * Slot 0x9 is reserved for use by the in-built framebuffer whilst only
> + * slots 0xc, 0xd and 0xe physically exist on the Quadra 800
> + */
> +#define Q800_NUBUS_SLOTS_AVAILABLE    ((1UL << 0x9) | (1UL << 0xc) | \
> +                                       (1UL << 0xd) | (1UL << 0xe))

There is a BIT(x) macro for these kind of constants that I find more 
readable as there would be less < signs and perenthesis but I don't insist 
on using it just note for consideration in case you need another respin for 
other reasons. (That macro could also be used to shorten the ~(1UL << nr_bits)
values in other patches.)

Regards.
BALATON Zoltan

> +
> /*
>  * The GLUE (General Logic Unit) is an Apple custom integrated circuit chip
>  * that performs a variety of functions (RAM management, clock generation, ...).
> @@ -392,6 +399,8 @@ static void q800_init(MachineState *machine)
>     /* NuBus */
>
>     dev = qdev_new(TYPE_MAC_NUBUS_BRIDGE);
> +    qdev_prop_set_uint32(dev, "slot-available-mask",
> +                         Q800_NUBUS_SLOTS_AVAILABLE);
>     sysbus_realize_and_unref(SYS_BUS_DEVICE(dev), &error_fatal);
>     sysbus_mmio_map(SYS_BUS_DEVICE(dev), 0, 9 * NUBUS_SUPER_SLOT_SIZE);
>     sysbus_mmio_map(SYS_BUS_DEVICE(dev), 1, NUBUS_SLOT_BASE +
>


  reply	other threads:[~2021-09-15 10:51 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-15 10:10 [PATCH v2 00/20] nubus: bus, device, bridge, IRQ and address space improvements Mark Cave-Ayland
2021-09-15 10:10 ` [PATCH v2 01/20] nubus-device: rename slot_nb variable to slot Mark Cave-Ayland
2021-09-15 10:10 ` [PATCH v2 02/20] nubus-device: expose separate super slot memory region Mark Cave-Ayland
2021-09-15 10:10 ` [PATCH v2 03/20] nubus-device: add device slot parameter Mark Cave-Ayland
2021-09-15 10:10 ` [PATCH v2 04/20] nubus: use bitmap to manage available slots Mark Cave-Ayland
2021-09-15 10:39   ` Philippe Mathieu-Daudé
2021-09-15 11:39     ` Mark Cave-Ayland
2021-09-15 10:10 ` [PATCH v2 05/20] nubus: move slot bitmap checks from NubusDevice realize() to BusClass check_address() Mark Cave-Ayland
2021-09-15 10:10 ` [PATCH v2 06/20] nubus: implement BusClass get_dev_path() Mark Cave-Ayland
2021-09-15 10:10 ` [PATCH v2 07/20] nubus: add trace-events for empty slot accesses Mark Cave-Ayland
2021-09-15 10:42   ` Philippe Mathieu-Daudé
2021-09-15 10:10 ` [PATCH v2 08/20] nubus: generate bus error when attempting to access empty slots Mark Cave-Ayland
2021-09-15 10:10 ` [PATCH v2 09/20] macfb: don't register declaration ROM Mark Cave-Ayland
2021-09-15 10:10 ` [PATCH v2 10/20] nubus-device: remove nubus_register_rom() and nubus_register_format_block() Mark Cave-Ayland
2021-09-15 10:10 ` [PATCH v2 11/20] nubus-device: add romfile property for loading declaration ROMs Mark Cave-Ayland
2021-09-15 10:10 ` [PATCH v2 12/20] nubus: move nubus to its own 32-bit address space Mark Cave-Ayland
2021-09-15 10:10 ` [PATCH v2 13/20] nubus-bridge: introduce separate NubusBridge structure Mark Cave-Ayland
2021-09-15 10:10 ` [PATCH v2 14/20] mac-nubus-bridge: rename MacNubusState to MacNubusBridge Mark Cave-Ayland
2021-09-15 10:10 ` [PATCH v2 15/20] nubus: move NubusBus from mac-nubus-bridge to nubus-bridge Mark Cave-Ayland
2021-09-15 10:10 ` [PATCH v2 16/20] nubus-bridge: embed the NubusBus object directly within nubus-bridge Mark Cave-Ayland
2021-09-15 10:10 ` [PATCH v2 17/20] nubus-bridge: make slot_available_mask a qdev property Mark Cave-Ayland
2021-09-15 10:10 ` [PATCH v2 18/20] nubus: add support for slot IRQs Mark Cave-Ayland
2021-09-15 10:10 ` [PATCH v2 19/20] q800: wire up nubus IRQs Mark Cave-Ayland
2021-09-15 10:10 ` [PATCH v2 20/20] q800: configure nubus available slots for Quadra 800 Mark Cave-Ayland
2021-09-15 10:50   ` BALATON Zoltan [this message]
2021-09-15 11:32     ` Philippe Mathieu-Daudé
2021-09-15 11:41     ` 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=34dbcdd0-c328-b6e5-c6da-dcc22cdb58f0@eik.bme.hu \
    --to=balaton@eik.bme.hu \
    --cc=laurent@vivier.eu \
    --cc=mark.cave-ayland@ilande.co.uk \
    --cc=qemu-devel@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.