Whamcloud - gitweb
LU-10365 tests: set proper paths headers for sanity test 400a 37/31737/8
authorJames Simmons <uja.ornl@yahoo.com>
Tue, 21 Aug 2018 18:39:57 +0000 (14:39 -0400)
committerOleg Drokin <green@whamcloud.com>
Sat, 1 Sep 2018 03:29:21 +0000 (03:29 +0000)
For the case when /usr/include/lustre doesn't exist sanity test
400a attempts to use the lustre user land headers located in the
source tree. Some of the lustre user land headers are wrappers
around the UAPI headers so we need to include those paths as well.

A test move was done in the linux kernel that moved the UAPI headers
to their proper place. Errors were reported mainly due to
linux/types.h being missing. This could be the reason Ubuntu18 fails
the sanity 400a test.

Test-Parameters: trivial clientdistro=ubuntu1604 testlist=sanity envdefinitions=ONLY=400a

Change-Id: If17da7d9fc4cedb3b9c18feaafbee47d1f94d49b
Signed-off-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-on: https://review.whamcloud.com/31737
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: James Nunez <jnunez@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
12 files changed:
lnet/include/uapi/linux/lnet/libcfs_debug.h
lnet/include/uapi/linux/lnet/lnet-dlc.h
lnet/include/uapi/linux/lnet/lnetctl.h
lnet/include/uapi/linux/lnet/lnetst.h
lnet/include/uapi/linux/lnet/nidstr.h
lustre/include/uapi/linux/lustre/lustre_barrier_user.h
lustre/include/uapi/linux/lustre/lustre_cfg.h
lustre/include/uapi/linux/lustre/lustre_fid.h
lustre/include/uapi/linux/lustre/lustre_fiemap.h
lustre/include/uapi/linux/lustre/lustre_log_user.h
lustre/include/uapi/linux/lustre/lustre_ostid.h
lustre/tests/sanity.sh

index c4d9472..2672fe7 100644 (file)
@@ -38,6 +38,8 @@
 #ifndef __UAPI_LIBCFS_DEBUG_H__
 #define __UAPI_LIBCFS_DEBUG_H__
 
+#include <linux/types.h>
+
 /**
  * Format for debug message headers
  */
index 52d0c81..f10cbc3 100644 (file)
@@ -29,6 +29,7 @@
 #ifndef __UAPI_LNET_DLC_H_
 #define __UAPI_LNET_DLC_H_
 
+#include <linux/types.h>
 /*
  * This is due to us being out of kernel and the way the OpenSFS branch
  * handles CFLAGS.
index 7e211e1..84e6712 100644 (file)
@@ -22,6 +22,7 @@
 #ifndef __UAPI_LNETCTL_H_
 #define __UAPI_LNETCTL_H_
 
+#include <linux/types.h>
 /*
  * This is due to us being out of kernel and the way the OpenSFS branch
  * handles CFLAGS.
index 06d5283..804e5e8 100644 (file)
@@ -35,6 +35,8 @@
 #ifndef __UAPI_LNET_ST_H__
 #define __UAPI_LNET_ST_H__
 
+#include <linux/types.h>
+
 #define LST_FEAT_NONE          (0)
 #define LST_FEAT_BULK_LEN      (1 << 0)        /* enable variable page size */
 
index 0a9162e..c41b915 100644 (file)
@@ -28,6 +28,7 @@
 #ifndef _LNET_NIDSTRINGS_H
 #define _LNET_NIDSTRINGS_H
 
+#include <linux/types.h>
 /*
  * This is due to us being out of kernel and the way the OpenSFS branch
  * handles CFLAGS.
index 482e87f..e86b262 100644 (file)
@@ -31,6 +31,7 @@
 #ifndef _LUSTRE_BARRIER_USER_H
 # define _LUSTRE_BARRIER_USER_H
 
+#include <linux/types.h>
 /*
  * This is due to us being out of kernel and the way the OpenSFS branch
  * handles CFLAGS.
index b5d6cb9..d5b5b6c 100644 (file)
@@ -35,6 +35,7 @@
 
 #include <linux/errno.h>
 #include <linux/kernel.h>
+#include <linux/types.h>
 /*
  * This is due to us being out of kernel and the way the OpenSFS branch
  * handles CFLAGS.
index 8a430f7..0cf7c17 100644 (file)
@@ -37,6 +37,7 @@
 #ifndef _UAPI_LUSTRE_FID_H_
 #define _UAPI_LUSTRE_FID_H_
 
+#include <linux/types.h>
 /*
  * This is due to us being out of kernel and the way the OpenSFS branch
  * handles CFLAGS.
index cee135b..68562cd 100644 (file)
@@ -45,6 +45,7 @@
 #include <stddef.h>
 #include <linux/fiemap.h>
 #endif
+#include <linux/types.h>
 
 /* XXX: We use fiemap_extent::fe_reserved[0] */
 #define fe_device      fe_reserved[0]
index 1191c74..d9fe861 100644 (file)
@@ -38,6 +38,7 @@
 #ifndef _LUSTRE_LOG_USER_H
 #define _LUSTRE_LOG_USER_H
 
+#include <linux/types.h>
 /*
  * This is due to us being out of kernel and the way the OpenSFS branch
  * handles CFLAGS.
index de705e0..4a96640 100644 (file)
@@ -35,6 +35,7 @@
 #define _UAPI_LUSTRE_OSTID_H_
 
 #include <linux/errno.h>
+#include <linux/types.h>
 /*
  * This is due to us being out of kernel and the way the OpenSFS branch
  * handles CFLAGS.
index f5a0868..b5ffe45 100755 (executable)
@@ -110,8 +110,8 @@ elif [ -r /etc/os-release ]; then
                        # bug number for skipped test:
                        #                LU-10334 LU-10335 LU-10335 LU-10335
                        ALWAYS_EXCEPT+=" 103a     130a     130b     130c"
-                       #                LU-10335 LU-10335 LU-10365 LU-10366
-                       ALWAYS_EXCEPT+=" 130d     130e     400a     410"
+                       #                LU-10335 LU-10335 LU-10366
+                       ALWAYS_EXCEPT+=" 130d     130e     410"
                fi
        fi
 fi
@@ -18402,12 +18402,12 @@ test_400a() { # LU-1606, was conf-sanity test_74
 
        if ! [[ -d $prefix ]]; then
                # Assume we're running in tree and fixup the include path.
-               extra_flags+=" -I$LUSTRE/include"
-               extra_flags+=" -L$LUSTRE/utils"
+               extra_flags+=" -I$LUSTRE/../lnet/include/uapi -I$LUSTRE/include/uapi -I$LUSTRE/include"
+               extra_flags+=" -L$LUSTRE/utils/.lib"
        fi
 
        for prog in $LUSTRE_TESTS_API_DIR/*.c; do
-               $CC -Wall -Werror $extra_flags -llustreapi -o $out $prog ||
+               $CC -Wall -Werror $extra_flags -o $out $prog -llustreapi ||
                        error "client api broken"
        done
        rm -f $out