Skip to content

Commit 79074f6

Browse files
rikardfalkebornjoergroedel
authored andcommitted
iommu/sun50i: Constify sun50i_iommu_ops
The struct sun50i_iommu_ops is not modified and can be made const to allow the compiler to put it in read-only memory. Before: text data bss dec hex filename 14358 2501 64 16923 421b drivers/iommu/sun50i-iommu.o After: text data bss dec hex filename 14726 2117 64 16907 420b drivers/iommu/sun50i-iommu.o Signed-off-by: Rikard Falkeborn <[email protected]> Acked-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Joerg Roedel <[email protected]>
1 parent ae7d292 commit 79074f6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/iommu/sun50i-iommu.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -771,7 +771,7 @@ static int sun50i_iommu_of_xlate(struct device *dev,
771771
return iommu_fwspec_add_ids(dev, &id, 1);
772772
}
773773

774-
static struct iommu_ops sun50i_iommu_ops = {
774+
static const struct iommu_ops sun50i_iommu_ops = {
775775
.pgsize_bitmap = SZ_4K,
776776
.attach_dev = sun50i_iommu_attach_device,
777777
.detach_dev = sun50i_iommu_detach_device,

0 commit comments

Comments
 (0)