summaryrefslogtreecommitdiff
path: root/hw
diff options
context:
space:
mode:
authorStefan Weil <weil@mail.berlios.de>2010-03-02 22:37:41 +0100
committerMichael S. Tsirkin <mst@redhat.com>2010-03-03 13:33:46 +0200
commitcdb90cc43c32e3767cc7bdc950fb0da7fb1c89e9 (patch)
treeb436b498867472cb6d3385106db7b1ece90408d0 /hw
parent5a14d441fc23343aeb90cd8695f66e175f96412e (diff)
downloadqemu-cdb90cc43c32e3767cc7bdc950fb0da7fb1c89e9.tar.gz
qemu-cdb90cc43c32e3767cc7bdc950fb0da7fb1c89e9.tar.bz2
qemu-cdb90cc43c32e3767cc7bdc950fb0da7fb1c89e9.zip
eepro100: Fix compiler errors from debug messages
When debug output was enabled (by defining DEBUG_EEPRO100), some debug messages resulted in a compiler error. This is fixed here. Signed-off-by: Stefan Weil <weil@mail.berlios.de> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'hw')
-rw-r--r--hw/eepro100.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/hw/eepro100.c b/hw/eepro100.c
index b33dbb85c8..6580ca8bff 100644
--- a/hw/eepro100.c
+++ b/hw/eepro100.c
@@ -56,7 +56,9 @@
#define KiB 1024
/* Debug EEPRO100 card. */
-//~ #define DEBUG_EEPRO100
+#if 0
+# define DEBUG_EEPRO100
+#endif
#ifdef DEBUG_EEPRO100
#define logout(fmt, ...) fprintf(stderr, "EE100\t%-24s" fmt, __func__, ## __VA_ARGS__)
@@ -874,9 +876,8 @@ static void action_command(EEPRO100State *s)
cpu_physical_memory_read(s->cb_address, (uint8_t *)&s->tx, sizeof(s->tx));
uint16_t status = le16_to_cpu(s->tx.status);
uint16_t command = le16_to_cpu(s->tx.command);
- logout
- ("val=0x%02x (cu start), status=0x%04x, command=0x%04x, link=0x%08x\n",
- val, status, command, s->tx.link);
+ logout("val=(cu start), status=0x%04x, command=0x%04x, link=0x%08x\n",
+ status, command, s->tx.link);
bool bit_el = ((command & 0x8000) != 0);
bool bit_s = ((command & 0x4000) != 0);
bool bit_i = ((command & 0x2000) != 0);
@@ -891,7 +892,7 @@ static void action_command(EEPRO100State *s)
break;
case CmdIASetup:
cpu_physical_memory_read(s->cb_address + 8, &s->conf.macaddr.a[0], 6);
- TRACE(OTHER, logout("macaddr: %s\n", nic_dump(&s->macaddr[0], 6)));
+ TRACE(OTHER, logout("macaddr: %s\n", nic_dump(&s->conf.macaddr.a[0], 6)));
break;
case CmdConfigure:
cpu_physical_memory_read(s->cb_address + 8, &s->configuration[0],
@@ -1875,7 +1876,7 @@ static int nic_init(PCIDevice *pci_dev, uint32_t device)
pci_mmio_map);
qemu_macaddr_default_if_unset(&s->conf.macaddr);
- logout("macaddr: %s\n", nic_dump(&s->macaddr[0], 6));
+ logout("macaddr: %s\n", nic_dump(&s->conf.macaddr.a[0], 6));
assert(s->region[1] == 0);
nic_reset(s);