Skip to content

Commit c2372aa

Browse files
sumanannajoergroedel
authored andcommitted
iommu/omap: Remove bogus version check in context save/restore
The omap2_iommu_save_ctx() and omap2_iommu_restore_ctx() performs a sanity version check against a fixed value that is correct only for OMAP2/OMAP3 IOMMUs. This fixed check does not scale for all OMAP2+ IOMMUs and is not absolutely required, so it has been removed. Signed-off-by: Suman Anna <s-anna@ti.com> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Joerg Roedel <jroedel@suse.de>
1 parent 3acb04c commit c2372aa

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

drivers/iommu/omap-iommu2.c

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,6 @@
2626
/*
2727
* omap2 architecture specific register bit definitions
2828
*/
29-
#define IOMMU_ARCH_VERSION 0x00000011
30-
3129
/* IRQSTATUS & IRQENABLE */
3230
#define MMU_IRQ_MULTIHITFAULT (1 << 4)
3331
#define MMU_IRQ_TABLEWALKFAULT (1 << 3)
@@ -268,8 +266,6 @@ static void omap2_iommu_save_ctx(struct omap_iommu *obj)
268266
p[i] = iommu_read_reg(obj, i * sizeof(u32));
269267
dev_dbg(obj->dev, "%s\t[%02d] %08x\n", __func__, i, p[i]);
270268
}
271-
272-
BUG_ON(p[0] != IOMMU_ARCH_VERSION);
273269
}
274270

275271
static void omap2_iommu_restore_ctx(struct omap_iommu *obj)
@@ -281,8 +277,6 @@ static void omap2_iommu_restore_ctx(struct omap_iommu *obj)
281277
iommu_write_reg(obj, p[i], i * sizeof(u32));
282278
dev_dbg(obj->dev, "%s\t[%02d] %08x\n", __func__, i, p[i]);
283279
}
284-
285-
BUG_ON(p[0] != IOMMU_ARCH_VERSION);
286280
}
287281

288282
static void omap2_cr_to_e(struct cr_regs *cr, struct iotlb_entry *e)

0 commit comments

Comments
 (0)