All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
To: qemu-devel@nongnu.org, laurent@vivier.eu
Subject: [PATCH 10/12] mac_via: remove explicit viaN prefix from VIA IRQ gpios
Date: Mon, 30 Aug 2021 11:24:45 +0100	[thread overview]
Message-ID: <20210830102447.10806-11-mark.cave-ayland@ilande.co.uk> (raw)
In-Reply-To: <20210830102447.10806-1-mark.cave-ayland@ilande.co.uk>

Now that q800 VIA1 and VIA2 are completely separate devices there is no need to
add a specific device prefix to ensure that the IRQ lines remain separate.

Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
---
 hw/m68k/q800.c    | 10 ++++------
 hw/misc/mac_via.c |  9 +++------
 2 files changed, 7 insertions(+), 12 deletions(-)

diff --git a/hw/m68k/q800.c b/hw/m68k/q800.c
index ec28e69802..5ba87f789c 100644
--- a/hw/m68k/q800.c
+++ b/hw/m68k/q800.c
@@ -377,12 +377,10 @@ static void q800_init(MachineState *machine)
 
     sysbus = SYS_BUS_DEVICE(dev);
     sysbus_realize_and_unref(sysbus, &error_fatal);
-    sysbus_connect_irq(sysbus, 0, qdev_get_gpio_in_named(via2_dev,
-                                                         "via2-irq",
-                                                         VIA2_IRQ_SCSI_BIT));
-    sysbus_connect_irq(sysbus, 1,
-                       qdev_get_gpio_in_named(via2_dev, "via2-irq",
-                                              VIA2_IRQ_SCSI_DATA_BIT));
+    sysbus_connect_irq(sysbus, 0, qdev_get_gpio_in(via2_dev,
+                                                   VIA2_IRQ_SCSI_BIT));
+    sysbus_connect_irq(sysbus, 1, qdev_get_gpio_in(via2_dev,
+                                                   VIA2_IRQ_SCSI_DATA_BIT));
     sysbus_mmio_map(sysbus, 0, ESP_BASE);
     sysbus_mmio_map(sysbus, 1, ESP_PDMA);
 
diff --git a/hw/misc/mac_via.c b/hw/misc/mac_via.c
index 7b9f067e71..f093f7388e 100644
--- a/hw/misc/mac_via.c
+++ b/hw/misc/mac_via.c
@@ -1004,8 +1004,7 @@ static void mos6522_q800_via1_realize(DeviceState *dev, Error **errp)
     v1s->tick_offset = (uint32_t)mktimegm(&tm) + RTC_OFFSET;
 
     adb_register_autopoll_callback(adb_bus, adb_via_poll, v1s);
-    v1s->adb_data_ready = qdev_get_gpio_in_named(dev, "via1-irq",
-                                                 VIA1_IRQ_ADB_READY_BIT);
+    v1s->adb_data_ready = qdev_get_gpio_in(dev, VIA1_IRQ_ADB_READY_BIT);
 
     if (v1s->blk) {
         int64_t len = blk_getlength(v1s->blk);
@@ -1042,8 +1041,7 @@ static void mos6522_q800_via1_init(Object *obj)
     qbus_create_inplace((BusState *)&v1s->adb_bus, sizeof(v1s->adb_bus),
                         TYPE_ADB_BUS, DEVICE(v1s), "adb.0");
 
-    qdev_init_gpio_in_named(DEVICE(obj), via1_irq_request, "via1-irq",
-                            VIA1_IRQ_NB);
+    qdev_init_gpio_in(DEVICE(obj), via1_irq_request, VIA1_IRQ_NB);
 }
 
 static const VMStateDescription vmstate_q800_via1 = {
@@ -1136,8 +1134,7 @@ static void mos6522_q800_via2_init(Object *obj)
                           "via2", VIA_SIZE);
     sysbus_init_mmio(sbd, &v2s->via_mem);
 
-    qdev_init_gpio_in_named(DEVICE(obj), via2_irq_request, "via2-irq",
-                            VIA2_IRQ_NB);
+    qdev_init_gpio_in(DEVICE(obj), via2_irq_request, VIA2_IRQ_NB);
 }
 
 static const VMStateDescription vmstate_q800_via2 = {
-- 
2.20.1



  parent reply	other threads:[~2021-08-30 10:33 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-08-30 10:24 [PATCH 00/12] mac_via: remove MAC_VIA device and prepare for Nubus IRQs Mark Cave-Ayland
2021-08-30 10:24 ` [PATCH 01/12] mac_via: introduce new VMStateDescription for q800 VIA1 and VIA2 Mark Cave-Ayland
2021-09-08  6:44   ` Laurent Vivier
2021-08-30 10:24 ` [PATCH 02/12] mac_via: move last_b variable into q800 VIA1 VMStateDescription Mark Cave-Ayland
2021-09-08  6:44   ` Laurent Vivier
2021-08-30 10:24 ` [PATCH 03/12] mac_via: move PRAM contents and block backend to MOS6522Q800VIA1State Mark Cave-Ayland
2021-09-08  6:46   ` Laurent Vivier
2021-08-30 10:24 ` [PATCH 04/12] mac_via: move PRAM/RTC variables " Mark Cave-Ayland
2021-08-30 22:07   ` Philippe Mathieu-Daudé
2021-09-08  6:47   ` Laurent Vivier
2021-08-30 10:24 ` [PATCH 05/12] mac_via: move ADB " Mark Cave-Ayland
2021-08-30 22:12   ` Philippe Mathieu-Daudé
2021-09-08  6:50   ` Laurent Vivier
2021-08-30 10:24 ` [PATCH 06/12] mac_via: move q800 VIA1 timer variables to q800 VIA1 VMStateDescription Mark Cave-Ayland
2021-09-08  6:50   ` Laurent Vivier
2021-08-30 10:24 ` [PATCH 07/12] mac_via: move VIA1 reset logic from mac_via_reset() to mos6522_q800_via1_reset() Mark Cave-Ayland
2021-08-30 22:04   ` Philippe Mathieu-Daudé
2021-09-08  6:51   ` Laurent Vivier
2021-08-30 10:24 ` [PATCH 08/12] mac_via: move VIA1 realize logic from mac_via_realize() to mos6522_q800_via1_realize() Mark Cave-Ayland
2021-09-08  6:52   ` Laurent Vivier
2021-08-30 10:24 ` [PATCH 09/12] mac_via: remove mac_via device Mark Cave-Ayland
2021-09-08  6:52   ` Laurent Vivier
2021-08-30 10:24 ` Mark Cave-Ayland [this message]
2021-08-30 22:03   ` [PATCH 10/12] mac_via: remove explicit viaN prefix from VIA IRQ gpios Philippe Mathieu-Daudé
2021-09-08  6:53   ` Laurent Vivier
2021-08-30 10:24 ` [PATCH 11/12] mac_via: rename VIA2_IRQ_SLOT_BIT to VIA2_IRQ_NUBUS_BIT Mark Cave-Ayland
2021-09-08  6:54   ` Laurent Vivier
2021-08-30 10:24 ` [PATCH 12/12] mac_via: add qdev gpios for nubus slot interrupts to VIA2 Mark Cave-Ayland
2021-09-08  6:54   ` Laurent Vivier

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=20210830102447.10806-11-mark.cave-ayland@ilande.co.uk \
    --to=mark.cave-ayland@ilande.co.uk \
    --cc=laurent@vivier.eu \
    --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.