From f7f868aa082fa08b9bbf34a08cec1d4cc3c2ade5 Mon Sep 17 00:00:00 2001 From: Ian Moffett Date: Sat, 3 Aug 2024 19:39:50 -0400 Subject: soc: pimc: Fix up mask bit Signed-off-by: Ian Moffett --- sv/soc/irq/pimc.sv | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'sv/soc/irq') diff --git a/sv/soc/irq/pimc.sv b/sv/soc/irq/pimc.sv index a41a941..6ad4c43 100644 --- a/sv/soc/irq/pimc.sv +++ b/sv/soc/irq/pimc.sv @@ -35,10 +35,7 @@ module pimc #( parameter IRQ_PIN_COUNT = 16, parameter IRQTAB_ENTSIZE = 32, - parameter IRQTAB_MMIOBASE = 48'h1000, - - /* irqtab indices */ - parameter IRQTAB_MASK = 1 + parameter IRQTAB_MMIOBASE = 48'h1000 ) ( input wire clk, /* 50 MHz */ input logic [IRQ_PIN_COUNT-1:0] irq_in, @@ -97,7 +94,7 @@ module pimc #( end else begin for (i = 0; i < IRQ_PIN_COUNT; i = i + 1) begin /* IRQ should be dropped if masked */ - irqmask <= irqtab[(i * IRQTAB_ENTSIZE) + IRQTAB_MASK][0]; + irqmask <= irqtab[i * IRQTAB_ENTSIZE][8]; accept <= (irqmask == 1'b0 && notify == 1'b1); if (irq_in[i] == 1'b1 && accept == 1'b1) begin lineno <= i[7:0]; -- cgit v1.2.3