Skip to content

Commit a2f528e

Browse files
Bartosz Golaszewskijoergroedel
authored andcommitted
iommu/sysfs: constify the class struct
All functions that take the class address as argument expect a const pointer so we can make the iommu class constant. Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org> Reviewed-by: Jason Gunthorpe <jgg@nvidia.com> Link: https://lore.kernel.org/r/20241018121725.61128-1-brgl@bgdev.pl Signed-off-by: Joerg Roedel <jroedel@suse.de>
1 parent 6632863 commit a2f528e

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

drivers/iommu/iommu-sysfs.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ static void release_device(struct device *dev)
3434
kfree(dev);
3535
}
3636

37-
static struct class iommu_class = {
37+
static const struct class iommu_class = {
3838
.name = "iommu",
3939
.dev_release = release_device,
4040
.dev_groups = dev_groups,

0 commit comments

Comments
 (0)