summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/xe/xe_gt_sysfs.c
diff options
context:
space:
mode:
authorTejas Upadhyay <tejas.upadhyay@intel.com>2023-07-03 12:06:10 +0300
committerRodrigo Vivi <rodrigo.vivi@intel.com>2023-12-21 19:35:15 +0300
commit55d8ac9631aaa8ae3794341c52009f635a0d3188 (patch)
treeb97d9d2b28bcc8fa7fef896670d89d0eb1756953 /drivers/gpu/drm/xe/xe_gt_sysfs.c
parent43e82fb9ecf0009aeb95e284067a9a24a55a93ed (diff)
downloadlinux-55d8ac9631aaa8ae3794341c52009f635a0d3188.tar.xz
drm/xe: make kobject type struct as constant
Since commit ee6d3dd4ed48 ("driver core: make kobj_type constant.") the driver core allows the usage of const struct kobj_type. Take advantage of this to constify the structure definition to prevent modification at runtime. Reviewed-by: Nirmoy Das <nirmoy.das@intel.com> Signed-off-by: Tejas Upadhyay <tejas.upadhyay@intel.com> Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Diffstat (limited to 'drivers/gpu/drm/xe/xe_gt_sysfs.c')
-rw-r--r--drivers/gpu/drm/xe/xe_gt_sysfs.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/xe/xe_gt_sysfs.c b/drivers/gpu/drm/xe/xe_gt_sysfs.c
index cdfe5995259b..b955940e8dc6 100644
--- a/drivers/gpu/drm/xe/xe_gt_sysfs.c
+++ b/drivers/gpu/drm/xe/xe_gt_sysfs.c
@@ -17,7 +17,7 @@ static void xe_gt_sysfs_kobj_release(struct kobject *kobj)
kfree(kobj);
}
-static struct kobj_type xe_gt_sysfs_kobj_type = {
+static const struct kobj_type xe_gt_sysfs_kobj_type = {
.release = xe_gt_sysfs_kobj_release,
.sysfs_ops = &kobj_sysfs_ops,
};