Whamcloud - gitweb
LU-13907 llite: don't set FS_REQUIRES_DEV on client 74/39674/4
authorAndreas Dilger <adilger@whamcloud.com>
Thu, 13 Aug 2020 22:18:52 +0000 (16:18 -0600)
committerOleg Drokin <green@whamcloud.com>
Sat, 19 Sep 2020 18:13:01 +0000 (18:13 +0000)
If doing a client-only build, do not set the FS_REQUIRES_DEV flag
for the 'lustre' filesystem type.  This is only needed on the server,
but the filesystem type declaration is shared between both.

In master, this was fixed by declaring a new 'lustre_tgt' filesystem
type and using that for server filesystem mounts.  However, for 2.12
this is overkill, and it is possible to get a 95% fix by dropping
the FS_REQUIRES_DEV flag for the common case of client-only builds.

Test-Parameters: trivial
Signed-off-by: Andreas Dilger <adilger@dilger.ca>
Change-Id: Iab2e78515aba018e2a6bceb324ad1b8a313ebbe5
Reviewed-on: https://review.whamcloud.com/39674
Reviewed-by: Jian Yu <yujian@whamcloud.com>
Reviewed-by: James Simmons <jsimmons@infradead.org>
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/obdclass/obd_mount.c

index 2d32c65..3c7a51f 100644 (file)
@@ -1675,7 +1675,12 @@ static struct file_system_type lustre_fs_type = {
         .get_sb       = lustre_get_sb,
 #endif
         .kill_sb      = lustre_kill_super,
-       .fs_flags     = FS_REQUIRES_DEV | FS_HAS_FIEMAP | FS_RENAME_DOES_D_MOVE,
+       .fs_flags     = FS_HAS_FIEMAP | FS_RENAME_DOES_D_MOVE |
+#ifdef HAVE_SERVER_SUPPORT
+                       FS_REQUIRES_DEV,
+#else
+                       0,
+#endif
 };
 MODULE_ALIAS_FS("lustre");