mirror of
https://github.com/torvalds/linux.git
synced 2024-12-24 11:51:27 +00:00
accel: constify the struct device_type usage
Since commit aed65af1cc
("drivers: make device_type const"), the driver
core can properly handle constant struct device_type. Move the
accel_sysfs_device_minor variable to be a constant structure as well,
placing it into read-only memory which can not be modified at runtime.
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Ricardo B. Marliere <ricardo@marliere.net>
Reviewed-by: Oded Gabbay <ogabbay@kernel.org>
Signed-off-by: Oded Gabbay <ogabbay@kernel.org>
This commit is contained in:
parent
fa58b59493
commit
576d7cc5a9
@ -23,7 +23,7 @@ static struct idr accel_minors_idr;
|
||||
|
||||
static struct dentry *accel_debugfs_root;
|
||||
|
||||
static struct device_type accel_sysfs_device_minor = {
|
||||
static const struct device_type accel_sysfs_device_minor = {
|
||||
.name = "accel_minor"
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user