qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Jan Kiszka <jan.kiszka@siemens.com>
To: qemu-devel <qemu-devel@nongnu.org>
Cc: "Paolo Bonzini" <pbonzini@redhat.com>,
	"Liu Ping Fan" <pingfank@linux.vnet.ibm.com>,
	"Andreas Färber" <afaerber@suse.de>
Subject: [Qemu-devel] [PATCH v2 03/13] wdt_ib700: replace register_ioport*
Date: Fri, 21 Jun 2013 18:41:35 +0200	[thread overview]
Message-ID: <42baf38b4e4d8b720b39df22980c46484ecd4601.1371832904.git.jan.kiszka@siemens.com> (raw)
In-Reply-To: <cover.1371832904.git.jan.kiszka@siemens.com>
In-Reply-To: <cover.1371832904.git.jan.kiszka@siemens.com>

Convert over to memory regions to obsolete register_ioport*.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
---
 hw/watchdog/wdt_ib700.c |   12 ++++++++++--
 1 files changed, 10 insertions(+), 2 deletions(-)

diff --git a/hw/watchdog/wdt_ib700.c b/hw/watchdog/wdt_ib700.c
index d85c894..597a923 100644
--- a/hw/watchdog/wdt_ib700.c
+++ b/hw/watchdog/wdt_ib700.c
@@ -97,15 +97,23 @@ static const VMStateDescription vmstate_ib700 = {
     }
 };
 
+static const MemoryRegionPortio wdt_portio_list[] = {
+    { 0x441, 2, 1, .write = ib700_write_disable_reg, },
+    { 0x443, 2, 1, .write = ib700_write_enable_reg, },
+    PORTIO_END_OF_LIST(),
+};
+
 static void wdt_ib700_realize(DeviceState *dev, Error **errp)
 {
     IB700State *s = IB700(dev);
+    PortioList *port_list = g_new(PortioList, 1);
 
     ib700_debug("watchdog init\n");
 
     s->timer = qemu_new_timer_ns(vm_clock, ib700_timer_expired, s);
-    register_ioport_write(0x441, 2, 1, ib700_write_disable_reg, s);
-    register_ioport_write(0x443, 2, 1, ib700_write_enable_reg, s);
+
+    portio_list_init(port_list, wdt_portio_list, s, "ib700");
+    portio_list_add(port_list, isa_address_space_io(&s->parent_obj), 0);
 }
 
 static void wdt_ib700_reset(DeviceState *dev)
-- 
1.7.3.4

  parent reply	other threads:[~2013-06-21 16:42 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-21 16:41 [Qemu-devel] [PATCH v2 00/13] Refactor portio dispatching Jan Kiszka
2013-06-21 16:41 ` [Qemu-devel] [PATCH v2 01/13] adlib: replace register_ioport* Jan Kiszka
2013-06-21 16:41 ` [Qemu-devel] [PATCH v2 02/13] applesmc: " Jan Kiszka
2013-06-21 16:41 ` Jan Kiszka [this message]
2013-06-21 16:41 ` [Qemu-devel] [PATCH v2 04/13] i82374: " Jan Kiszka
2013-06-21 16:41 ` [Qemu-devel] [PATCH v2 05/13] prep: " Jan Kiszka
2013-06-21 16:41 ` [Qemu-devel] [PATCH v2 06/13] vt82c686: " Jan Kiszka
2013-06-21 16:41 ` [Qemu-devel] [PATCH v2 07/13] Privatize register_ioport_read/write Jan Kiszka
2013-06-21 16:41 ` [Qemu-devel] [PATCH v2 08/13] isa: implement isa_is_ioport_assigned via memory_region_find Jan Kiszka
2013-06-21 16:41 ` [Qemu-devel] [PATCH v2 09/13] vmware-vga: Accept unaligned I/O accesses Jan Kiszka
2013-06-21 16:41 ` [Qemu-devel] [PATCH v2 10/13] xen: Mark fixed platform I/O as unaligned Jan Kiszka
2013-06-21 16:41 ` [Qemu-devel] [PATCH v2 11/13] ioport: Switch dispatching to memory core layer Jan Kiszka
2013-06-21 16:41 ` [Qemu-devel] [PATCH v2 12/13] ioport: Remove unused old dispatching services Jan Kiszka
2013-06-21 16:41 ` [Qemu-devel] [PATCH v2 13/13] ioport: Move IOPortRead/WriteFunc typedefs to memory.h Jan Kiszka
2013-06-21 20:09 ` [Qemu-devel] [PATCH v2 00/13] Refactor portio dispatching Paolo Bonzini

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=42baf38b4e4d8b720b39df22980c46484ecd4601.1371832904.git.jan.kiszka@siemens.com \
    --to=jan.kiszka@siemens.com \
    --cc=afaerber@suse.de \
    --cc=pbonzini@redhat.com \
    --cc=pingfank@linux.vnet.ibm.com \
    --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 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).