From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:58261) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Yn6h1-0007Us-CZ for qemu-devel@nongnu.org; Tue, 28 Apr 2015 10:41:04 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Yn6gw-00011I-L5 for qemu-devel@nongnu.org; Tue, 28 Apr 2015 10:40:59 -0400 Received: from mx1.redhat.com ([209.132.183.28]:35919) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Yn6gw-0000zW-CR for qemu-devel@nongnu.org; Tue, 28 Apr 2015 10:40:54 -0400 Received: from int-mx14.intmail.prod.int.phx2.redhat.com (int-mx14.intmail.prod.int.phx2.redhat.com [10.5.11.27]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id t3SEerfe023855 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL) for ; Tue, 28 Apr 2015 10:40:53 -0400 Received: from donizetti.redhat.com (ovpn-112-80.ams2.redhat.com [10.36.112.80]) by int-mx14.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id t3SEeTdE013668 for ; Tue, 28 Apr 2015 10:40:52 -0400 From: Paolo Bonzini Date: Tue, 28 Apr 2015 16:40:18 +0200 Message-Id: <1430232029-9457-12-git-send-email-pbonzini@redhat.com> In-Reply-To: <1430232029-9457-1-git-send-email-pbonzini@redhat.com> References: <1430232029-9457-1-git-send-email-pbonzini@redhat.com> Subject: [Qemu-devel] [PULL 11/22] gus: clean up MemoryRegionPortio List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Remove 16-bit reads/writes, since ioport.c is able to synthesize them. Remove the two MIDI registers (0x300 and 0x301) from gus_portio_list1, and add the second MIDI register (0x301) to gus_portio_list2. Tested with Second Reality. Signed-off-by: Paolo Bonzini --- hw/audio/gus.c | 20 +------------------- 1 file changed, 1 insertion(+), 19 deletions(-) diff --git a/hw/audio/gus.c b/hw/audio/gus.c index 4a43ce7..86223a9 100644 --- a/hw/audio/gus.c +++ b/hw/audio/gus.c @@ -71,13 +71,6 @@ IO_READ_PROTO (gus_readb) return gus_read (&s->emu, nport, 1); } -IO_READ_PROTO (gus_readw) -{ - GUSState *s = opaque; - - return gus_read (&s->emu, nport, 2); -} - IO_WRITE_PROTO (gus_writeb) { GUSState *s = opaque; @@ -85,13 +78,6 @@ IO_WRITE_PROTO (gus_writeb) gus_write (&s->emu, nport, 1, val); } -IO_WRITE_PROTO (gus_writew) -{ - GUSState *s = opaque; - - gus_write (&s->emu, nport, 2, val); -} - static int write_audio (GUSState *s, int samples) { int net = 0; @@ -236,17 +222,13 @@ static const VMStateDescription vmstate_gus = { static const MemoryRegionPortio gus_portio_list1[] = { {0x000, 1, 1, .write = gus_writeb }, - {0x000, 1, 2, .write = gus_writew }, {0x006, 10, 1, .read = gus_readb, .write = gus_writeb }, - {0x006, 10, 2, .read = gus_readw, .write = gus_writew }, {0x100, 8, 1, .read = gus_readb, .write = gus_writeb }, - {0x100, 8, 2, .read = gus_readw, .write = gus_writew }, PORTIO_END_OF_LIST (), }; static const MemoryRegionPortio gus_portio_list2[] = { - {0, 1, 1, .read = gus_readb }, - {0, 1, 2, .read = gus_readw }, + {0, 2, 1, .read = gus_readb }, PORTIO_END_OF_LIST (), }; -- 2.3.5