dev-arm: Fix Gicv2 distributor group register
authorAdrien Pesle <adrien.pesle@arm.com>
Thu, 11 Oct 2018 14:09:07 +0000 (16:09 +0200)
committerGiacomo Travaglini <giacomo.travaglini@arm.com>
Wed, 17 Oct 2018 14:47:14 +0000 (14:47 +0000)
For each bit in GICD_IGROUPR:
value 0 means corresponding irq is group0
value 1 means corresponding irq is group 1.

Change-Id: I15699d4bc89ff3df0e0bdb41154c0d0989dc2f63
Reviewed-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/13555
Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com>
Maintainer: Andreas Sandberg <andreas.sandberg@arm.com>

src/dev/arm/gic_v2.hh

index c9c1a4715b7fed57ce1622c9db527beeebd58371..4afad89f6cc558ebfc7e61e26a3665cfcf0aa44a 100644 (file)
@@ -336,7 +336,7 @@ class GicV2 : public BaseGic, public BaseGicRegisters
 
     bool isGroup0(ContextID ctx, uint32_t int_num) {
         const uint32_t group_reg = getIntGroup(ctx, intNumToWord(int_num));
-        return bits(group_reg, intNumToBit(int_num));
+        return !bits(group_reg, intNumToBit(int_num));
     }
 
     /**