aboutsummaryrefslogtreecommitdiff
path: root/hw/timer/hpet.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/timer/hpet.c')
-rw-r--r--hw/timer/hpet.c27
1 files changed, 7 insertions, 20 deletions
diff --git a/hw/timer/hpet.c b/hw/timer/hpet.c
index b5d4072490..05fd86af81 100644
--- a/hw/timer/hpet.c
+++ b/hw/timer/hpet.c
@@ -417,20 +417,6 @@ static void hpet_del_timer(HPETTimer *t)
update_irq(t, 0);
}
-#ifdef HPET_DEBUG
-static uint32_t hpet_ram_readb(void *opaque, hwaddr addr)
-{
- printf("qemu: hpet_read b at %" PRIx64 "\n", addr);
- return 0;
-}
-
-static uint32_t hpet_ram_readw(void *opaque, hwaddr addr)
-{
- printf("qemu: hpet_read w at %" PRIx64 "\n", addr);
- return 0;
-}
-#endif
-
static uint64_t hpet_ram_read(void *opaque, hwaddr addr,
unsigned size)
{
@@ -510,7 +496,8 @@ static void hpet_ram_write(void *opaque, hwaddr addr,
HPETState *s = opaque;
uint64_t old_val, new_val, val, index;
- DPRINTF("qemu: Enter hpet_ram_writel at %" PRIx64 " = %#x\n", addr, value);
+ DPRINTF("qemu: Enter hpet_ram_writel at %" PRIx64 " = 0x%" PRIx64 "\n",
+ addr, value);
index = addr;
old_val = hpet_ram_read(opaque, addr, 4);
new_val = value;
@@ -520,7 +507,7 @@ static void hpet_ram_write(void *opaque, hwaddr addr,
uint8_t timer_id = (addr - 0x100) / 0x20;
HPETTimer *timer = &s->timer[timer_id];
- DPRINTF("qemu: hpet_ram_writel timer_id = %#x\n", timer_id);
+ DPRINTF("qemu: hpet_ram_writel timer_id = 0x%x\n", timer_id);
if (timer_id > s->num_timers) {
DPRINTF("qemu: timer id out of range\n");
return;
@@ -652,8 +639,8 @@ static void hpet_ram_write(void *opaque, hwaddr addr,
}
s->hpet_counter =
(s->hpet_counter & 0xffffffff00000000ULL) | value;
- DPRINTF("qemu: HPET counter written. ctr = %#x -> %" PRIx64 "\n",
- value, s->hpet_counter);
+ DPRINTF("qemu: HPET counter written. ctr = 0x%" PRIx64 " -> "
+ "%" PRIx64 "\n", value, s->hpet_counter);
break;
case HPET_COUNTER + 4:
if (hpet_enabled(s)) {
@@ -661,8 +648,8 @@ static void hpet_ram_write(void *opaque, hwaddr addr,
}
s->hpet_counter =
(s->hpet_counter & 0xffffffffULL) | (((uint64_t)value) << 32);
- DPRINTF("qemu: HPET counter + 4 written. ctr = %#x -> %" PRIx64 "\n",
- value, s->hpet_counter);
+ DPRINTF("qemu: HPET counter + 4 written. ctr = 0x%" PRIx64 " -> "
+ "%" PRIx64 "\n", value, s->hpet_counter);
break;
default:
DPRINTF("qemu: invalid hpet_ram_writel\n");