aboutsummaryrefslogtreecommitdiffstats
path: root/ioport-user.c
diff options
context:
space:
mode:
authorDavid 'Digit' Turner <digit@android.com>2010-05-10 18:44:56 -0700
committerDavid 'Digit' Turner <digit@android.com>2010-05-11 16:30:28 -0700
commit3266b5118e1d9ac13ea87bc24f37b50d22a2b81f (patch)
tree17e0b09fb41548191c041563e0cedb2631cc75af /ioport-user.c
parent9d6baf019d82e303b985fdaa7b3d282076b32586 (diff)
downloadexternal_qemu-3266b5118e1d9ac13ea87bc24f37b50d22a2b81f.zip
external_qemu-3266b5118e1d9ac13ea87bc24f37b50d22a2b81f.tar.gz
external_qemu-3266b5118e1d9ac13ea87bc24f37b50d22a2b81f.tar.bz2
Upstream: Move ioport code to ioport.[hc]
Change-Id: I41aa30fff127338665a6a32fa66dcd43dd3bfe8b
Diffstat (limited to 'ioport-user.c')
-rw-r--r--ioport-user.c60
1 files changed, 60 insertions, 0 deletions
diff --git a/ioport-user.c b/ioport-user.c
new file mode 100644
index 0000000..03fac22
--- /dev/null
+++ b/ioport-user.c
@@ -0,0 +1,60 @@
+/*
+ * qemu user ioport functions
+ *
+ * Copyright (c) 2003-2008 Fabrice Bellard
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, see <http://www.gnu.org/licenses/>.
+ */
+
+#include <stdio.h>
+
+#include "qemu.h"
+#include "qemu-common.h"
+#include "ioport.h"
+
+void cpu_outb(pio_addr_t addr, uint8_t val)
+{
+ fprintf(stderr, "outb: port=0x%04"FMT_pioaddr", data=%02"PRIx8"\n",
+ addr, val);
+}
+
+void cpu_outw(pio_addr_t addr, uint16_t val)
+{
+ fprintf(stderr, "outw: port=0x%04"FMT_pioaddr", data=%04"PRIx16"\n",
+ addr, val);
+}
+
+void cpu_outl(pio_addr_t addr, uint32_t val)
+{
+ fprintf(stderr, "outl: port=0x%04"FMT_pioaddr", data=%08"PRIx32"\n",
+ addr, val);
+}
+
+uint8_t cpu_inb(pio_addr_t addr)
+{
+ fprintf(stderr, "inb: port=0x%04"FMT_pioaddr"\n", addr);
+ return 0;
+}
+
+uint16_t cpu_inw(pio_addr_t addr)
+{
+ fprintf(stderr, "inw: port=0x%04"FMT_pioaddr"\n", addr);
+ return 0;
+}
+
+uint32_t cpu_inl(pio_addr_t addr)
+{
+ fprintf(stderr, "inl: port=0x%04"FMT_pioaddr"\n", addr);
+ return 0;
+}