[PATCH] iommufd/selftest: set varaiable mock_iommu_device storage-class-specifier to static
From: Tom Rix
Date: Mon Apr 03 2023 - 20:24:15 EST
smatch reports
drivers/iommu/iommufd/selftest.c:295:21: warning: symbol
'mock_iommu_device' was not declared. Should it be static?
This variable is only used in one file so it should be static.
Signed-off-by: Tom Rix <trix@xxxxxxxxxx>
---
drivers/iommu/iommufd/selftest.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/iommu/iommufd/selftest.c b/drivers/iommu/iommufd/selftest.c
index 2deda489a934..9d43334e4faf 100644
--- a/drivers/iommu/iommufd/selftest.c
+++ b/drivers/iommu/iommufd/selftest.c
@@ -292,7 +292,7 @@ static const struct iommu_ops mock_ops = {
},
};
-struct iommu_device mock_iommu_device = {
+static struct iommu_device mock_iommu_device = {
.ops = &mock_ops,
};
--
2.27.0