Whamcloud - gitweb
LU-18518 ldiskfs: fix LC_SRC_NFS_FILLDIR_USE_CTX check 33/57333/3
authorSohei Koyama <skoyama@ddn.com>
Sun, 8 Dec 2024 13:59:39 +0000 (22:59 +0900)
committerOleg Drokin <green@whamcloud.com>
Thu, 2 Jan 2025 20:51:32 +0000 (20:51 +0000)
When compiled with clang, these checks always failed, resulting
in lustre device mount being stuck.

Signed-off-by: Sohei Koyama <skoyama@ddn.com>
Change-Id: I7bac750700b791046050964bdcd59c2f05d7d986
Test-Parameters: trivial
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/57333
Tested-by: Maloo <maloo@whamcloud.com>
Tested-by: jenkins <devops@whamcloud.com>
Reviewed-by: Jian Yu <yujian@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/autoconf/lustre-core.m4

index 4dc1b75..639835d 100644 (file)
@@ -1170,13 +1170,15 @@ lm_grant, [
 AC_DEFUN([LC_SRC_NFS_FILLDIR_USE_CTX], [
        LB2_LINUX_TEST_SRC([filldir_ctx], [
                #include <linux/fs.h>
-       ],[
+
+               int filldir(struct dir_context *ctx, const char* name,
+                           int i, loff_t off, u64 tmp, unsigned temp);
                int filldir(struct dir_context *ctx, const char* name,
                            int i, loff_t off, u64 tmp, unsigned temp)
                {
                        return 0;
                }
-
+       ],[
                struct dir_context ctx = {
                        .actor = filldir,
                };
@@ -4041,13 +4043,15 @@ AC_DEFUN([LC_HAVE_GET_RANDOM_U32_AND_U64], [
 AC_DEFUN([LC_SRC_NFS_FILLDIR_USE_CTX_RETURN_BOOL], [
        LB2_LINUX_TEST_SRC([filldir_ctx_return_bool], [
                #include <linux/fs.h>
-       ],[
+
+               bool filldir(struct dir_context *ctx, const char* name,
+                            int i, loff_t off, u64 tmp, unsigned temp);
                bool filldir(struct dir_context *ctx, const char* name,
                             int i, loff_t off, u64 tmp, unsigned temp)
                {
                        return 0;
                }
-
+       ],[
                struct dir_context ctx = {
                        .actor = filldir,
                };