Skip to contentSkip to conversation

iommu/omap: Use the correct type for SLAB_HWCACHE_ALIGN

PATCH Applied Suman Anna via iommu 2 participants 2 messages Aug 16, 2019 – Aug 19, 2019 IOMMU

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 iommu/omap: Use the correct type for SLAB_HWCACHE_ALIGN

The macro SLAB_HWCACHE_ALIGN is of type slab_flags_t, but is currently assigned in the OMAP IOMMU driver using a unsigned long variable. This generates a sparse warning around the type check. Fix this by defining the variable flags using the correct type.

---
 drivers/iommu/omap-iommu.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/iommu/omap-iommu.c +1 -1
index 99a9ff3e7f71..8645e9b175a3 100644
@@ -1818,7 +1818,7 @@ static const struct iommu_ops omap_iommu_ops = {
 static int __init omap_iommu_init(void)
 {
 	struct kmem_cache *p;
-	const unsigned long flags = SLAB_HWCACHE_ALIGN;
+	const slab_flags_t flags = SLAB_HWCACHE_ALIGN;
 	size_t align = 1 << 10; /* L2 pagetable alignement */
 	struct device_node *np;
 	int ret;
Signature · 1 line
2.22.0
maintainer Applied
#1 lore raw
Quoted 2 lines · Suman Anna
 drivers/iommu/omap-iommu.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Applied, thanks.