Whamcloud - gitweb
LU-6142 obdclass: make obd_psdev static 95/39395/2
authorMr NeilBrown <neilb@suse.de>
Thu, 16 Jul 2020 03:53:39 +0000 (13:53 +1000)
committerOleg Drokin <green@whamcloud.com>
Thu, 13 Aug 2020 06:00:30 +0000 (06:00 +0000)
obd_psdev is only used in one file, so it can be local to that file.

Test-Parameters: trivial
Signed-off-by: Mr NeilBrown <neilb@suse.de>
Change-Id: Ib74d78e0e72e054d5f998d54f1476216926b293b
Reviewed-on: https://review.whamcloud.com/39395
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: James Simmons <jsimmons@infradead.org>
Reviewed-by: Arshad Hussain <arshad.super@gmail.com>
Reviewed-by: Jian Yu <yujian@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/include/obd_class.h
lustre/obdclass/class_obd.c

index afb71e7..8148dcc 100644 (file)
@@ -1861,7 +1861,6 @@ struct root_squash_info {
 int server_name2index(const char *svname, __u32 *idx, const char **endptr);
 
 /* linux-module.c */
 int server_name2index(const char *svname, __u32 *idx, const char **endptr);
 
 /* linux-module.c */
-extern struct miscdevice obd_psdev;
 int obd_ioctl_getdata(char **buf, int *len, void __user *arg);
 int class_procfs_init(void);
 int class_procfs_clean(void);
 int obd_ioctl_getdata(char **buf, int *len, void __user *arg);
 int class_procfs_init(void);
 int class_procfs_clean(void);
index a399698..9b34434 100644 (file)
@@ -502,7 +502,7 @@ static struct file_operations obd_psdev_fops = {
 };
 
 /* modules setup */
 };
 
 /* modules setup */
-struct miscdevice obd_psdev = {
+static struct miscdevice obd_psdev = {
        .minor  = MISC_DYNAMIC_MINOR,
        .name   = OBD_DEV_NAME,
        .fops   = &obd_psdev_fops,
        .minor  = MISC_DYNAMIC_MINOR,
        .name   = OBD_DEV_NAME,
        .fops   = &obd_psdev_fops,