[PATCH v3 2/2] staging: lustre-libcfs: make static-variable constant

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This static can be made constant as it is never modified.

Found during sparse-cleanup.

Signed-off-by: Patrick Boettcher <patrick.boettcher@xxxxxxxxx>
---
 drivers/staging/lustre/lustre/libcfs/module.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/staging/lustre/lustre/libcfs/module.c b/drivers/staging/lustre/lustre/libcfs/module.c
index 3cce06a..f448fe3 100644
--- a/drivers/staging/lustre/lustre/libcfs/module.c
+++ b/drivers/staging/lustre/lustre/libcfs/module.c
@@ -705,7 +705,7 @@ struct lnet_debugfs_symlink_def {
 	char *target;
 };
 
-static struct lnet_debugfs_symlink_def lnet_debugfs_symlinks[] = {
+static const struct lnet_debugfs_symlink_def lnet_debugfs_symlinks[] = {
 	{ "console_ratelimit",
 	  "/sys/module/libcfs/parameters/libcfs_console_ratelimit"},
 	{ "debug_path",
@@ -760,7 +760,7 @@ static void insert_debugfs(void)
 {
 	struct ctl_table *table;
 	struct dentry *entry;
-	struct lnet_debugfs_symlink_def *symlinks;
+	const struct lnet_debugfs_symlink_def *symlinks;
 
 	if (lnet_debugfs_root == NULL)
 		lnet_debugfs_root = debugfs_create_dir("lnet", NULL);
-- 
2.1.4

_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel



[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux