staging: lustre: use NULL instead of 0 for pointer
authorDaeseok Youn <daeseok.youn@gmail.com>
Mon, 7 Apr 2014 02:47:17 +0000 (11:47 +0900)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 17 Apr 2014 03:24:31 +0000 (20:24 -0700)
Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/lustre/lustre/obdclass/obd_mount.c

index 6f8ba54e9667a3558690cdfabbf17b1861c018eb..419a32361359d16f0f0c437fc4bf069d34ec1c00 100644 (file)
@@ -187,7 +187,7 @@ int lustre_start_simple(char *obdname, char *type, char *uuid,
        int rc;
        CDEBUG(D_MOUNT, "Starting obd %s (typ=%s)\n", obdname, type);
 
-       rc = do_lcfg(obdname, 0, LCFG_ATTACH, type, uuid, 0, 0);
+       rc = do_lcfg(obdname, 0, LCFG_ATTACH, type, uuid, NULL, NULL);
        if (rc) {
                CERROR("%s attach error %d\n", obdname, rc);
                return rc;
@@ -195,7 +195,7 @@ int lustre_start_simple(char *obdname, char *type, char *uuid,
        rc = do_lcfg(obdname, 0, LCFG_SETUP, s1, s2, s3, s4);
        if (rc) {
                CERROR("%s setup error %d\n", obdname, rc);
-               do_lcfg(obdname, 0, LCFG_DETACH, 0, 0, 0, 0);
+               do_lcfg(obdname, 0, LCFG_DETACH, NULL, NULL, NULL, NULL);
        }
        return rc;
 }
@@ -337,7 +337,8 @@ int lustre_start_mgc(struct super_block *sb)
                        lnet_process_id_t id;
                        while ((rc = LNetGetId(i++, &id)) != -ENOENT) {
                                rc = do_lcfg(mgcname, id.nid,
-                                            LCFG_ADD_UUID, niduuid, 0,0,0);
+                                            LCFG_ADD_UUID, niduuid,
+                                            NULL, NULL, NULL);
                        }
                } else {
                        /* Use mgsnode= nids */
@@ -351,7 +352,8 @@ int lustre_start_mgc(struct super_block *sb)
                        }
                        while (class_parse_nid(ptr, &nid, &ptr) == 0) {
                                rc = do_lcfg(mgcname, nid,
-                                            LCFG_ADD_UUID, niduuid, 0,0,0);
+                                            LCFG_ADD_UUID, niduuid,
+                                            NULL, NULL, NULL);
                                i++;
                        }
                }
@@ -360,7 +362,7 @@ int lustre_start_mgc(struct super_block *sb)
                ptr = lsi->lsi_lmd->lmd_dev;
                while (class_parse_nid(ptr, &nid, &ptr) == 0) {
                        rc = do_lcfg(mgcname, nid,
-                                    LCFG_ADD_UUID, niduuid, 0,0,0);
+                                    LCFG_ADD_UUID, niduuid, NULL, NULL, NULL);
                        i++;
                        /* Stop at the first failover nid */
                        if (*ptr == ':')
@@ -396,13 +398,13 @@ int lustre_start_mgc(struct super_block *sb)
                while (class_parse_nid_quiet(ptr, &nid, &ptr) == 0) {
                        j++;
                        rc = do_lcfg(mgcname, nid,
-                                    LCFG_ADD_UUID, niduuid, 0,0,0);
+                                    LCFG_ADD_UUID, niduuid, NULL, NULL, NULL);
                        if (*ptr == ':')
                                break;
                }
                if (j > 0) {
                        rc = do_lcfg(mgcname, 0, LCFG_ADD_CONN,
-                                    niduuid, 0, 0, 0);
+                                    niduuid, NULL, NULL, NULL);
                        i++;
                } else {
                        /* at ":/fsname" */
@@ -532,7 +534,7 @@ static int lustre_stop_mgc(struct super_block *sb)
        for (i = 0; i < lsi->lsi_lmd->lmd_mgs_failnodes; i++) {
                sprintf(ptr, "_%x", i);
                rc = do_lcfg(LUSTRE_MGC_OBDNAME, 0, LCFG_DEL_UUID,
-                            niduuid, 0, 0, 0);
+                            niduuid, NULL, NULL, NULL);
                if (rc)
                        CERROR("del MDC UUID %s failed: rc = %d\n",
                               niduuid, rc);