summaryrefslogtreecommitdiff
path: root/hw
diff options
context:
space:
mode:
Diffstat (limited to 'hw')
-rw-r--r--hw/slavio_timer.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/slavio_timer.c b/hw/slavio_timer.c
index 1b17a3d372..14fd40262b 100644
--- a/hw/slavio_timer.c
+++ b/hw/slavio_timer.c
@@ -125,7 +125,7 @@ static uint32_t slavio_timer_mem_readl(void *opaque, target_phys_addr_t addr)
// of counter (user mode)
slavio_timer_get_out(s);
if (slavio_timer_is_user(s)) // read user timer LSW
- ret = s->count & 0xffffffe00;
+ ret = s->count & 0xfffffe00;
else // read limit
ret = (s->count & 0x7ffffe00) | s->reached;
break;