From 666ee3d06824400eff61c30d7722ea60d673fe8c Mon Sep 17 00:00:00 2001 From: Gavin Shan Date: Thu, 2 Oct 2014 16:30:12 +1000 Subject: PHB3: Support multiple MM32 segments for error injection When doing error injection to 32-bits MMIO range, fixed length 8MB is used. That's incorrect as one PE might span multile segments. Also the 32-bits MMIO segment size isn't 8MB necessarily. The patch fixes the issue to cover all (contiguous) 32-bits MMIO segments assigned to the specified PE. Also, it fixes the 48 bits of 50 bits AIB address, instead of all bits used for comparison. BZ: 115222 Signed-off-by: Gavin Shan Signed-off-by: Benjamin Herrenschmidt --- include/phb3-regs.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'include/phb3-regs.h') diff --git a/include/phb3-regs.h b/include/phb3-regs.h index 2611b5f9..686a1136 100644 --- a/include/phb3-regs.h +++ b/include/phb3-regs.h @@ -144,11 +144,13 @@ #define PHB_PAPR_ERR_INJ_CTL_WR PPC_BIT(5) #define PHB_PAPR_ERR_INJ_CTL_FREEZE PPC_BIT(6) #define PHB_PAPR_ERR_INJ_ADDR 0x2b8 +#define PHB_PAPR_ERR_INJ_ADDR_MMIO_MASK PPC_BITMASK(16,63) +#define PHB_PAPR_ERR_INJ_ADDR_MMIO_LSH PPC_BITLSHIFT(63) #define PHB_PAPR_ERR_INJ_MASK 0x2c0 #define PHB_PAPR_ERR_INJ_MASK_CFG_MASK PPC_BITMASK(4,11) #define PHB_PAPR_ERR_INJ_MASK_CFG_LSH PPC_BITLSHIFT(11) -#define PHB_PAPR_ERR_INJ_MASK_MMIO_MASK PPC_BITMASK(14,40) /* 8M aligned */ -#define PHB_PAPR_ERR_INJ_MASK_MMIO_LSH PPC_BITLSHIFT(40) +#define PHB_PAPR_ERR_INJ_MASK_MMIO_MASK PPC_BITMASK(16,63) +#define PHB_PAPR_ERR_INJ_MASK_MMIO_LSH PPC_BITLSHIFT(63) #define PHB_ETU_ERR_SUMMARY 0x2c8 /* UTL registers */ -- cgit v1.2.1