Skip to content

Commit cf1e515

Browse files
Jinjie Ruanjgunthorpe
authored andcommitted
iommufd/selftest: Make dirty_ops static
The sparse tool complains as follows: drivers/iommu/iommufd/selftest.c:277:30: warning: symbol 'dirty_ops' was not declared. Should it be static? This symbol is not used outside of selftest.c, so marks it static. Fixes: 266ce58 ("iommufd/selftest: Test IOMMU_HWPT_ALLOC_DIRTY_TRACKING") Link: https://patch.msgid.link/r/[email protected] Signed-off-by: Jinjie Ruan <[email protected]> Reviewed-by: Yi Liu <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
1 parent 950aeef commit cf1e515

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/iommu/iommufd/selftest.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,7 @@ static int mock_domain_read_and_clear_dirty(struct iommu_domain *domain,
273273
return 0;
274274
}
275275

276-
const struct iommu_dirty_ops dirty_ops = {
276+
static const struct iommu_dirty_ops dirty_ops = {
277277
.set_dirty_tracking = mock_domain_set_dirty_tracking,
278278
.read_and_clear_dirty = mock_domain_read_and_clear_dirty,
279279
};

0 commit comments

Comments
 (0)