aboutsummaryrefslogtreecommitdiff
path: root/hw/etraxfs_pic.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/etraxfs_pic.c')
-rw-r--r--hw/etraxfs_pic.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/hw/etraxfs_pic.c b/hw/etraxfs_pic.c
index a656a265d1..7022c99534 100644
--- a/hw/etraxfs_pic.c
+++ b/hw/etraxfs_pic.c
@@ -154,6 +154,7 @@ static void etraxfs_pic_handler(void *opaque, int irq, int level)
__func__, irq, level,
fs->rw_mask, fs->r_vect, fs->r_masked_vect));
+ irq -= 1;
fs->r_vect &= ~(1 << irq);
fs->r_vect |= (!!level << irq);
fs->r_masked_vect = fs->r_vect & fs->rw_mask;