Skip to content

Commit ecf6508

Browse files
marcanjoergroedel
authored andcommitted
iommu/apple-dart: Clear stream error indicator bits for T8110 DARTs
These registers exist and at least on the t602x variant the IRQ only clears when theses are cleared. Signed-off-by: Hector Martin <[email protected]> Signed-off-by: Janne Grunau <[email protected]> Reviewed-by: Sven Peter <[email protected]> Reviewed-by: Neal Gompa <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Joerg Roedel <[email protected]>
1 parent 5229bd5 commit ecf6508

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

drivers/iommu/apple-dart.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,8 @@
122122
#define DART_T8110_ERROR_ADDR_LO 0x170
123123
#define DART_T8110_ERROR_ADDR_HI 0x174
124124

125+
#define DART_T8110_ERROR_STREAMS 0x1c0
126+
125127
#define DART_T8110_PROTECT 0x200
126128
#define DART_T8110_UNPROTECT 0x204
127129
#define DART_T8110_PROTECT_LOCK 0x208
@@ -1089,6 +1091,9 @@ static irqreturn_t apple_dart_t8110_irq(int irq, void *dev)
10891091
error, stream_idx, error_code, fault_name, addr);
10901092

10911093
writel(error, dart->regs + DART_T8110_ERROR);
1094+
for (int i = 0; i < BITS_TO_U32(dart->num_streams); i++)
1095+
writel(U32_MAX, dart->regs + DART_T8110_ERROR_STREAMS + 4 * i);
1096+
10921097
return IRQ_HANDLED;
10931098
}
10941099

0 commit comments

Comments
 (0)