4 # Wrapper for AC_CONFIG_SUBDIR
6 AC_DEFUN([LC_CONFIG_SRCDIR], [
7 AC_CONFIG_SRCDIR([lustre/obdclass/obdo.c])
15 # lustre specific paths
17 AC_DEFUN([LC_PATH_DEFAULTS], [
18 # ptlrpc kernel build requires this
26 demodir='$(docdir)/demo'
29 pkgexampledir='${pkgdatadir}/examples'
30 AC_SUBST(pkgexampledir)
36 # is the target os supported?
38 AC_DEFUN([LC_TARGET_SUPPORTED], [
47 ]) # LC_TARGET_SUPPORTED
50 # LC_GLIBC_SUPPORT_FHANDLES
52 AC_DEFUN([LC_GLIBC_SUPPORT_FHANDLES], [
53 AC_CHECK_FUNCS([name_to_handle_at],
54 [AC_DEFINE(HAVE_FHANDLE_GLIBC_SUPPORT, 1,
55 [file handle and related syscalls are supported])],
56 [AC_MSG_WARN([file handle and related syscalls are not supported])])
57 ]) # LC_GLIBC_SUPPORT_FHANDLES
62 # Ensure the stack size is at least 8k in Lustre server (all kernels)
64 AC_DEFUN([LC_STACK_SIZE], [
65 LB_CHECK_COMPILE([if stack size is at least 8k],
67 #include <linux/thread_info.h>
69 #if THREAD_SIZE < 8192
70 #error "stack size < 8192"
72 ], [], [AC_MSG_ERROR([
74 Lustre requires that Linux is configured with at least a 8KB stack.
81 # Allow the user to set the MDS thread upper limit
83 AC_DEFUN([LC_MDS_MAX_THREADS], [
84 AC_MSG_CHECKING([for maximum number of MDS threads])
85 AC_ARG_WITH([mds_max_threads],
86 AC_HELP_STRING([--with-mds-max-threads=count],
87 [maximum threads available on the MDS: (default=512)]),
88 [AC_DEFINE_UNQUOTED(MDS_MAX_THREADS, $with_mds_max_threads,
89 [maximum number of MDS threads])])
90 AC_MSG_RESULT([$with_mds_max_threads])
91 ]) # LC_MDS_MAX_THREADS
96 # the pinger is temporary, until we have the recovery node in place
98 AC_DEFUN([LC_CONFIG_PINGER], [
99 AC_MSG_CHECKING([whether to enable Lustre pinger support])
100 AC_ARG_ENABLE([pinger],
101 AC_HELP_STRING([--disable-pinger],
102 [disable recovery pinger support]),
103 [], [enable_pinger="yes"])
104 AC_MSG_RESULT([$enable_pinger])
105 AS_IF([test "x$enable_pinger" != xno],
106 [AC_DEFINE(ENABLE_PINGER, 1,[Use the Pinger])])
107 ]) # LC_CONFIG_PINGER
112 # do checksum of bulk data between client and OST
114 AC_DEFUN([LC_CONFIG_CHECKSUM], [
115 AC_MSG_CHECKING([whether to enable data checksum support])
116 AC_ARG_ENABLE([checksum],
117 AC_HELP_STRING([--disable-checksum],
118 [disable data checksum support]),
119 [], [enable_checksum="yes"])
120 AC_MSG_RESULT([$enable_checksum])
121 AS_IF([test "x$enable_checksum" != xno],
122 [AC_DEFINE(ENABLE_CHECKSUM, 1, [do data checksums])])
123 ]) # LC_CONFIG_CHECKSUM
128 # enable distributed flock by default
130 AC_DEFUN([LC_CONFIG_FLOCK], [
131 AC_MSG_CHECKING([whether to enable flock by default])
132 AC_ARG_ENABLE([flock],
133 AC_HELP_STRING([--disable-flock],
134 [disable flock by default]),
135 [], [enable_flock="yes"])
136 AC_MSG_RESULT([$enable_flock])
137 AS_IF([test "x$enable_flock" != xno],
138 [AC_DEFINE(ENABLE_FLOCK, 1, [enable flock by default])])
142 # LC_CONFIG_HEALTH_CHECK_WRITE
144 # Turn off the actual write to the disk
146 AC_DEFUN([LC_CONFIG_HEALTH_CHECK_WRITE], [
147 AC_MSG_CHECKING([whether to enable a write with the health check])
148 AC_ARG_ENABLE([health_write],
149 AC_HELP_STRING([--enable-health_write],
150 [enable disk writes when doing health check]),
151 [], [enable_health_write="no"])
152 AC_MSG_RESULT([$enable_health_write])
153 AS_IF([test "x$enable_health_write" != xno],
154 [AC_DEFINE(USE_HEALTH_CHECK_WRITE, 1, [Write when Checking Health])])
155 ]) # LC_CONFIG_HEALTH_CHECK_WRITE
158 # LC_CONFIG_LRU_RESIZE
160 AC_DEFUN([LC_CONFIG_LRU_RESIZE], [
161 AC_MSG_CHECKING([whether to enable lru self-adjusting])
162 AC_ARG_ENABLE([lru_resize],
163 AC_HELP_STRING([--enable-lru-resize],
164 [enable lru resize support]),
165 [], [enable_lru_resize="yes"])
166 AC_MSG_RESULT([$enable_lru_resize])
167 AS_IF([test "x$enable_lru_resize" != xno],
168 [AC_DEFINE(HAVE_LRU_RESIZE_SUPPORT, 1, [Enable lru resize support])])
169 ]) # LC_CONFIG_LRU_RESIZE
174 # Quota support. The kernel must support CONFIG_QUOTA.
176 AC_DEFUN([LC_QUOTA_CONFIG], [
177 LB_CHECK_CONFIG_IM([QUOTA], [],
180 Lustre quota requires that CONFIG_QUOTA is enabled in your kernel.
185 #[AC_DEFINE(CONFIG_LUSTRE_FS_POSIX_ACL, 1, [Enable POSIX acl])])
187 # LC_POSIX_ACL_CONFIG
191 AC_DEFUN([LC_POSIX_ACL_CONFIG], [
192 LB_CHECK_CONFIG_IM([FS_POSIX_ACL],
193 [AC_DEFINE(CONFIG_LUSTRE_FS_POSIX_ACL, 1, [Enable POSIX acl])
195 ]) # LC_POSIX_ACL_CONFIG
197 LB_CHECK_CONFIG_IM([CRYPTO_MD5], [],
198 [AC_MSG_WARN([kernel MD5 support is recommended by using GSS.])])
201 # LC_CONFIG_GSS_KEYRING
203 # default 'auto', tests for dependencies, if found, enables;
204 # only called if gss is enabled
206 AC_DEFUN([LC_CONFIG_GSS_KEYRING], [
207 AC_MSG_CHECKING([whether to enable gss keyring backend])
208 AC_ARG_ENABLE([gss_keyring],
209 [AC_HELP_STRING([--disable-gss-keyring],
210 [disable gss keyring backend])],
211 [], [enable_gss_keyring="auto"])
212 AC_MSG_RESULT([$enable_gss_keyring])
213 AS_IF([test "x$enable_gss_keyring" != xno], [
214 LB_CHECK_CONFIG_IM([KEYS], [], [
215 gss_keyring_conf_test="fail"
216 AC_MSG_WARN([GSS keyring backend requires that CONFIG_KEYS be enabled in your kernel.])])
218 AC_CHECK_LIB([keyutils], [keyctl_search], [], [
219 gss_keyring_conf_test="fail"
220 AC_MSG_WARN([GSS keyring backend requires libkeyutils])])
222 AS_IF([test "x$gss_keyring_conf_test" != xfail], [
223 AC_DEFINE([HAVE_GSS_KEYRING], [1],
224 [Define this if you enable gss keyring backend])
225 enable_gss_keyring="yes"
227 AS_IF([test "x$enable_gss_keyring" = xyes], [
228 AC_MSG_ERROR([Cannot enable gss_keyring. See above for details.])
232 ]) # LC_CONFIG_GSS_KEYRING
235 # LC_HAVE_CRED_TGCRED
237 # rhel7 struct cred has no member tgcred
239 AC_DEFUN([LC_HAVE_CRED_TGCRED], [
240 LB_CHECK_COMPILE([if 'struct cred' has member 'tgcred'],
242 #include <linux/cred.h>
244 ((struct cred *)0)->tgcred = NULL;
246 AC_DEFINE(HAVE_CRED_TGCRED, 1,
247 [struct cred has member tgcred])
249 ]) # LC_HAVE_CRED_TGCRED
252 # LC_KEY_TYPE_INSTANTIATE_2ARGS
254 # rhel7 key_type->instantiate takes 2 args (struct key, struct key_preparsed_payload)
256 AC_DEFUN([LC_KEY_TYPE_INSTANTIATE_2ARGS], [
257 LB_CHECK_COMPILE([if 'key_type->instantiate' has two args],
258 key_type_instantiate_2args, [
259 #include <linux/key-type.h>
261 ((struct key_type *)0)->instantiate(0, NULL);
263 AC_DEFINE(HAVE_KEY_TYPE_INSTANTIATE_2ARGS, 1,
264 [key_type->instantiate has two args])
266 ]) # LC_KEY_TYPE_INSTANTIATE_2ARGS
271 AC_DEFUN([LC_CONFIG_SUNRPC], [
272 LB_CHECK_CONFIG_IM([SUNRPC], [], [
273 AS_IF([test "x$sunrpc_required" = xyes], [
276 kernel SUNRPC support is required by using GSS.
279 ]) # LC_CONFIG_SUNRPC
282 # LC_CONFIG_GSS (default 'auto' (tests for dependencies, if found, enables))
284 # Build gss and related tools of Lustre. Currently both kernel and user space
285 # parts are depend on linux platform.
287 AC_DEFUN([LC_CONFIG_GSS], [
288 AC_MSG_CHECKING([whether to enable gss support])
290 [AC_HELP_STRING([--enable-gss], [enable gss support])],
291 [], [enable_gss="auto"])
292 AC_MSG_RESULT([$enable_gss])
294 AS_IF([test "x$enable_gss" != xno], [
295 LC_CONFIG_GSS_KEYRING
297 LC_KEY_TYPE_INSTANTIATE_2ARGS
298 sunrpc_required=$enable_gss
302 LB_CHECK_CONFIG_IM([CRYPTO_MD5], [],
303 [AC_MSG_WARN([kernel MD5 support is recommended by using GSS.])])
304 LB_CHECK_CONFIG_IM([CRYPTO_SHA1], [],
305 [AC_MSG_WARN([kernel SHA1 support is recommended by using GSS.])])
306 LB_CHECK_CONFIG_IM([CRYPTO_SHA256], [],
307 [AC_MSG_WARN([kernel SHA256 support is recommended by using GSS.])])
308 LB_CHECK_CONFIG_IM([CRYPTO_SHA512], [],
309 [AC_MSG_WARN([kernel SHA512 support is recommended by using GSS.])])
311 require_krb5=$enable_gss
315 AS_IF([test -n "$KRBDIR"], [
316 gss_conf_test="success"
318 gss_conf_test="failure"
321 AS_IF([test "x$gss_conf_test" = xsuccess && test "x$enable_gss" != xno], [
322 AC_DEFINE([HAVE_GSS], [1], [Define this is if you enable gss])
325 enable_gss_keyring="no"
329 enable_ssk=$enable_gss
331 enable_gss_keyring="no"
337 # OpenSSL 1.0+ return int for HMAC functions but older SLES11 versions do not
338 AC_DEFUN([LC_OPENSSL_SSK], [
339 AC_MSG_CHECKING([whether OpenSSL has functions needed for SSK])
340 AS_IF([test "x$enable_ssk" != xno], [
341 AC_COMPILE_IFELSE([AC_LANG_SOURCE([
342 #include <openssl/hmac.h>
343 #include <openssl/evp.h>
347 rc = HMAC_Init_ex(NULL, "test", 4, EVP_md_null(), NULL);
349 ])],[AC_DEFINE(HAVE_OPENSSL_SSK, 1,
350 [OpenSSL HMAC functions needed for SSK])],
353 AC_MSG_RESULT([$enable_ssk])
356 # LC_OPENSSL_GETSEPOL
358 # OpenSSL is needed for l_getsepol
359 AC_DEFUN([LC_OPENSSL_GETSEPOL], [
360 AC_MSG_CHECKING([whether openssl-devel is present])
361 AC_COMPILE_IFELSE([AC_LANG_SOURCE([
362 #include <openssl/evp.h>
365 EVP_MD_CTX *mdctx = EVP_MD_CTX_create();
368 AC_DEFINE(HAVE_OPENSSL_GETSEPOL, 1, [openssl-devel is present])
369 enable_getsepol="yes"
375 No openssk-devel headers found, unable to build l_getsepol and SELinux status checking
378 AC_MSG_RESULT([$enable_getsepol])
379 ]) # LC_OPENSSL_GETSEPOL
381 # LC_INODE_PERMISION_2ARGS
383 # up to v2.6.27 had a 3 arg version (inode, mask, nameidata)
384 # v2.6.27->v2.6.37 had a 2 arg version (inode, mask)
385 # v2.6.37->v3.0 had a 3 arg version (inode, mask, nameidata)
386 # v3.1 onward have a 2 arg version (inode, mask)
388 AC_DEFUN([LC_INODE_PERMISION_2ARGS], [
389 LB_CHECK_COMPILE([if 'inode_operations->permission' has two args],
390 inode_ops_permission_2args, [
391 #include <linux/fs.h>
393 struct inode *inode __attribute__ ((unused));
396 inode->i_op->permission(NULL, 0);
398 AC_DEFINE(HAVE_INODE_PERMISION_2ARGS, 1,
399 [inode_operations->permission has two args])
401 ]) # LC_INODE_PERMISION_2ARGS
404 # LC_HAVE_FSTYPE_MOUNT
406 # 2.6.39 replace get_sb with mount in struct file_system_type
408 AC_DEFUN([LC_HAVE_FSTYPE_MOUNT], [
409 LB_CHECK_COMPILE([if 'file_system_type' has 'mount' field],
410 file_system_type_mount, [
411 #include <linux/fs.h>
413 struct file_system_type fst = { };
416 mount = (void *)fst.mount;
418 AC_DEFINE(HAVE_FSTYPE_MOUNT, 1,
419 [struct file_system_type has mount field])
421 ]) # LC_HAVE_FSTYPE_MOUNT
424 # LC_HAVE_FHANDLE_SYSCALLS
426 # 2.6.39 The open_by_handle_at() and name_to_handle_at() system calls were
427 # added to Linux kernel 2.6.39.
428 # Check if client supports these functions
430 AC_DEFUN([LC_HAVE_FHANDLE_SYSCALLS], [
431 LB_CHECK_CONFIG_IM([FHANDLE],[
432 AC_DEFINE(HAVE_FHANDLE_SYSCALLS, 1,
433 [kernel supports fhandles and related syscalls])
435 ]) # LC_HAVE_FHANDLE_SYSCALLS
438 # LC_HAVE_INODE_OWNER_OR_CAPABLE
440 # 2.6.39 renames is_owner_or_cap to inode_owner_or_capable
442 AC_DEFUN([LC_HAVE_INODE_OWNER_OR_CAPABLE], [
443 LB_CHECK_COMPILE([if 'inode_owner_or_capable' exist],
444 inode_owner_or_capable, [
445 #include <linux/fs.h>
447 inode_owner_or_capable(NULL);
449 AC_DEFINE(HAVE_INODE_OWNER_OR_CAPABLE, 1,
450 [inode_owner_or_capable exist])
452 ]) # LC_HAVE_INODE_OWNER_OR_CAPABLE
455 # LC_DIRTY_INODE_WITH_FLAG
457 # 3.0 dirty_inode() has a flag parameter
458 # see kernel commit aa38572954ade525817fe88c54faebf85e5a61c0
460 AC_DEFUN([LC_DIRTY_INODE_WITH_FLAG], [
461 LB_CHECK_COMPILE([if 'dirty_inode' super_operation takes flag],
462 dirty_inode_super_operation_flag, [
463 #include <linux/fs.h>
465 struct inode *inode = NULL;
466 inode->i_sb->s_op->dirty_inode(NULL, 0);
468 AC_DEFINE(HAVE_DIRTY_INODE_HAS_FLAG, 1,
469 [dirty_inode super_operation takes flag])
471 ]) # LC_DIRTY_INODE_WITH_FLAG
476 # 3.0 introduced setns
478 AC_DEFUN([LC_SETNS], [
479 AC_CHECK_HEADERS([sched.h], [], [],
482 AC_CHECK_FUNCS([setns])
486 # LC_LM_XXX_LOCK_MANAGER_OPS
488 # 3.1 renames lock-manager ops(lock_manager_operations) from fl_xxx to lm_xxx
489 # see kernel commit 8fb47a4fbf858a164e973b8ea8ef5e83e61f2e50
491 AC_DEFUN([LC_LM_XXX_LOCK_MANAGER_OPS], [
492 LB_CHECK_COMPILE([if 'lock-manager' ops renamed to 'lm_xxx'],
493 lock_manager_ops_lm_xxx, [
494 #include <linux/fs.h>
496 struct lock_manager_operations lm_ops;
497 lm_ops.lm_notify = NULL;
499 AC_DEFINE(HAVE_LM_XXX_LOCK_MANAGER_OPS, 1,
500 [lock-manager ops renamed to lm_xxx])
502 ]) # LC_LM_XXX_LOCK_MANAGER_OPS
507 # 3.1 kills inode->i_alloc_sem, use i_dio_count and inode_dio_wait
509 # see kernel commit bd5fe6c5eb9c548d7f07fe8f89a150bb6705e8e3
511 AC_DEFUN([LC_INODE_DIO_WAIT], [
512 LB_CHECK_COMPILE([if 'inode->i_alloc_sem' is killed and use inode_dio_wait],
514 #include <linux/fs.h>
516 inode_dio_wait((struct inode *)0);
518 AC_DEFINE(HAVE_INODE_DIO_WAIT, 1,
519 [inode->i_alloc_sem is killed and use inode_dio_wait])
521 ]) # LC_INODE_DIO_WAIT
526 # 3.1 adds get_acl method to inode_operations to read ACL from disk.
527 # see kernel commit 4e34e719e457f2e031297175410fc0bd4016a085
529 AC_DEFUN([LC_IOP_GET_ACL], [
530 LB_CHECK_COMPILE([if 'inode_operations' has '.get_acl' member function],
532 #include <linux/fs.h>
534 struct inode_operations iop;
537 AC_DEFINE(HAVE_IOP_GET_ACL, 1,
538 [inode_operations has .get_acl member function])
543 # LC_FILE_LLSEEK_SIZE
545 # 3.1 introduced generic_file_llseek_size()
547 AC_DEFUN([LC_FILE_LLSEEK_SIZE], [
548 LB_CHECK_EXPORT([generic_file_llseek_size], [fs/read_write.c],
549 [AC_DEFINE(HAVE_FILE_LLSEEK_SIZE, 1,
550 [generic_file_llseek_size is exported by the kernel])])
551 ]) # LC_FILE_LLSEEK_SIZE
554 # LC_RADIX_EXCEPTION_ENTRY
555 # 3.1 adds radix_tree_exception_entry.
557 AC_DEFUN([LC_RADIX_EXCEPTION_ENTRY], [
558 LB_CHECK_COMPILE([radix_tree_exceptional_entry exist],
559 radix_tree_exceptional_entry, [
560 #include <linux/radix-tree.h>
562 radix_tree_exceptional_entry(NULL);
564 AC_DEFINE(HAVE_RADIX_EXCEPTION_ENTRY, 1,
565 [radix_tree_exceptional_entry exist])
567 ]) # LC_RADIX_EXCEPTION_ENTRY
570 # LC_HAVE_PROTECT_I_NLINK
572 # 3.2 protects inode->i_nlink from direct modification
573 # see kernel commit a78ef704a8dd430225955f0709b22d4a6ba21deb
574 # at the same time adds set_nlink(), so checks set_nlink() for it.
576 AC_DEFUN([LC_HAVE_PROTECT_I_NLINK], [
577 LB_CHECK_COMPILE([if 'inode->i_nlink' is protected from direct modification],
578 inode_i_nlink_protected, [
579 #include <linux/fs.h>
584 AC_DEFINE(HAVE_PROTECT_I_NLINK, 1,
585 [inode->i_nlink is protected from direct modification])
587 ]) # LC_HAVE_PROTECT_I_NLINK
590 # 2.6.39 security_inode_init_security takes a 'struct qstr' parameter
592 # 3.2 security_inode_init_security takes a callback to set xattrs
594 AC_DEFUN([LC_HAVE_SECURITY_IINITSEC], [
595 LB_CHECK_COMPILE([if security_inode_init_security takes a callback],
596 security_inode_init_security_callback, [
597 #include <linux/security.h>
599 security_inode_init_security(NULL, NULL, NULL, (const initxattrs)NULL, NULL);
601 AC_DEFINE(HAVE_SECURITY_IINITSEC_CALLBACK, 1,
602 [security_inode_init_security takes a callback to set xattrs])
604 LB_CHECK_COMPILE([if security_inode_init_security takes a 'struct qstr' parameter],
605 security_inode_init_security_qstr, [
606 #include <linux/security.h>
608 security_inode_init_security(NULL, NULL, (struct qstr *)NULL, NULL, NULL, NULL);
610 AC_DEFINE(HAVE_SECURITY_IINITSEC_QSTR, 1,
611 [security_inode_init_security takes a 'struct qstr' parameter])
614 ]) # LC_HAVE_SECURITY_IINITSEC
617 # 2.6.39 vfs_create takes a 'struct nameidata' parameter
619 AC_DEFUN([LC_VFS_CREATE_USE_NAMEIDATA], [
620 LB_CHECK_COMPILE([if vfs_create takes a struct nameidata parameter],
622 #include <linux/namei.h>
623 #include <linux/fs.h>
625 struct nameidata *nd;
626 vfs_create(NULL, NULL, 0, nd);
628 AC_DEFINE(HAVE_VFS_CREATE_USE_NAMEIDATA, 1,
629 [vfs_create use nameidata as parameter])
631 ]) # LC_VFS_CREATE_USE_NAMEIDATA
634 # LC_HAVE_MIGRATE_HEADER
636 # 3.3 introduces migrate_mode.h and migratepage has 4 args
638 AC_DEFUN([LC_HAVE_MIGRATE_HEADER], [
639 LB_CHECK_FILE([$LINUX/include/linux/migrate.h], [
640 AC_DEFINE(HAVE_MIGRATE_H, 1,
641 [kernel has include/linux/migrate.h])
643 LB_CHECK_FILE([$LINUX/include/linux/migrate_mode.h], [
644 AC_DEFINE(HAVE_MIGRATE_MODE_H, 1,
645 [kernel has include/linux/migrate_mode.h])
648 ]) # LC_HAVE_MIGRATE_HEADER
651 # LC_MIGRATEPAGE_4ARGS
653 AC_DEFUN([LC_MIGRATEPAGE_4ARGS], [
654 LB_CHECK_COMPILE([if 'address_space_operations.migratepage' has 4 args],
655 address_space_ops_migratepage_4args, [
656 #include <linux/fs.h>
657 #ifdef HAVE_MIGRATE_H
658 #include <linux/migrate.h>
659 #elif defined(HAVE_MIGRATE_MODE_H)
660 #include <linux/migrate_mode.h>
663 struct address_space_operations aops = { };
664 aops.migratepage(NULL, NULL, NULL, MIGRATE_ASYNC);
666 AC_DEFINE(HAVE_MIGRATEPAGE_4ARGS, 1,
667 [address_space_operations.migratepage has 4 args])
669 ]) # LC_MIGRATEPAGE_4ARGS
672 # LC_SUPEROPS_USE_DENTRY
674 # 3.3 switchs super_operations to use dentry as parameter (but not vfsmount)
675 # see kernel commit 34c80b1d93e6e20ca9dea0baf583a5b5510d92d4
677 AC_DEFUN([LC_SUPEROPS_USE_DENTRY], [
678 tmp_flags="$EXTRA_KCFLAGS"
679 EXTRA_KCFLAGS="-Werror"
680 LB_CHECK_COMPILE([if 'super_operations' use 'dentry' as parameter],
682 #include <linux/fs.h>
683 int show_options(struct seq_file *seq, struct dentry *root) {
687 struct super_operations ops;
688 ops.show_options = show_options;
690 AC_DEFINE(HAVE_SUPEROPS_USE_DENTRY, 1,
691 [super_operations use dentry as parameter])
693 EXTRA_KCFLAGS="$tmp_flags"
694 ]) # LC_SUPEROPS_USE_DENTRY
697 # LC_INODEOPS_USE_UMODE_T
699 # 3.3 switchs inode_operations to use umode_t as parameter (but not int)
700 # see kernel commit 1a67aafb5f72a436ca044293309fa7e6351d6a35
702 AC_DEFUN([LC_INODEOPS_USE_UMODE_T], [
703 tmp_flags="$EXTRA_KCFLAGS"
704 EXTRA_KCFLAGS="-Werror"
705 LB_CHECK_COMPILE([if 'inode_operations' use 'umode_t' as parameter],
707 #include <linux/fs.h>
708 #include <linux/types.h>
709 int my_mknod(struct inode *dir, struct dentry *dchild,
710 umode_t mode, dev_t dev)
715 struct inode_operations ops;
716 ops.mknod = my_mknod;
718 AC_DEFINE(HAVE_INODEOPS_USE_UMODE_T, 1,
719 [inode_operations use umode_t as parameter])
721 EXTRA_KCFLAGS="$tmp_flags"
722 ]) # LC_INODEOPS_USE_UMODE_T
725 # LC_KMAP_ATOMIC_HAS_1ARG
727 # 3.4 kmap_atomic removes second argument
728 # see kernel commit 1ec9c5ddc17aa398f05646abfcbaf315b544e62f
730 AC_DEFUN([LC_KMAP_ATOMIC_HAS_1ARG], [
731 LB_CHECK_COMPILE([if 'kmap_atomic' has only 1 argument],
733 #include <linux/highmem.h>
737 AC_DEFINE(HAVE_KMAP_ATOMIC_HAS_1ARG, 1,
738 [have kmap_atomic has only 1 argument])
740 ]) # LC_KMAP_ATOMIC_HAS_1ARG
743 # LC_HAVE_D_MAKE_ROOT
745 # 3.4 converts d_alloc_root to d_make_root
746 # see kernel commit 32991ab305ace7017c62f8eecbe5eb36dc32e13b
748 AC_DEFUN([LC_HAVE_D_MAKE_ROOT], [
749 LB_CHECK_COMPILE([if have 'd_make_root'],
751 #include <linux/fs.h>
753 d_make_root((struct inode *)NULL);
755 AC_DEFINE(HAVE_D_MAKE_ROOT, 1,
758 ]) # LC_HAVE_D_MAKE_ROOT
761 # LC_HAVE_CACHE_REGISTER
763 # 3.4 cache_register/cache_unregister are removed
764 # see kernel commit 2c5f846747526e2b83c5f1b8e69016be0e2e87c0
765 # Note, since 2.6.37 cache_register_net/cache_unregister_net
766 # are defined, but not exported.
767 # 3.3 cache_register_net/cache_unregister_net are
768 # exported and replacing cache_register/cache_unregister in 3.4
770 AC_DEFUN([LC_HAVE_CACHE_REGISTER], [
771 LB_CHECK_COMPILE([if have 'cache_register'],
773 #include <linux/sunrpc/cache.h>
775 cache_register(NULL);
777 AC_DEFINE(HAVE_CACHE_REGISTER, 1,
778 [have cache_register])
780 ]) # LC_HAVE_CACHE_REGISTER
783 # LC_HAVE_CLEAR_INODE
785 # 3.5 renames end_writeback() back to clear_inode()...
786 # see kernel commit dbd5768f87ff6fb0a4fe09c4d7b6c4a24de99430
788 AC_DEFUN([LC_HAVE_CLEAR_INODE], [
789 LB_CHECK_COMPILE([if have 'clear_inode'],
791 #include <linux/fs.h>
793 clear_inode((struct inode *)NULL);
795 AC_DEFINE(HAVE_CLEAR_INODE, 1,
798 ]) # LC_HAVE_CLEAR_INODE
801 # LC_HAVE_ENCODE_FH_PARENT
803 # 3.5 encode_fh has parent inode passed in directly
804 # see kernel commit b0b0382b
806 AC_DEFUN([LC_HAVE_ENCODE_FH_PARENT], [
807 tmp_flags="$EXTRA_KCFLAGS"
808 EXTRA_KCFLAGS="-Werror"
809 LB_CHECK_COMPILE([if 'encode_fh' have parent inode as parameter],
810 encode_fh_parent_inode, [
811 #include <linux/exportfs.h>
812 #include <linux/fs.h>
813 #include <linux/types.h>
814 int ll_encode_fh(struct inode *i, __u32 *a, int *b, struct inode *p)
819 struct export_operations exp_op;
820 exp_op.encode_fh = ll_encode_fh;
822 AC_DEFINE(HAVE_ENCODE_FH_PARENT, 1,
823 [have parent inode as parameter])
825 EXTRA_KCFLAGS="$tmp_flags"
826 ]) # LC_HAVE_ENCODE_FH_PARENT
829 # LC_FILE_LLSEEK_SIZE_5ARG
831 # 3.5 has generic_file_llseek_size with 5 args
833 AC_DEFUN([LC_FILE_LLSEEK_SIZE_5ARG], [
834 LB_CHECK_COMPILE([if Linux kernel has 'generic_file_llseek_size' with 5 args],
835 generic_file_llseek_size_5args, [
836 #include <linux/fs.h>
838 generic_file_llseek_size(NULL, 0, 0, 0, 0);
840 AC_DEFINE(HAVE_FILE_LLSEEK_SIZE_5ARGS, 1,
841 [kernel has generic_file_llseek_size with 5 args])
843 ]) # LC_FILE_LLSEEK_SIZE_5ARG
846 # LC_LLITE_DATA_IS_LIST
848 # 3.6 switch i_dentry/d_alias from list to hlist
850 # In the upstream kernels d_alias first changes
851 # to a hlist and then in later version, 3.11, gets
852 # moved to the union d_u. Due to some distros having
853 # d_alias in the d_u union as a struct list, which
854 # has never existed upstream stream, we can't test
855 # if d_alias is a list or hlist directly. If ever
856 # i_dentry and d_alias even up different combos then
857 # the build will fail. In that case then we will need
858 # to separate out the i_dentry and d_alias test below.
860 AC_DEFUN([LC_DATA_FOR_LLITE_IS_LIST], [
861 tmp_flags="$EXTRA_KCFLAGS"
862 EXTRA_KCFLAGS="-Werror"
863 LB_CHECK_COMPILE([if 'i_dentry/d_alias' uses 'list'],
864 i_dentry_d_alias_list, [
865 #include <linux/fs.h>
868 INIT_LIST_HEAD(&inode.i_dentry);
870 AC_DEFINE(DATA_FOR_LLITE_IS_LIST, 1,
871 [both i_dentry/d_alias uses list])
873 EXTRA_KCFLAGS="$tmp_flags"
874 ]) # LC_DATA_FOR_LLITE_IS_LIST
877 # LC_DENTRY_OPEN_USE_PATH
879 # 3.6 dentry_open uses struct path as first argument
880 # see kernel commit 765927b2
882 AC_DEFUN([LC_DENTRY_OPEN_USE_PATH], [
883 tmp_flags="$EXTRA_KCFLAGS"
884 EXTRA_KCFLAGS="-Werror"
885 LB_CHECK_COMPILE([if 'dentry_open' uses 'struct path' as first argument],
887 #include <linux/fs.h>
888 #include <linux/path.h>
891 dentry_open(&path, 0, NULL);
893 AC_DEFINE(HAVE_DENTRY_OPEN_USE_PATH, 1,
894 [dentry_open uses struct path as first argument])
896 EXTRA_KCFLAGS="$tmp_flags"
897 ]) # LC_DENTRY_OPEN_USE_PATH
900 # LC_HAVE_IOP_ATOMIC_OPEN
902 # 3.6 vfs adds iop->atomic_open
904 AC_DEFUN([LC_HAVE_IOP_ATOMIC_OPEN], [
905 LB_CHECK_COMPILE([if 'iop' has 'atomic_open'],
906 inode_ops_atomic_open, [
907 #include <linux/fs.h>
909 struct inode_operations iop;
910 iop.atomic_open = NULL;
912 AC_DEFINE(HAVE_IOP_ATOMIC_OPEN, 1,
913 [have iop atomic_open])
915 ]) # LC_HAVE_IOP_ATOMIC_OPEN
918 # LC_HAVE_SB_START_WRITE
920 # RHEL6 2.6.32, 3.6 or newer support wrapped FS freeze functions
922 AC_DEFUN([LC_HAVE_SB_START_WRITE], [
923 LB_CHECK_COMPILE([if kernel supports wrapped FS freeze functions],
925 #include <linux/fs.h>
927 sb_start_write(NULL);
929 AC_DEFINE(HAVE_SB_START_WRITE, 1,
930 [kernel supports wrapped FS freeze functions])
932 ]) # LC_HAVE_SB_START_WRITE
935 # LC_HAVE_POSIXACL_USER_NS
937 # 3.7 posix_acl_{to,from}_xattr take struct user_namespace
939 AC_DEFUN([LC_HAVE_POSIXACL_USER_NS], [
940 LB_CHECK_COMPILE([if 'posix_acl_to_xattr' takes 'struct user_namespace'],
941 posix_acl_to_xattr_user_namespace, [
942 #include <linux/fs.h>
943 #include <linux/posix_acl_xattr.h>
945 posix_acl_to_xattr((struct user_namespace *)NULL, NULL, NULL, 0);
947 AC_DEFINE(HAVE_POSIXACL_USER_NS, 1,
948 [posix_acl_to_xattr takes struct user_namespace])
950 ]) # LC_HAVE_POSIXACL_USER_NS
953 # LC_HAVE_FILE_F_INODE
955 # 3.8 struct file has new member f_inode
957 AC_DEFUN([LC_HAVE_FILE_F_INODE], [
958 LB_CHECK_COMPILE([if 'struct file' has member 'f_inode'],
960 #include <linux/fs.h>
962 ((struct file *)0)->f_inode = NULL;
964 AC_DEFINE(HAVE_FILE_F_INODE, 1,
965 [struct file has member f_inode])
967 ]) # LC_HAVE_FILE_F_INODE
972 # 3.8 has introduced inline function file_inode
974 AC_DEFUN([LC_HAVE_FILE_INODE], [
975 LB_CHECK_COMPILE([if file_inode() exists],
977 #include <linux/fs.h>
981 AC_DEFINE(HAVE_FILE_INODE, 1,
982 [file_inode() has been defined])
984 ]) # LC_HAVE_FILE_INODE
987 # LC_HAVE_SUNRPC_UPCALL_HAS_3ARGS
989 AC_DEFUN([LC_HAVE_SUNRPC_UPCALL_HAS_3ARGS], [
990 LB_CHECK_COMPILE([if 'sunrpc_cache_pipe_upcall' takes 3 args],
991 sunrpc_cache_pipe_upcall_3args, [
992 #include <linux/sunrpc/cache.h>
994 sunrpc_cache_pipe_upcall(NULL, NULL, NULL);
996 AC_DEFINE(HAVE_SUNRPC_UPCALL_HAS_3ARGS, 1,
997 [sunrpc_cache_pipe_upcall takes 3 args])
999 ]) # LC_HAVE_SUNRPC_UPCALL_HAS_3ARGS
1002 # LC_HAVE_HLIST_FOR_EACH_3ARG
1004 # 3.9 uses hlist_for_each_entry with 3 args
1005 # b67bfe0d42cac56c512dd5da4b1b347a23f4b70a
1007 AC_DEFUN([LC_HAVE_HLIST_FOR_EACH_3ARG], [
1008 LB_CHECK_COMPILE([if 'hlist_for_each_entry' has 3 args],
1009 hlist_for_each_entry_3args, [
1010 #include <linux/list.h>
1011 #include <linux/fs.h>
1013 struct hlist_head *head = NULL;
1014 struct inode *inode;
1016 hlist_for_each_entry(inode, head, i_hash) {
1020 AC_DEFINE(HAVE_HLIST_FOR_EACH_3ARG, 1,
1021 [hlist_for_each_entry has 3 args])
1023 ]) # LC_HAVE_HLIST_FOR_EACH_3ARG
1026 # LC_HAVE_BIO_END_SECTOR
1028 # 3.9 introduces bio_end_sector macro
1029 # f73a1c7d117d07a96d89475066188a2b79e53c48
1031 AC_DEFUN([LC_HAVE_BIO_END_SECTOR], [
1032 LB_CHECK_COMPILE([if 'bio_end_sector' is defined],
1034 #include <linux/bio.h>
1036 struct bio bio = { };
1037 unsigned long long end;
1039 end = bio_end_sector(&bio);
1041 AC_DEFINE(HAVE_BIO_END_SECTOR, 1,
1042 [bio_end_sector is defined])
1044 ]) # LC_HAVE_BIO_END_SECTOR
1047 # 3.9 created is_sxid
1049 AC_DEFUN([LC_HAVE_IS_SXID], [
1050 LB_CHECK_COMPILE([if 'is_sxid' is defined],
1052 #include <linux/fs.h>
1054 struct inode inode = { };
1056 is_sxid(inode.i_mode);
1058 AC_DEFINE(HAVE_IS_SXID, 1, [is_sxid is defined])
1060 ]) # LC_HAVE_IS_SXID
1063 # LC_HAVE_VFS_GETATTR_2ARGS
1065 AC_DEFUN([LC_HAVE_VFS_GETATTR_2ARGS], [
1066 LB_CHECK_COMPILE([if vfs_getattr takes 2 args],
1068 #include <linux/fs.h>
1072 vfs_getattr(&path, NULL);
1074 AC_DEFINE(HAVE_VFS_GETATTR_2ARGS, 1,
1075 [vfs_getattr takes 2 args])
1077 ]) # LC_HAVE_VFS_GETATTR_2ARGS
1080 # LC_HAVE_REMOVE_PROC_SUBTREE
1082 # 3.10 introduced remove_proc_subtree
1084 AC_DEFUN([LC_HAVE_REMOVE_PROC_SUBTREE], [
1085 LB_CHECK_COMPILE([if 'remove_proc_subtree' is defined],
1086 remove_proc_subtree, [
1087 #include <linux/proc_fs.h>
1089 remove_proc_subtree(NULL, NULL);
1091 AC_DEFINE(HAVE_REMOVE_PROC_SUBTREE, 1,
1092 [remove_proc_subtree is defined])
1094 ]) # LC_HAVE_REMOVE_PROC_SUBTREE
1097 # LC_HAVE_PROC_REMOVE
1099 # 3.10 introduced proc_remove
1101 AC_DEFUN([LC_HAVE_PROC_REMOVE], [
1102 LB_CHECK_COMPILE([if 'proc_remove' is defined],
1104 #include <linux/proc_fs.h>
1108 AC_DEFINE(HAVE_PROC_REMOVE, 1,
1109 [proc_remove is defined])
1111 ]) # LC_HAVE_PROC_REMOVE
1113 AC_DEFUN([LC_HAVE_PROJECT_QUOTA], [
1114 LB_CHECK_COMPILE([if get_projid exists],
1117 #include <linux/quota.h>
1119 struct dquot_operations ops = { };
1121 ops.get_projid(NULL, NULL);
1123 AC_DEFINE(HAVE_PROJECT_QUOTA, 1,
1124 [get_projid function exists])
1126 ]) # LC_HAVE_PROJECT_QUOTA
1130 # LC_HAVE_SECURITY_DENTRY_INIT_SECURITY
1132 # 3.10 introduced security_dentry_init_security()
1134 AC_DEFUN([LC_HAVE_SECURITY_DENTRY_INIT_SECURITY], [
1135 LB_CHECK_COMPILE([if 'security_dentry_init_security' is defined],
1136 security_dentry_init_security, [
1137 #include <linux/security.h>
1139 security_dentry_init_security(NULL, 0, NULL, NULL, NULL);
1141 AC_DEFINE(HAVE_SECURITY_DENTRY_INIT_SECURITY, 1,
1142 [security_dentry_init_security' is defined])
1144 ]) # LC_HAVE_SECURITY_DENTRY_INIT_SECURITY
1147 # 3.10 exports security_inode_listsecurity
1149 AC_DEFUN([LC_HAVE_SECURITY_INODE_LISTSECURITY], [
1150 LB_CHECK_COMPILE([if security_inode_listsecurity() is available/exported],
1151 security_inode_listsecurity, [
1152 #include <linux/security.h>
1154 security_inode_listsecurity(NULL, NULL, 0);
1156 AC_DEFINE(HAVE_SECURITY_INODE_LISTSECURITY, 1,
1157 [security_inode_listsecurity() is available/exported])
1159 ]) # LC_HAVE_SECURITY_INODE_LISTSECURITY
1162 # LC_INVALIDATE_RANGE
1164 # 3.11 invalidatepage requires the length of the range to invalidate
1166 AC_DEFUN([LC_INVALIDATE_RANGE], [
1167 LB_CHECK_COMPILE([if 'address_space_operations.invalidatepage' requires 3 arguments],
1168 address_space_ops_invalidatepage_3args, [
1169 #include <linux/fs.h>
1171 struct address_space_operations a_ops;
1172 a_ops.invalidatepage(NULL, 0, 0);
1174 AC_DEFINE(HAVE_INVALIDATE_RANGE, 1,
1175 [address_space_operations.invalidatepage needs 3 arguments])
1177 ]) # LC_INVALIDATE_RANGE
1180 # LC_HAVE_DIR_CONTEXT
1182 # 3.11 readdir now takes the new struct dir_context
1184 AC_DEFUN([LC_HAVE_DIR_CONTEXT], [
1185 LB_CHECK_COMPILE([if 'dir_context' exist],
1187 #include <linux/fs.h>
1189 #ifdef FMODE_KABI_ITERATE
1190 #error "back to use readdir in kabi_extand mode"
1192 struct dir_context ctx;
1197 AC_DEFINE(HAVE_DIR_CONTEXT, 1,
1198 [dir_context exist])
1200 ]) # LC_HAVE_DIR_CONTEXT
1203 # LC_D_COMPARE_5ARGS
1205 # 3.11 dentry_operations.d_compare() taken 5 arguments.
1207 AC_DEFUN([LC_D_COMPARE_5ARGS], [
1208 LB_CHECK_COMPILE([if 'd_compare' taken 5 arguments],
1210 #include <linux/dcache.h>
1212 ((struct dentry_operations*)0)->d_compare(NULL,NULL,0,NULL,NULL);
1214 AC_DEFINE(HAVE_D_COMPARE_5ARGS, 1,
1215 [d_compare need 5 arguments])
1217 ]) # LC_D_COMPARE_5ARGS
1222 # 3.11 need to access d_count to get dentry reference count
1224 AC_DEFUN([LC_HAVE_DCOUNT], [
1225 LB_CHECK_COMPILE([if 'd_count' exists],
1227 #include <linux/dcache.h>
1229 struct dentry de = { };
1232 count = d_count(&de);
1234 AC_DEFINE(HAVE_D_COUNT, 1,
1240 # LC_PID_NS_FOR_CHILDREN
1242 # 3.11 replaces pid_ns by pid_ns_for_children in struct nsproxy
1244 AC_DEFUN([LC_PID_NS_FOR_CHILDREN], [
1245 LB_CHECK_COMPILE([if 'struct nsproxy' has 'pid_ns_for_children'],
1246 pid_ns_for_children, [
1247 #include <linux/nsproxy.h>
1250 ns.pid_ns_for_children = NULL;
1252 AC_DEFINE(HAVE_PID_NS_FOR_CHILDREN, 1,
1253 ['struct nsproxy' has 'pid_ns_for_children'])
1255 ]) # LC_PID_NS_FOR_CHILDREN
1258 # LC_OLDSIZE_TRUNCATE_PAGECACHE
1260 # 3.12 truncate_pagecache without oldsize parameter
1262 AC_DEFUN([LC_OLDSIZE_TRUNCATE_PAGECACHE], [
1263 LB_CHECK_COMPILE([if 'truncate_pagecache' with 'old_size' parameter],
1264 truncate_pagecache_old_size, [
1265 #include <linux/mm.h>
1267 truncate_pagecache(NULL, 0, 0);
1269 AC_DEFINE(HAVE_OLDSIZE_TRUNCATE_PAGECACHE, 1,
1272 ]) # LC_OLDSIZE_TRUNCATE_PAGECACHE
1275 # LC_PTR_ERR_OR_ZERO
1277 # For some reason SLES11SP4 is missing the PTR_ERR_OR_ZERO macro
1278 # It was added to linux kernel 3.12
1280 AC_DEFUN([LC_PTR_ERR_OR_ZERO_MISSING], [
1281 LB_CHECK_COMPILE([if 'PTR_ERR_OR_ZERO' is missing],
1283 #include <linux/err.h>
1285 if (PTR_ERR_OR_ZERO(NULL)) return 0;
1287 AC_DEFINE(HAVE_PTR_ERR_OR_ZERO, 1,
1288 ['PTR_ERR_OR_ZERO' exist])
1290 ]) # LC_PTR_ERR_OR_ZERO_MISSING
1293 # LC_HAVE_DENTRY_D_U_D_ALIAS
1295 # 3.11 kernel moved d_alias to the union d_u in struct dentry
1297 # Some distros move d_alias to d_u but it is still a struct list
1299 AC_DEFUN([LC_HAVE_DENTRY_D_U_D_ALIAS], [
1300 AS_IF([test "x$lb_cv_compile_i_dentry_d_alias_list" = xyes], [
1301 LB_CHECK_COMPILE([if list 'dentry.d_u.d_alias' exist],
1303 #include <linux/list.h>
1304 #include <linux/dcache.h>
1307 INIT_LIST_HEAD(&de.d_u.d_alias);
1309 AC_DEFINE(HAVE_DENTRY_D_U_D_ALIAS, 1,
1310 [list dentry.d_u.d_alias exist])
1313 LB_CHECK_COMPILE([if hlist 'dentry.d_u.d_alias' exist],
1315 #include <linux/list.h>
1316 #include <linux/dcache.h>
1319 INIT_HLIST_NODE(&de.d_u.d_alias);
1321 AC_DEFINE(HAVE_DENTRY_D_U_D_ALIAS, 1,
1322 [hlist dentry.d_u.d_alias exist])
1325 ]) # LC_HAVE_DENTRY_D_U_D_ALIAS
1328 # LC_HAVE_DENTRY_D_CHILD
1330 # 3.11 kernel d_child has been moved out of the union d_u
1333 AC_DEFUN([LC_HAVE_DENTRY_D_CHILD], [
1334 LB_CHECK_COMPILE([if 'dentry.d_child' exist],
1336 #include <linux/list.h>
1337 #include <linux/dcache.h>
1340 INIT_LIST_HEAD(&de.d_child);
1342 AC_DEFINE(HAVE_DENTRY_D_CHILD, 1,
1343 [dentry.d_child exist])
1345 ]) # LC_HAVE_DENTRY_D_CHILD
1350 # 3.12 ki_left removed from struct kiocb
1352 AC_DEFUN([LC_KIOCB_KI_LEFT], [
1353 LB_CHECK_COMPILE([if 'struct kiocb' with 'ki_left' member],
1355 #include <linux/aio.h>
1357 ((struct kiocb*)0)->ki_left = 0;
1359 AC_DEFINE(HAVE_KIOCB_KI_LEFT, 1,
1362 ]) # LC_KIOCB_KI_LEFT
1365 # LC_INIT_LIST_HEAD_RCU
1367 # 3.12 added INIT_LIST_HEAD_RCU in commit 2a855b644c310d5db5
1368 # which is unfortunately an inline function and not a macro
1369 # that can be tested directly, so it needs a configure check.
1371 AC_DEFUN([LC_INIT_LIST_HEAD_RCU], [
1372 LB_CHECK_COMPILE([if 'INIT_LIST_HEAD_RCU' exists],
1373 init_list_head_rcu, [
1374 #include <linux/list.h>
1375 #include <linux/rculist.h>
1377 struct list_head list;
1378 INIT_LIST_HEAD_RCU(&list);
1380 AC_DEFINE(HAVE_INIT_LIST_HEAD_RCU, 1,
1381 [INIT_LIST_HEAD_RCU exists])
1383 ]) # LC_INIT_LIST_HEAD_RCU
1386 # LC_VFS_RENAME_5ARGS
1388 # 3.13 has vfs_rename with 5 args
1390 AC_DEFUN([LC_VFS_RENAME_5ARGS], [
1391 LB_CHECK_COMPILE([if Linux kernel has 'vfs_rename' with 5 args],
1393 #include <linux/fs.h>
1395 vfs_rename(NULL, NULL, NULL, NULL, NULL);
1397 AC_DEFINE(HAVE_VFS_RENAME_5ARGS, 1,
1398 [kernel has vfs_rename with 5 args])
1400 ]) # LC_VFS_RENAME_5ARGS
1403 # LC_VFS_UNLINK_3ARGS
1405 # 3.13 has vfs_unlink with 3 args
1407 AC_DEFUN([LC_VFS_UNLINK_3ARGS], [
1408 LB_CHECK_COMPILE([if Linux kernel has 'vfs_unlink' with 3 args],
1410 #include <linux/fs.h>
1412 vfs_unlink(NULL, NULL, NULL);
1414 AC_DEFINE(HAVE_VFS_UNLINK_3ARGS, 1,
1415 [kernel has vfs_unlink with 3 args])
1417 ]) # LC_VFS_UNLINK_3ARGS
1419 # LC_HAVE_D_IS_POSITIVE
1421 # Kernel version 3.13 b18825a7c8e37a7cf6abb97a12a6ad71af160de7
1422 # d_is_positive is added
1424 AC_DEFUN([LC_HAVE_D_IS_POSITIVE], [
1425 LB_CHECK_COMPILE([if 'd_is_positive' exist],
1427 #include <linux/dcache.h>
1429 d_is_positive(NULL);
1431 AC_DEFINE(HAVE_D_IS_POSITIVE, 1,
1432 ['d_is_positive' is available])
1434 ]) # LC_HAVE_D_IS_POSITIVE
1439 # 3.14 move some of its data in struct bio into the new
1442 AC_DEFUN([LC_HAVE_BVEC_ITER], [
1443 LB_CHECK_COMPILE([if Linux kernel has struct bvec_iter],
1445 #include <linux/bio.h>
1447 struct bvec_iter iter;
1449 iter.bi_bvec_done = 0;
1451 AC_DEFINE(HAVE_BVEC_ITER, 1,
1452 [kernel has struct bvec_iter])
1454 ]) # LC_HAVE_BVEC_ITER
1459 # 3.14 adds set_acl method to inode_operations
1460 # see kernel commit 893d46e443346370cd4ea81d9d35f72952c62a37
1462 AC_DEFUN([LC_IOP_SET_ACL], [
1463 LB_CHECK_COMPILE([if 'inode_operations' has '.set_acl' member function],
1464 inode_ops_set_acl, [
1465 #include <linux/fs.h>
1467 struct inode_operations iop;
1470 AC_DEFINE(HAVE_IOP_SET_ACL, 1,
1471 [inode_operations has .set_acl member function])
1476 # LC_HAVE_TRUNCATE_IPAGE_FINAL
1478 # 3.14 bring truncate_inode_pages_final for evict_inode
1480 AC_DEFUN([LC_HAVE_TRUNCATE_IPAGES_FINAL], [
1481 LB_CHECK_COMPILE([if Linux kernel has truncate_inode_pages_final],
1482 truncate_ipages_final, [
1483 #include <linux/mm.h>
1485 truncate_inode_pages_final(NULL);
1487 AC_DEFINE(HAVE_TRUNCATE_INODE_PAGES_FINAL, 1,
1488 [kernel has truncate_inode_pages_final])
1490 ]) # LC_HAVE_TRUNCATE_IPAGES_FINAL
1493 # LC_IOPS_RENAME_WITH_FLAGS
1495 # 3.14 has inode_operations->rename with 5 args
1496 # commit 520c8b16505236fc82daa352e6c5e73cd9870cff
1498 AC_DEFUN([LC_IOPS_RENAME_WITH_FLAGS], [
1499 LB_CHECK_COMPILE([if 'inode_operations->rename' taken flags as argument],
1500 iops_rename_with_flags, [
1501 #include <linux/fs.h>
1503 struct inode *i1 = NULL, *i2 = NULL;
1504 struct dentry *d1 = NULL, *d2 = NULL;
1506 rc = ((struct inode_operations *)0)->rename(i1, d1, i2, d2, 0);
1508 AC_DEFINE(HAVE_IOPS_RENAME_WITH_FLAGS, 1,
1509 [inode_operations->rename need flags as argument])
1511 ]) # LC_IOPS_RENAME_WITH_FLAGS
1514 # LC_VFS_RENAME_6ARGS
1516 # 3.15 has vfs_rename with 6 args
1518 AC_DEFUN([LC_VFS_RENAME_6ARGS], [
1519 LB_CHECK_COMPILE([if Linux kernel has 'vfs_rename' with 6 args],
1521 #include <linux/fs.h>
1523 vfs_rename(NULL, NULL, NULL, NULL, NULL, NULL);
1525 AC_DEFINE(HAVE_VFS_RENAME_6ARGS, 1,
1526 [kernel has vfs_rename with 6 args])
1528 ]) # LC_VFS_RENAME_6ARGS
1531 # LC_DIRECTIO_USE_ITER
1533 # 3.16 kernel changes direct IO to use iov_iter
1535 AC_DEFUN([LC_DIRECTIO_USE_ITER], [
1536 LB_CHECK_COMPILE([if direct IO uses iov_iter],
1538 #include <linux/fs.h>
1540 struct address_space_operations ops = { };
1541 struct iov_iter *iter = NULL;
1544 ops.direct_IO(0, NULL, iter, offset);
1546 AC_DEFINE(HAVE_DIRECTIO_ITER, 1,
1547 [direct IO uses iov_iter])
1549 ]) # LC_DIRECTIO_USE_ITER
1552 # LC_HAVE_IOV_ITER_INIT_DIRECTION
1555 # 3.16 linux commit 71d8e532b1549a478e6a6a8a44f309d050294d00
1556 # changed iov_iter_init api to start accepting a tag
1557 # that defines if its a read or write operation
1559 AC_DEFUN([LC_HAVE_IOV_ITER_INIT_DIRECTION], [
1560 tmp_flags="$EXTRA_KCFLAGS"
1561 EXTRA_KCFLAGS="-Werror"
1562 LB_CHECK_COMPILE([if 'iov_iter_init' takes a tag],
1564 #include <linux/uio.h>
1565 #include <linux/fs.h>
1567 const struct iovec *iov = NULL;
1569 iov_iter_init(NULL, READ, iov, 1, 0);
1571 AC_DEFINE(HAVE_IOV_ITER_INIT_DIRECTION, 1,
1572 [iov_iter_init handles directional tag])
1574 EXTRA_KCFLAGS="$tmp_flags"
1575 ]) # LC_HAVE_IOV_ITER_INIT_DIRECTION
1578 # LC_HAVE_IOV_ITER_TRUNCATE
1581 # 3.16 introduces a new API iov_iter_truncate()
1583 AC_DEFUN([LC_HAVE_IOV_ITER_TRUNCATE], [
1584 tmp_flags="$EXTRA_KCFLAGS"
1585 EXTRA_KCFLAGS="-Werror"
1586 LB_CHECK_COMPILE([if 'iov_iter_truncate' exists ],
1588 #include <linux/uio.h>
1589 #include <linux/fs.h>
1591 struct iov_iter *i = NULL;
1593 iov_iter_truncate(i, 0);
1595 AC_DEFINE(HAVE_IOV_ITER_TRUNCATE, 1, [iov_iter_truncate exists])
1597 EXTRA_KCFLAGS="$tmp_flags"
1598 ]) # LC_HAVE_IOV_ITER_TRUNCATE
1601 # LC_HAVE_FILE_OPERATIONS_READ_WRITE_ITER
1603 # 3.16 introduces [read|write]_iter to struct file_operations
1605 AC_DEFUN([LC_HAVE_FILE_OPERATIONS_READ_WRITE_ITER], [
1606 LB_CHECK_COMPILE([if 'file_operations.[read|write]_iter' exist],
1607 file_function_iter, [
1608 #include <linux/fs.h>
1610 ((struct file_operations *)NULL)->read_iter(NULL, NULL);
1611 ((struct file_operations *)NULL)->write_iter(NULL, NULL);
1613 AC_DEFINE(HAVE_FILE_OPERATIONS_READ_WRITE_ITER, 1,
1614 [file_operations.[read|write]_iter functions exist])
1616 ]) # LC_HAVE_FILE_OPERATIONS_READ_WRITE_ITER
1619 # LC_HAVE_INTERVAL_BLK_INTEGRITY
1621 # 3.17 replace sector_size with interval in struct blk_integrity
1623 AC_DEFUN([LC_HAVE_INTERVAL_BLK_INTEGRITY], [
1624 LB_CHECK_COMPILE([if 'blk_integrity.interval' exist],
1625 interval_blk_integrity, [
1626 #include <linux/blkdev.h>
1628 ((struct blk_integrity *)0)->interval = 0;
1630 AC_DEFINE(HAVE_INTERVAL_BLK_INTEGRITY, 1,
1631 [blk_integrity.interval exist])
1633 ]) # LC_HAVE_INTERVAL_BLK_INTEGRITY
1638 # 3.17 replaces key_type::match with match_preparse
1639 # and has new struct key_match_data
1641 AC_DEFUN([LC_KEY_MATCH_DATA], [
1642 LB_CHECK_COMPILE([if struct key_match field exist],
1644 #include <linux/key-type.h>
1646 struct key_match_data data;
1648 data.raw_data = NULL;
1650 AC_DEFINE(HAVE_KEY_MATCH_DATA, 1,
1651 [struct key_match_data exist])
1653 ]) # LC_KEY_MATCH_DATA
1656 # LC_NFS_FILLDIR_USE_CTX
1658 # 3.18 kernel moved from void cookie to struct dir_context
1660 AC_DEFUN([LC_NFS_FILLDIR_USE_CTX], [
1661 tmp_flags="$EXTRA_KCFLAGS"
1662 EXTRA_KCFLAGS="-Werror"
1663 LB_CHECK_COMPILE([if filldir_t uses struct dir_context],
1665 #include <linux/fs.h>
1667 int filldir(struct dir_context *ctx, const char* name,
1668 int i, loff_t off, u64 tmp, unsigned temp)
1673 struct dir_context ctx = {
1677 ctx.actor(NULL, "test", 0, (loff_t) 0, 0, 0);
1679 AC_DEFINE(HAVE_FILLDIR_USE_CTX, 1,
1680 [filldir_t needs struct dir_context as argument])
1682 EXTRA_KCFLAGS="$tmp_flags"
1683 ]) # LC_NFS_FILLDIR_USE_CTX
1686 # LC_PERCPU_COUNTER_INIT
1688 # 3.18 For kernels 3.18 and after percpu_counter_init starts
1689 # to pass a GFP_* memory allocation flag for internal
1690 # memory allocation purposes.
1692 AC_DEFUN([LC_PERCPU_COUNTER_INIT], [
1693 LB_CHECK_COMPILE([if percpu_counter_init uses GFP_* flag as argument],
1694 percpu_counter_init, [
1695 #include <linux/percpu_counter.h>
1697 percpu_counter_init(NULL, 0, GFP_KERNEL);
1699 AC_DEFINE(HAVE_PERCPU_COUNTER_INIT_GFP_FLAG, 1,
1700 [percpu_counter_init uses GFP_* flag])
1702 ]) # LC_PERCPU_COUNTER_INIT
1705 # LC_KIOCB_HAS_NBYTES
1707 # 3.19 kernel removed ki_nbytes from struct kiocb
1709 AC_DEFUN([LC_KIOCB_HAS_NBYTES], [
1710 LB_CHECK_COMPILE([if struct kiocb has ki_nbytes field],
1712 #include <linux/fs.h>
1714 struct kiocb iocb = { };
1718 AC_DEFINE(HAVE_KI_NBYTES, 1, [ki_nbytes field exist])
1720 ]) # LC_KIOCB_HAS_NBYTES
1723 # LC_HAVE_DQUOT_QC_DQBLK
1725 # 3.19 has quotactl_ops->[sg]et_dqblk that take struct kqid and qc_dqblk
1726 # Added in commit 14bf61ffe
1728 AC_DEFUN([LC_HAVE_DQUOT_QC_DQBLK], [
1729 tmp_flags="$EXTRA_KCFLAGS"
1730 EXTRA_KCFLAGS="-Werror"
1731 LB_CHECK_COMPILE([if 'quotactl_ops.set_dqblk' takes struct qc_dqblk],
1733 #include <linux/fs.h>
1734 #include <linux/quota.h>
1736 ((struct quotactl_ops *)0)->set_dqblk(NULL, *((struct kqid*)0), (struct qc_dqblk*)0);
1738 AC_DEFINE(HAVE_DQUOT_QC_DQBLK, 1,
1739 [quotactl_ops.set_dqblk takes struct qc_dqblk])
1740 AC_DEFINE(HAVE_DQUOT_KQID, 1,
1741 [quotactl_ops.set_dqblk takes struct kqid])
1743 EXTRA_KCFLAGS="$tmp_flags"
1744 ]) # LC_HAVE_DQUOT_QC_DQBLK
1747 # LC_BACKING_DEV_INFO_REMOVAL
1749 # 3.20 kernel removed backing_dev_info from address_space
1751 AC_DEFUN([LC_BACKING_DEV_INFO_REMOVAL], [
1752 LB_CHECK_COMPILE([if struct address_space has backing_dev_info],
1754 #include <linux/fs.h>
1756 struct address_space mapping;
1758 mapping.backing_dev_info = NULL;
1760 AC_DEFINE(HAVE_BACKING_DEV_INFO, 1, [backing_dev_info exist])
1762 ]) # LC_BACKING_DEV_INFO_REMOVAL
1765 # LC_HAVE_BDI_CAP_MAP_COPY
1767 # 3.20 removed mmap handling for backing devices since
1768 # it breaks on non-MMU systems. See kernel commit
1769 # b4caecd48005fbed3949dde6c1cb233142fd69e9
1771 AC_DEFUN([LC_HAVE_BDI_CAP_MAP_COPY], [
1772 LB_CHECK_COMPILE([if have 'BDI_CAP_MAP_COPY'],
1774 #include <linux/backing-dev.h>
1776 struct backing_dev_info info;
1778 info.capabilities = BDI_CAP_MAP_COPY;
1780 AC_DEFINE(HAVE_BDI_CAP_MAP_COPY, 1,
1781 [BDI_CAP_MAP_COPY exist])
1783 ]) # LC_HAVE_BDI_CAP_MAP_COPY
1788 # 4.1 kernel has iov_iter_rw
1790 AC_DEFUN([LC_IOV_ITER_RW], [
1791 LB_CHECK_COMPILE([if iov_iter_rw exist],
1793 #include <linux/fs.h>
1794 #include <linux/uio.h>
1796 struct iov_iter *iter = NULL;
1800 AC_DEFINE(HAVE_IOV_ITER_RW, 1,
1801 [iov_iter_rw exist])
1806 # LC_HAVE_SYNC_READ_WRITE
1808 # 4.1 new_sync_[read|write] no longer exported
1810 AC_DEFUN([LC_HAVE_SYNC_READ_WRITE], [
1811 LB_CHECK_EXPORT([new_sync_read], [fs/read_write.c],
1812 [AC_DEFINE(HAVE_SYNC_READ_WRITE, 1,
1813 [new_sync_[read|write] is exported by the kernel])])
1814 ]) # LC_HAVE_SYNC_READ_WRITE
1819 # 4.1 redefined bi_cnt as __bi_cnt in commit dac56212e8127dbc0
1821 AC_DEFUN([LC_HAVE___BI_CNT], [
1822 LB_CHECK_COMPILE([if Linux kernel has __bi_cnt in struct bio],
1824 #include <asm/atomic.h>
1825 #include <linux/bio.h>
1826 #include <linux/blk_types.h>
1828 struct bio bio = { };
1830 cnt = atomic_read(&bio.__bi_cnt);
1832 AC_DEFINE(HAVE___BI_CNT, 1,
1833 [struct bio has __bi_cnt])
1835 ]) # LC_HAVE___BI_CNT
1838 # LC_SYMLINK_OPS_USE_NAMEIDATA
1840 # For the 4.2+ kernels the file system internal symlink api no
1841 # longer uses struct nameidata as a argument
1843 AC_DEFUN([LC_SYMLINK_OPS_USE_NAMEIDATA], [
1844 LB_CHECK_COMPILE([if symlink inode operations have struct nameidata argument],
1845 symlink_use_nameidata, [
1846 #include <linux/namei.h>
1847 #include <linux/fs.h>
1849 struct nameidata *nd = NULL;
1851 ((struct inode_operations *)0)->follow_link(NULL, nd);
1852 ((struct inode_operations *)0)->put_link(NULL, nd, NULL);
1854 AC_DEFINE(HAVE_SYMLINK_OPS_USE_NAMEIDATA, 1,
1855 [symlink inode operations need struct nameidata argument])
1857 ]) # LC_SYMLINK_OPS_USE_NAMEIDATA
1860 # LC_BIO_ENDIO_USES_ONE_ARG
1862 # 4.2 kernel bio_endio now only takes one argument
1864 AC_DEFUN([LC_BIO_ENDIO_USES_ONE_ARG], [
1865 LB_CHECK_COMPILE([if 'bio_endio' with one argument exist],
1867 #include <linux/bio.h>
1871 AC_DEFINE(HAVE_BIO_ENDIO_USES_ONE_ARG, 1,
1872 [bio_endio takes only one argument])
1874 ]) # LC_BIO_ENDIO_USES_ONE_ARG
1877 # LC_HAVE_INTERVAL_EXP_BLK_INTEGRITY
1879 # 4.3 replace interval with interval_exp in 'struct blk_integrity'
1880 # 'struct blk_integrity_profile' is also added in this version,
1881 # thus use this to determine whether 'struct blk_integrity' has profile
1883 AC_DEFUN([LC_HAVE_INTERVAL_EXP_BLK_INTEGRITY], [
1884 LB_CHECK_COMPILE([if 'blk_integrity.interval_exp' exist],
1885 blk_integrity_interval_exp, [
1886 #include <linux/blkdev.h>
1888 ((struct blk_integrity *)0)->interval_exp = 0;
1890 AC_DEFINE(HAVE_INTERVAL_EXP_BLK_INTEGRITY, 1,
1891 [blk_integrity.interval_exp exist])
1893 ]) # LC_HAVE_INTERVAL_EXP_BLK_INTEGRITY
1896 # LC_HAVE_LOOP_CTL_GET_FREE
1898 # 4.x kernel have moved userspace APIs to
1899 # the separate directory and all of them
1900 # support LOOP_CTL_GET_FREE
1902 AC_DEFUN([LC_HAVE_LOOP_CTL_GET_FREE], [
1903 LB_CHECK_FILE([$LINUX/include/linux/loop.h], [
1904 LB_CHECK_COMPILE([if have 'HAVE_LOOP_CTL_GET_FREE'],
1905 LOOP_CTL_GET_FREE, [
1906 #include <linux/loop.h>
1910 i = LOOP_CTL_GET_FREE;
1912 AC_DEFINE(HAVE_LOOP_CTL_GET_FREE, 1,
1913 [LOOP_CTL_GET_FREE exist])
1916 AC_DEFINE(HAVE_LOOP_CTL_GET_FREE, 1,
1917 [kernel has LOOP_CTL_GET_FREE])
1919 ]) # LC_HAVE_LOOP_CTL_GET_FREE
1922 # LC_HAVE_CACHE_HEAD_HLIST
1924 # 4.3 kernel swiched to hlist for cache_head
1926 AC_DEFUN([LC_HAVE_CACHE_HEAD_HLIST], [
1927 LB_CHECK_COMPILE([if 'struct cache_head' has 'cache_list' field],
1928 cache_head_has_hlist, [
1929 #include <linux/sunrpc/cache.h>
1931 do {} while(sizeof(((struct cache_head *)0)->cache_list));
1933 AC_DEFINE(HAVE_CACHE_HEAD_HLIST, 1,
1934 [cache_head has hlist cache_list])
1936 ]) # LC_HAVE_CACHE_HEAD_HLIST
1939 # LC_HAVE_XATTR_HANDLER_SIMPLIFIED
1941 # Kernel version 4.3 commit e409de992e3ea3674393465f07cc71c948edd87a
1942 # simplified xattr_handler handling by passing in the handler pointer
1944 AC_DEFUN([LC_HAVE_XATTR_HANDLER_SIMPLIFIED], [
1945 tmp_flags="$EXTRA_KCFLAGS"
1946 EXTRA_KCFLAGS="-Werror"
1947 LB_CHECK_COMPILE([if 'struct xattr_handler' functions pass in handler pointer],
1948 xattr_handler_simplified, [
1949 #include <linux/xattr.h>
1951 struct xattr_handler handler;
1953 ((struct xattr_handler *)0)->get(&handler, NULL, NULL, NULL, 0);
1954 ((struct xattr_handler *)0)->set(&handler, NULL, NULL, NULL, 0, 0);
1956 AC_DEFINE(HAVE_XATTR_HANDLER_SIMPLIFIED, 1, [handler pointer is parameter])
1958 EXTRA_KCFLAGS="$tmp_flags"
1959 ]) # LC_HAVE_XATTR_HANDLER_SIMPLIFIED
1962 # LC_HAVE_BIP_ITER_BIO_INTEGRITY_PAYLOAD
1964 # 4.3 replace interval with interval_exp in 'struct blk_integrity'.
1966 AC_DEFUN([LC_HAVE_BIP_ITER_BIO_INTEGRITY_PAYLOAD], [
1967 LB_CHECK_COMPILE([if 'bio_integrity_payload.bip_iter' exist],
1968 bio_integrity_payload_bip_iter, [
1969 #include <linux/bio.h>
1971 ((struct bio_integrity_payload *)0)->bip_iter.bi_size = 0;
1973 AC_DEFINE(HAVE_BIP_ITER_BIO_INTEGRITY_PAYLOAD, 1,
1974 [bio_integrity_payload.bip_iter exist])
1976 ]) # LC_HAVE_BIP_ITER_BIO_INTEGRITY_PAYLOAD
1979 # LC_BIO_INTEGRITY_PREP_FN
1981 # Lustre kernel patch extents bio_integrity_prep to accept optional
1982 # generate/verify_fn as extra args.
1984 AC_DEFUN([LC_BIO_INTEGRITY_PREP_FN], [
1985 LB_CHECK_COMPILE([if 'bio_integrity_prep_fn' exists],
1986 bio_integrity_prep_fn, [
1987 #include <linux/bio.h>
1989 bio_integrity_prep_fn(NULL, NULL, NULL);
1991 AC_DEFINE(HAVE_BIO_INTEGRITY_PREP_FN, 1,
1992 [kernel has bio_integrity_prep_fn])
1993 AC_SUBST(PATCHED_INTEGRITY_INTF)
1995 AC_SUBST(PATCHED_INTEGRITY_INTF, [#])
1997 ]) # LC_BIO_INTEGRITY_PREP_FN
2002 # 4.4/4.8 redefined bi_rw as bi_opf (SLES12/kernel commit 4382e33ad37486)
2004 AC_DEFUN([LC_HAVE_BI_OPF], [
2005 LB_CHECK_COMPILE([if Linux kernel has bi_opf in struct bio],
2007 #include <linux/bio.h>
2013 AC_DEFINE(HAVE_BI_OPF, 1,
2014 [struct bio has bi_opf])
2019 # LC_HAVE_SUBMIT_BIO_2ARGS
2021 # 4.4 removed an argument from submit_bio
2023 AC_DEFUN([LC_HAVE_SUBMIT_BIO_2ARGS], [
2024 LB_CHECK_COMPILE([if submit_bio takes two arguments],
2025 have_submit_bio_2args, [
2026 #include <linux/bio.h>
2029 submit_bio(READ, &bio);
2031 AC_DEFINE(HAVE_SUBMIT_BIO_2ARGS, 1,
2032 [submit_bio takes two arguments])
2034 ]) # LC_HAVE_SUBMIT_BIO_2_ARGS
2037 # LC_HAVE_CLEAN_BDEV_ALIASES
2039 # 4.4/4.9 unmap_underlying_metadata was replaced by clean_bdev_aliases
2040 # (SLES12/kernel commit 29f3ad7d8380364c)
2042 AC_DEFUN([LC_HAVE_CLEAN_BDEV_ALIASES], [
2043 LB_CHECK_COMPILE([if kernel has clean_bdev_aliases],
2044 have_clean_bdev_aliases, [
2045 #include <linux/buffer_head.h>
2047 struct block_device bdev;
2048 clean_bdev_aliases(&bdev,1,1);
2050 AC_DEFINE(HAVE_CLEAN_BDEV_ALIASES, 1,
2051 [kernel has clean_bdev_aliases])
2053 ]) # LC_HAVE_CLEAN_BDEV_ALIASES
2056 # LC_HAVE_LOCKS_LOCK_FILE_WAIT
2058 # 4.4 kernel have moved locks API users to
2059 # locks_lock_inode_wait()
2061 AC_DEFUN([LC_HAVE_LOCKS_LOCK_FILE_WAIT], [
2062 LB_CHECK_COMPILE([if 'locks_lock_file_wait' exists],
2063 locks_lock_file_wait, [
2064 #include <linux/fs.h>
2066 locks_lock_file_wait(NULL, NULL);
2068 AC_DEFINE(HAVE_LOCKS_LOCK_FILE_WAIT, 1,
2069 [kernel has locks_lock_file_wait])
2071 ]) # LC_HAVE_LOCKS_LOCK_FILE_WAIT
2074 # LC_HAVE_KEY_PAYLOAD_DATA_ARRAY
2076 # 4.4 kernel merged type-specific data with the payload data for keys
2078 AC_DEFUN([LC_HAVE_KEY_PAYLOAD_DATA_ARRAY], [
2079 LB_CHECK_COMPILE([if 'struct key' has 'payload.data' as an array],
2080 key_payload_data_array, [
2081 #include <linux/key.h>
2083 struct key key = { };
2085 key.payload.data[0] = NULL;
2087 AC_DEFINE(HAVE_KEY_PAYLOAD_DATA_ARRAY, 1, [payload.data is an array])
2089 ]) #LC_HAVE_KEY_PAYLOAD_DATA_ARRAY
2092 # LC_HAVE_XATTR_HANDLER_NAME
2094 # Kernel version 4.4 commit 98e9cb5711c68223f0e4d5201b9a6add255ec550
2095 # add a name member to struct xattr_handler
2097 AC_DEFUN([LC_HAVE_XATTR_HANDLER_NAME], [
2098 tmp_flags="$EXTRA_KCFLAGS"
2099 EXTRA_KCFLAGS="-Werror"
2100 LB_CHECK_COMPILE([if 'struct xattr_handler' has a name member],
2101 xattr_handler_name, [
2102 #include <linux/xattr.h>
2104 ((struct xattr_handler *)NULL)->name = NULL;
2106 AC_DEFINE(HAVE_XATTR_HANDLER_NAME, 1, [xattr_handler has a name member])
2108 EXTRA_KCFLAGS="$tmp_flags"
2109 ]) # LC_HAVE_XATTR_HANDLER_NAME
2112 # LC_HAVE_FILE_DENTRY
2114 # 4.5 adds wrapper file_dentry
2116 AC_DEFUN([LC_HAVE_FILE_DENTRY], [
2117 LB_CHECK_COMPILE([if Linux kernel has 'file_dentry'],
2119 #include <linux/fs.h>
2123 AC_DEFINE(HAVE_FILE_DENTRY, 1,
2124 [kernel has file_dentry])
2126 ]) # LC_HAVE_FILE_DENTRY
2129 # LC_HAVE_INODE_LOCK
2131 # 4.5 introduced inode_lock
2133 AC_DEFUN([LC_HAVE_INODE_LOCK], [
2134 LB_CHECK_COMPILE([if 'inode_lock' is defined],
2136 #include <linux/fs.h>
2140 AC_DEFINE(HAVE_INODE_LOCK, 1,
2141 [inode_lock is defined])
2143 ]) # LC_HAVE_INODE_LOCK
2146 # LC_HAVE_IOP_GET_LINK
2148 # 4.5 vfs replaced iop->follow_link with
2151 AC_DEFUN([LC_HAVE_IOP_GET_LINK], [
2152 LB_CHECK_COMPILE([if 'iop' has 'get_link'],
2153 inode_ops_get_link, [
2154 #include <linux/fs.h>
2156 struct inode_operations iop;
2157 iop.get_link = NULL;
2159 AC_DEFINE(HAVE_IOP_GET_LINK, 1,
2160 [have iop get_link])
2162 ]) # LC_HAVE_IOP_GET_LINK
2165 # LC_HAVE_IN_COMPAT_SYSCALL
2167 # 4.6 renamed is_compat_task to in_compat_syscall
2169 AC_DEFUN([LC_HAVE_IN_COMPAT_SYSCALL], [
2170 LB_CHECK_COMPILE([if 'in_compat_syscall' is defined],
2171 in_compat_syscall, [
2172 #include <linux/compat.h>
2174 in_compat_syscall();
2176 AC_DEFINE(HAVE_IN_COMPAT_SYSCALL, 1,
2177 [have in_compat_syscall])
2179 ]) # LC_HAVE_IN_COMPAT_SYSCALL
2182 # LC_HAVE_XATTR_HANDLER_INODE_PARAM
2184 # Kernel version 4.6 commit b296821a7c42fa58baa17513b2b7b30ae66f3336
2185 # and commit 5930122683dff58f0846b0f0405b4bd598a3ba6a added inode parameter
2186 # to xattr_handler functions
2188 AC_DEFUN([LC_HAVE_XATTR_HANDLER_INODE_PARAM], [
2189 tmp_flags="$EXTRA_KCFLAGS"
2190 EXTRA_KCFLAGS="-Werror"
2191 LB_CHECK_COMPILE([if 'struct xattr_handler' functions have inode parameter],
2192 xattr_handler_inode_param, [
2193 #include <linux/xattr.h>
2195 const struct xattr_handler handler;
2197 ((struct xattr_handler *)0)->get(&handler, NULL, NULL, NULL, NULL, 0);
2198 ((struct xattr_handler *)0)->set(&handler, NULL, NULL, NULL, NULL, 0, 0);
2200 AC_DEFINE(HAVE_XATTR_HANDLER_INODE_PARAM, 1, [needs inode parameter])
2202 EXTRA_KCFLAGS="$tmp_flags"
2203 ]) # LC_HAVE_XATTR_HANDLER_INODE_PARAM
2208 # Kernel version 4.6 commit 85c7f81041d57cfe9dc97f4680d5586b54534a39
2209 # introduced parallel lookups in the VFS layer. The inline function
2210 # d_in_lookup was added to notify when the same item was being queried
2213 AC_DEFUN([LC_D_IN_LOOKUP], [
2214 tmp_flags="$EXTRA_KCFLAGS"
2215 EXTRA_KCFLAGS="-Werror"
2216 LB_CHECK_COMPILE([if 'd_in_lookup' is defined],
2218 #include <linux/dcache.h>
2222 AC_DEFINE(HAVE_D_IN_LOOKUP, 1, [d_in_lookup is defined])
2224 EXTRA_KCFLAGS="$tmp_flags"
2230 # Kernel version 4.7 commit c8b8e32d700fe943a935e435ae251364d016c497
2231 # direct-io: eliminate the offset argument to ->direct_IO
2233 AC_DEFUN([LC_DIRECTIO_2ARGS], [
2234 LB_CHECK_COMPILE([if '->direct_IO()' taken 2 arguments],
2236 #include <linux/fs.h>
2238 struct address_space_operations ops = { };
2239 struct iov_iter *iter = NULL;
2240 struct kiocb *iocb = NULL;
2243 rc = ops.direct_IO(iocb, iter);
2245 AC_DEFINE(HAVE_DIRECTIO_2ARGS, 1,
2246 [direct_IO need 2 arguments])
2248 ]) # LC_DIRECTIO_2ARGS
2251 # LC_GENERIC_WRITE_SYNC_2ARGS
2253 # Kernel version 4.7 commit dde0c2e79848298cc25621ad080d47f94dbd7cce
2254 # fs: add IOCB_SYNC and IOCB_DSYNC
2256 AC_DEFUN([LC_GENERIC_WRITE_SYNC_2ARGS], [
2257 LB_CHECK_COMPILE([if 'generic_write_sync()' taken 2 arguments],
2258 generic_write_sync_2args, [
2259 #include <linux/fs.h>
2261 struct kiocb *iocb = NULL;
2264 rc = generic_write_sync(iocb, 0);
2266 AC_DEFINE(HAVE_GENERIC_WRITE_SYNC_2ARGS, 1,
2267 [generic_write_sync need 2 arguments])
2269 ]) # LC_GENERIC_WRITE_SYNC_2ARGS
2272 # LC_FOP_ITERATE_SHARED
2274 # Kernel version 4.7 adds iterate_shared method to file_operations
2276 AC_DEFUN([LC_FOP_ITERATE_SHARED], [
2277 LB_CHECK_COMPILE([if 'file_operations' has 'iterate_shared'],
2278 fop_iterate_shared, [
2279 #include <linux/fs.h>
2281 struct file_operations fop;
2282 fop.iterate_shared = NULL;
2284 AC_DEFINE(HAVE_FOP_ITERATE_SHARED, 1,
2285 [file_operations has iterate_shared])
2287 ]) # LC_FOP_ITERATE_SHARED
2290 # LC_FOPS_ITERATE_SHARED
2292 # 4.7 commit ae05327a00fd47c34dfe25294b359a3f3fef96e8
2293 # ext4: switch to ->iterate_shared()
2294 # this replaces ext4_dir_operations iterate with iterate_shared.
2295 # dir_relaxed_shared() was also added in this commit, so we can
2296 # use that function to verify that the ext4_dir_operations is using
2299 AC_DEFUN([LC_FOPS_ITERATE_SHARED], [
2300 LB_CHECK_COMPILE([if ext4_dir_operations uses iterate_shared],
2302 #include <linux/fs.h>
2304 ((struct file_operations *)0)->iterate_shared(NULL, NULL);
2305 dir_relax_shared(NULL);
2307 AC_DEFINE(HAVE_ITERATE_SHARED, 1,
2308 ['iterate_shared' is available])
2310 ]) # LC_FOPS_ITERATE_SHARED
2313 # LC_HAVE_POSIX_ACL_VALID_USER_NS
2315 # 4.8 posix_acl_valid takes struct user_namespace
2317 AC_DEFUN([LC_HAVE_POSIX_ACL_VALID_USER_NS], [
2318 LB_CHECK_COMPILE([if 'posix_acl_valid' takes 'struct user_namespace'],
2320 #include <linux/fs.h>
2321 #include <linux/posix_acl.h>
2323 posix_acl_valid((struct user_namespace*)NULL, (const struct posix_acl*)NULL);
2325 AC_DEFINE(HAVE_POSIX_ACL_VALID_USER_NS, 1,
2326 [posix_acl_valid takes struct user_namespace])
2328 ]) # LC_HAVE_POSIX_ACL_VALID_USER_NS
2331 # LC_D_COMPARE_4ARGS
2333 # Kernel version 4.8 commit 6fa67e707559303e086303aeecc9e8b91ef497d5
2334 # get rid of 'parent' argument of ->d_compare()
2336 AC_DEFUN([LC_D_COMPARE_4ARGS], [
2337 LB_CHECK_COMPILE([if 'd_compare' taken 4 arguments],
2339 #include <linux/dcache.h>
2341 ((struct dentry_operations*)0)->d_compare(NULL,0,NULL,NULL);
2343 AC_DEFINE(HAVE_D_COMPARE_4ARGS, 1,
2344 [d_compare need 4 arguments])
2346 ]) # LC_D_COMPARE_4ARGS
2349 # LC_FULL_NAME_HASH_3ARGS
2351 # Kernel version 4.8 commit 8387ff2577eb9ed245df9a39947f66976c6bcd02
2352 # vfs: make the string hashes salt the hash
2354 AC_DEFUN([LC_FULL_NAME_HASH_3ARGS], [
2355 LB_CHECK_COMPILE([if 'full_name_hash' taken 3 arguments],
2356 full_name_hash_3args, [
2357 #include <linux/stringhash.h>
2360 hash = full_name_hash(NULL,NULL,0);
2362 AC_DEFINE(HAVE_FULL_NAME_HASH_3ARGS, 1,
2363 [full_name_hash need 3 arguments])
2365 ]) # LC_FULL_NAME_HASH_3ARGS
2368 # LC_STRUCT_POSIX_ACL_XATTR
2370 # Kernel version 4.8 commit 2211d5ba5c6c4e972ba6dbc912b2897425ea6621
2371 # posix_acl: xattr representation cleanups
2373 AC_DEFUN([LC_STRUCT_POSIX_ACL_XATTR], [
2374 LB_CHECK_COMPILE([if 'struct posix_acl_xattr_{header,entry}' defined],
2375 struct_posix_acl_xattr, [
2376 #include <linux/fs.h>
2377 #include <linux/posix_acl_xattr.h>
2379 struct posix_acl_xattr_header *h = NULL;
2380 struct posix_acl_xattr_entry *e;
2381 e = (void *)(h + 1);
2383 AC_DEFINE(HAVE_STRUCT_POSIX_ACL_XATTR, 1,
2384 [struct posix_acl_xattr_{header,entry} defined])
2386 ]) # LC_STRUCT_POSIX_ACL_XATTR
2391 # Kernel version 4.8 commit fd50ecaddf8372a1d96e0daeaac0f93cf04e4d42
2392 # removed {get,set,remove}xattr inode operations
2394 AC_DEFUN([LC_IOP_XATTR], [
2395 LB_CHECK_COMPILE([if 'inode_operations' has {get,set,remove}xattr members],
2397 #include <linux/fs.h>
2399 struct inode_operations iop;
2400 iop.setxattr = NULL;
2401 iop.getxattr = NULL;
2402 iop.removexattr = NULL;
2404 AC_DEFINE(HAVE_IOP_XATTR, 1,
2405 [inode_operations has {get,set,remove}xattr members])
2412 # Kernel version 4.9 commit 81243eacfa400f5f7b89f4c2323d0de9982bb0fb
2413 # cred: simpler, 1D supplementary groups
2415 AC_DEFUN([LC_GROUP_INFO_GID], [
2416 LB_CHECK_COMPILE([if 'struct group_info' has member 'gid'],
2418 #include <linux/cred.h>
2421 p = ((struct group_info *)0)->gid;
2423 AC_DEFINE(HAVE_GROUP_INFO_GID, 1,
2424 [struct group_info has member gid])
2426 ]) # LC_GROUP_INFO_GID
2431 # Kernel version 4.9 commit 5d6c31910bc0713e37628dc0ce677dcb13c8ccf4
2432 # added __vfs_{get,set,remove}xattr helpers
2434 AC_DEFUN([LC_VFS_SETXATTR], [
2435 LB_CHECK_COMPILE([if '__vfs_setxattr' helper is available],
2437 #include <linux/xattr.h>
2439 __vfs_setxattr(NULL, NULL, NULL, NULL, 0, 0);
2441 AC_DEFINE(HAVE_VFS_SETXATTR, 1,
2442 ['__vfs_setxattr is available])
2444 ]) # LC_VFS_SETXATTR
2447 # LC_POSIX_ACL_UPDATE_MODE
2449 # Kernel version 4.9 commit 073931017b49d9458aa351605b43a7e34598caef
2450 # posix_acl: Clear SGID bit when setting file permissions
2452 AC_DEFUN([LC_POSIX_ACL_UPDATE_MODE], [
2453 LB_CHECK_COMPILE([if 'posix_acl_update_mode' exists],
2454 posix_acl_update_mode, [
2455 #include <linux/fs.h>
2456 #include <linux/posix_acl.h>
2458 posix_acl_update_mode(NULL, NULL, NULL);
2460 AC_DEFINE(HAVE_POSIX_ACL_UPDATE_MODE, 1,
2461 ['posix_acl_update_mode' is available])
2463 ]) # LC_POSIX_ACL_UPDATE_MODE
2466 # LC_IOP_GENERIC_READLINK
2468 # Kernel version 4.10 commit dfeef68862edd7d4bafe68ef7aeb5f658ef24bb5
2469 # removed generic_readlink from individual file systems
2471 AC_DEFUN([LC_IOP_GENERIC_READLINK], [
2472 LB_CHECK_COMPILE([if 'generic_readlink' still exist],
2473 inode_ops_readlink, [
2474 #include <linux/fs.h>
2476 struct inode_operations iop;
2477 iop.readlink = generic_readlink;
2479 AC_DEFINE(HAVE_IOP_GENERIC_READLINK, 1,
2480 [generic_readlink has been removed])
2482 ]) # LC_IOP_GENERIC_READLINK
2485 # LC_HAVE_VM_FAULT_ADDRESS
2487 # Kernel version 4.10 commit 1a29d85eb0f19b7d8271923d8917d7b4f5540b3e
2488 # removed virtual_address field. Need to use address field instead
2490 AC_DEFUN([LC_HAVE_VM_FAULT_ADDRESS], [
2491 LB_CHECK_COMPILE([if 'struct vm_fault' replaced virtual_address with address field],
2493 #include <linux/mm.h>
2495 struct vm_fault vmf;
2498 AC_DEFINE(HAVE_VM_FAULT_ADDRESS, 1,
2499 [virtual_address has been replaced by address field])
2501 ]) # LC_HAVE_VM_FAULT_ADDRESS
2504 # LC_INODEOPS_ENHANCED_GETATTR
2506 # Kernel version 4.11 commit a528d35e8bfcc521d7cb70aaf03e1bd296c8493f
2507 # expanded getattr to be able to get more stat information.
2509 AC_DEFUN([LC_INODEOPS_ENHANCED_GETATTR], [
2510 LB_CHECK_COMPILE([if 'inode_operations' getattr member can gather advance stats],
2512 #include <linux/fs.h>
2516 ((struct inode_operations *)1)->getattr(&path, NULL, 0, 0);
2518 AC_DEFINE(HAVE_INODEOPS_ENHANCED_GETATTR, 1,
2519 [inode_operations .getattr member function can gather advance stats])
2521 ]) # LC_INODEOPS_ENHANCED_GETATTR
2524 # LC_VM_OPERATIONS_REMOVE_VMF_ARG
2526 # Kernel version 4.11 commit 11bac80004499ea59f361ef2a5516c84b6eab675
2527 # removed struct vm_area_struct as an argument for vm_operations since
2528 # in the same kernel version struct vma_area_struct was folded into
2531 AC_DEFUN([LC_VM_OPERATIONS_REMOVE_VMF_ARG], [
2532 LB_CHECK_COMPILE([if 'struct vm_operations' removed struct vm_area_struct],
2533 vm_operations_no_vm_area_struct, [
2534 #include <linux/mm.h>
2536 struct vm_fault vmf;
2538 ((struct vm_operations_struct *)0)->fault(&vmf);
2539 ((struct vm_operations_struct *)0)->page_mkwrite(&vmf);
2541 AC_DEFINE(HAVE_VM_OPS_USE_VM_FAULT_ONLY, 1,
2542 ['struct vm_operations' remove struct vm_area_struct argument])
2544 ]) # LC_VM_OPERATIONS_REMOVE_VMF_ARG
2547 # LC_HAVE_KEY_USAGE_REFCOUNT
2549 # Kernel version 4.11 commit fff292914d3a2f1efd05ca71c2ba72a3c663201e
2550 # converted key.usage from atomic_t to refcount_t.
2552 AC_DEFUN([LC_HAVE_KEY_USAGE_REFCOUNT], [
2553 LB_CHECK_COMPILE([if 'key.usage' is refcount_t],
2554 key_usage_refcount, [
2555 #include <linux/key.h>
2557 struct key key = { };
2559 refcount_read(&key.usage);
2561 AC_DEFINE(HAVE_KEY_USAGE_REFCOUNT, 1, [key.usage is of type refcount_t])
2563 ]) #LC_HAVE_KEY_USAGE_REFCOUNT
2566 # LC_HAVE_CRYPTO_MAX_ALG_NAME_128
2568 # Kernel version 4.11 commit f437a3f477cce402dbec6537b29e9e33962c9f73
2569 # switched CRYPTO_MAX_ALG_NAME from 64 to 128.
2571 AC_DEFUN([LC_HAVE_CRYPTO_MAX_ALG_NAME_128], [
2572 LB_CHECK_COMPILE([if 'CRYPTO_MAX_ALG_NAME' is 128],
2573 crypto_max_alg_name, [
2574 #include <linux/crypto.h>
2576 #if CRYPTO_MAX_ALG_NAME != 128
2580 AC_DEFINE(HAVE_CRYPTO_MAX_ALG_NAME_128, 1,
2581 ['CRYPTO_MAX_ALG_NAME' is 128])
2583 ]) # LC_HAVE_CRYPTO_MAX_ALG_NAME_128
2586 # Kernel version 4.12 commit 47f38c539e9a42344ff5a664942075bd4df93876
2587 # CURRENT_TIME is not 64 bit time safe so it was replaced with
2590 AC_DEFUN([LC_CURRENT_TIME], [
2591 LB_CHECK_COMPILE([if CURRENT_TIME has been replaced with current_time],
2593 #include <linux/fs.h>
2597 attr.ia_atime = current_time(NULL);
2599 AC_DEFINE(HAVE_CURRENT_TIME, 1,
2600 [current_time() has replaced CURRENT_TIME])
2602 ]) # LIBCFS_CURRENT_TIME
2605 # Kernel version 4.12-rc3 85787090a21eb749d8b347eaf9ff1a455637473c
2606 # changed struct super_block s_uuid into a proper uuid_t
2608 AC_DEFUN([LC_SUPER_BLOCK_S_UUID], [
2609 LB_CHECK_COMPILE([if 'struct super_block' s_uuid is uuid_t],
2610 super_block_s_uuid, [
2611 #include <linux/fs.h>
2613 struct super_block sb;
2615 uuid_parse(NULL, &sb.s_uuid);
2617 AC_DEFINE(HAVE_S_UUID_AS_UUID_T, 1, ['s_uuid' is an uuid_t])
2619 ]) # LC_SUPER_BLOCK_S_UUID
2622 # LC_SUPER_SETUP_BDI_NAME
2624 # Kernel version 4.12 commit 9594caf216dc0fe3e318b34af0127276db661241
2625 # unified bdi handling
2627 AC_DEFUN([LC_SUPER_SETUP_BDI_NAME], [
2628 LB_CHECK_COMPILE([if 'super_setup_bdi_name' exist],
2629 super_setup_bdi_name, [
2630 #include <linux/fs.h>
2632 super_setup_bdi_name(NULL, "lustre");
2634 AC_DEFINE(HAVE_SUPER_SETUP_BDI_NAME, 1,
2635 ['super_setup_bdi_name' is available])
2637 ]) # LC_SUPER_SETUP_BDI_NAME
2642 # 4.12 replace bi_error to bi_status
2644 AC_DEFUN([LC_BI_STATUS], [
2645 LB_CHECK_COMPILE([if 'bi_status' exist],
2647 #include <linux/blk_types.h>
2649 ((struct bio *)0)->bi_status = 0;
2651 AC_DEFINE(HAVE_BI_STATUS, 1,
2652 ['bi_status' is available])
2657 # LC_UAPI_LINUX_MOUNT_H
2659 # kernel 4.20 commit e262e32d6bde0f77fb0c95d977482fc872c51996
2660 # vfs: Suppress MS_* flag defs within the kernel ...
2662 AC_DEFUN([LC_UAPI_LINUX_MOUNT_H], [
2663 tmp_flags="$EXTRA_KCFLAGS"
2664 EXTRA_KCFLAGS="-Werror"
2665 LB_CHECK_COMPILE([if MS_RDONLY was moved to uapi/linux/mount.h],
2667 #include <uapi/linux/mount.h>
2672 AC_DEFINE(HAVE_UAPI_LINUX_MOUNT_H, 1,
2673 [if MS_RDONLY was moved to uapi/linux/mount.h])
2675 EXTRA_KCFLAGS="$tmp_flags"
2676 ]) # LC_UAPI_LINUX_MOUNT_H
2679 # LC_HAVE_SUNRPC_CACHE_HASH_LOCK_IS_A_SPINLOCK
2681 # kernel 4.20 commit 1863d77f15da0addcd293a1719fa5d3ef8cde3ca
2682 # SUNRPC: Replace the cache_detail->hash_lock with a regular spinlock
2684 # Now that the reader functions are all RCU protected, use a regular
2685 # spinlock rather than a reader/writer lock.
2687 AC_DEFUN([LC_HAVE_SUNRPC_CACHE_HASH_LOCK_IS_A_SPINLOCK], [
2688 tmp_flags="$EXTRA_KCFLAGS"
2689 EXTRA_KCFLAGS="-Werror"
2690 LB_CHECK_COMPILE([if cache_detail->hash_lock is a spinlock],
2691 hash_lock_isa_spinlock_t, [
2692 #include <linux/sunrpc/cache.h>
2694 spinlock_t *lock = &(((struct cache_detail *)0)->hash_lock);
2697 AC_DEFINE(HAVE_CACHE_HASH_SPINLOCK, 1,
2698 [if cache_detail->hash_lock is a spinlock])
2700 EXTRA_KCFLAGS="$tmp_flags"
2701 ]) # LC_HAVE_SUNRPC_CACHE_HASH_LOCK_IS_A_SPINLOCK
2704 # LC_BIO_INTEGRITY_ENABLED
2706 # 4.13 removed bio_integrity_enabled
2708 AC_DEFUN([LC_BIO_INTEGRITY_ENABLED], [
2709 LB_CHECK_COMPILE([if 'bio_integrity_enabled' exist],
2710 bio_integrity_enabled, [
2711 #include <linux/bio.h>
2713 bio_integrity_enabled(NULL);
2715 AC_DEFINE(HAVE_BIO_INTEGRITY_ENABLED, 1,
2716 ['bio_integrity_enabled' is available])
2718 ]) # LC_BIO_INTEGRITY_ENABLED
2721 # LC_PAGEVEC_INIT_ONE_PARAM
2723 # 4.14 pagevec_init takes one parameter
2725 AC_DEFUN([LC_PAGEVEC_INIT_ONE_PARAM], [
2726 LB_CHECK_COMPILE([if 'pagevec_init' takes one parameter],
2728 #include <linux/pagevec.h>
2732 AC_DEFINE(HAVE_PAGEVEC_INIT_ONE_PARAM, 1,
2733 ['pagevec_init' takes one parameter])
2735 ]) # LC_PAGEVEC_INIT_ONE_PARAM
2740 # 4.14 replaced bi_bdev to bi_disk
2742 AC_DEFUN([LC_BI_BDEV], [
2743 LB_CHECK_COMPILE([if 'bi_bdev' exist],
2745 #include <linux/bio.h>
2747 ((struct bio *)0)->bi_bdev = NULL;
2749 AC_DEFINE(HAVE_BI_BDEV, 1,
2750 ['bi_bdev' is available])
2757 # kernel 4.17 commit b93b016313b3ba8003c3b8bb71f569af91f19fc7
2759 AC_DEFUN([LC_I_PAGES], [
2760 LB_CHECK_COMPILE([if struct address_space has i_pages],
2762 #include <linux/fs.h>
2764 struct address_space mapping = {};
2767 i_pages = &mapping.i_pages;
2769 AC_DEFINE(HAVE_I_PAGES, 1,
2770 [struct address_space has i_pages])
2777 # kernel 4.17 commit 3d3539018d2cbd12e5af4a132636ee7fd8d43ef0
2778 # mm: create the new vm_fault_t type
2780 AC_DEFUN([LC_VM_FAULT_T], [
2781 LB_CHECK_COMPILE([if vm_fault_t type exists],
2783 #include <linux/mm_types.h>
2785 vm_fault_t x = VM_FAULT_SIGBUS;
2788 AC_DEFINE(HAVE_VM_FAULT_T, 1,
2789 [if vm_fault_t type exists])
2794 # LC_INODE_TIMESPEC64
2796 # kernel 4.17-rc7 commit 8efd6894ff089adeeac7cb9f32125b85d963d1bc
2797 # fs: add timespec64_truncate()
2798 # kernel 4.18 commit 95582b00838837fc07e042979320caf917ce3fe6
2799 # inode timestamps switched to timespec64
2800 # kernel 4.19-rc2 commit 976516404ff3fab2a8caa8bd6f5efc1437fed0b8
2801 # y2038: remove unused time interfaces
2805 # When inode times are timespec64 stop using the deprecated
2808 AC_DEFUN([LC_INODE_TIMESPEC64], [
2809 tmp_flags="$EXTRA_KCFLAGS"
2810 EXTRA_KCFLAGS="-Werror"
2811 LB_CHECK_COMPILE([if inode timestamps are struct timespec64],
2813 #include <linux/fs.h>
2815 struct inode inode = {};
2816 struct timespec64 ts = {};
2818 inode.i_atime = timespec64_trunc(ts, 1);
2821 AC_DEFINE(HAVE_INODE_TIMESPEC64, 1,
2822 [inode times are using timespec64])
2824 EXTRA_KCFLAGS="$tmp_flags"
2825 ]) # LC_INODE_TIMESPEC64
2828 # LC_HAS_LINUX_SELINUX_ENABLED
2830 # kernel 5.1 commit 3d252529480c68bfd6a6774652df7c8968b28e41
2831 # SELinux: Remove unused selinux_is_enabled
2833 AC_DEFUN([LC_HAS_LINUX_SELINUX_ENABLED], [
2834 tmp_flags="$EXTRA_KCFLAGS"
2835 EXTRA_KCFLAGS="-Werror"
2836 LB_CHECK_COMPILE([if linux/selinux.h exists],
2837 selinux_is_enabled, [
2838 #include <linux/selinux.h>
2840 bool has_selinux = selinux_is_enabled();
2843 AC_DEFINE(HAVE_LINUX_SELINUX_IS_ENABLED, 1,
2844 [if linux/selinux.h exists])
2846 EXTRA_KCFLAGS="$tmp_flags"
2847 ]) # LC_HAS_LINUX_SELINUX_ENABLED
2850 # LC_BIO_BI_PHYS_SEGMENTS
2852 # kernel 5.3-rc1 commit 14ccb66b3f585b2bc21e7256c96090abed5a512c
2853 # block: remove the bi_phys_segments field in struct bio
2855 AC_DEFUN([LC_BIO_BI_PHYS_SEGMENTS], [
2856 tmp_flags="$EXTRA_KCFLAGS"
2857 EXTRA_KCFLAGS="-Werror"
2858 LB_CHECK_COMPILE([if struct bio has bi_phys_segments member],
2859 bye_bio_bi_phys_segments, [
2860 #include <linux/bio.h>
2862 struct bio *bio = NULL;
2863 bio->bi_phys_segments++;
2865 AC_DEFINE(HAVE_BIO_BI_PHYS_SEGMENTS, 1,
2866 [struct bio has bi_phys_segments member])
2868 EXTRA_KCFLAGS="$tmp_flags"
2869 ]) # LC_BIO_BI_PHYS_SEGMENTS
2872 # LC_LM_COMPARE_OWNER_EXISTS
2874 # kernel 5.3-rc3 commit f85d93385e9fe6886a751f647f6812a89bf6bee3
2875 # locks: Cleanup lm_compare_owner and lm_owner_key
2876 # removed lm_compare_owner
2878 AC_DEFUN([LC_LM_COMPARE_OWNER_EXISTS], [
2879 tmp_flags="$EXTRA_KCFLAGS"
2880 EXTRA_KCFLAGS="-Werror"
2881 LB_CHECK_COMPILE([if lock_manager_operations has lm_compare_owner],
2882 lock_manager_ops_lm_compare_owner, [
2883 #include <linux/fs.h>
2885 struct lock_manager_operations lm_ops;
2886 lm_ops.lm_compare_owner = NULL;
2888 AC_DEFINE(HAVE_LM_COMPARE_OWNER, 1,
2889 [lock_manager_operations has lm_compare_owner])
2891 EXTRA_KCFLAGS="$tmp_flags"
2892 ]) # LC_LM_COMPARE_OWNER_EXISTS
2897 # Lustre linux kernel checks
2899 AC_DEFUN([LC_PROG_LINUX], [
2900 AC_MSG_NOTICE([Lustre kernel checks
2901 ==============================================================================])
2906 LC_CONFIG_HEALTH_CHECK_WRITE
2907 LC_CONFIG_LRU_RESIZE
2909 LC_GLIBC_SUPPORT_FHANDLES
2915 LC_HAVE_FHANDLE_SYSCALLS
2916 LC_HAVE_FSTYPE_MOUNT
2917 LC_HAVE_INODE_OWNER_OR_CAPABLE
2918 LC_HAVE_SECURITY_IINITSEC
2919 LC_VFS_CREATE_USE_NAMEIDATA
2922 LC_DIRTY_INODE_WITH_FLAG
2926 LC_LM_XXX_LOCK_MANAGER_OPS
2930 LC_INODE_PERMISION_2ARGS
2931 LC_RADIX_EXCEPTION_ENTRY
2932 LC_HAVE_LOOP_CTL_GET_FREE
2935 LC_HAVE_PROTECT_I_NLINK
2938 LC_HAVE_MIGRATE_HEADER
2939 LC_MIGRATEPAGE_4ARGS
2940 LC_SUPEROPS_USE_DENTRY
2941 LC_INODEOPS_USE_UMODE_T
2942 LC_HAVE_CACHE_REGISTER
2946 LC_KMAP_ATOMIC_HAS_1ARG
2950 LC_HAVE_ENCODE_FH_PARENT
2951 LC_FILE_LLSEEK_SIZE_5ARG
2954 LC_DATA_FOR_LLITE_IS_LIST
2955 LC_DENTRY_OPEN_USE_PATH
2956 LC_HAVE_IOP_ATOMIC_OPEN
2957 LC_HAVE_SB_START_WRITE
2960 LC_HAVE_POSIXACL_USER_NS
2963 LC_HAVE_FILE_F_INODE
2965 LC_HAVE_SUNRPC_UPCALL_HAS_3ARGS
2968 LC_HAVE_HLIST_FOR_EACH_3ARG
2969 LC_HAVE_BIO_END_SECTOR
2971 LC_HAVE_VFS_GETATTR_2ARGS
2974 LC_HAVE_REMOVE_PROC_SUBTREE
2976 LC_HAVE_PROJECT_QUOTA
2977 LC_HAVE_SECURITY_DENTRY_INIT_SECURITY
2978 LC_HAVE_SECURITY_INODE_LISTSECURITY
2985 LC_HAVE_DENTRY_D_U_D_ALIAS
2986 LC_HAVE_DENTRY_D_CHILD
2987 LC_PID_NS_FOR_CHILDREN
2990 LC_OLDSIZE_TRUNCATE_PAGECACHE
2991 LC_PTR_ERR_OR_ZERO_MISSING
2993 LC_INIT_LIST_HEAD_RCU
2998 LC_HAVE_D_IS_POSITIVE
3002 LC_HAVE_TRUNCATE_IPAGES_FINAL
3003 LC_IOPS_RENAME_WITH_FLAGS
3010 LC_DIRECTIO_USE_ITER
3011 LC_HAVE_IOV_ITER_INIT_DIRECTION
3012 LC_HAVE_IOV_ITER_TRUNCATE
3013 LC_HAVE_FILE_OPERATIONS_READ_WRITE_ITER
3016 LC_HAVE_INTERVAL_BLK_INTEGRITY
3020 LC_PERCPU_COUNTER_INIT
3021 LC_NFS_FILLDIR_USE_CTX
3025 LC_HAVE_DQUOT_QC_DQBLK
3028 LC_BACKING_DEV_INFO_REMOVAL
3029 LC_HAVE_BDI_CAP_MAP_COPY
3033 LC_HAVE_SYNC_READ_WRITE
3037 LC_BIO_ENDIO_USES_ONE_ARG
3038 LC_SYMLINK_OPS_USE_NAMEIDATA
3041 LC_HAVE_INTERVAL_EXP_BLK_INTEGRITY
3042 LC_HAVE_BIP_ITER_BIO_INTEGRITY_PAYLOAD
3043 LC_HAVE_CACHE_HEAD_HLIST
3044 LC_HAVE_XATTR_HANDLER_SIMPLIFIED
3047 LC_HAVE_LOCKS_LOCK_FILE_WAIT
3048 LC_HAVE_KEY_PAYLOAD_DATA_ARRAY
3049 LC_HAVE_XATTR_HANDLER_NAME
3051 LC_HAVE_SUBMIT_BIO_2ARGS
3052 LC_HAVE_CLEAN_BDEV_ALIASES
3059 LC_HAVE_IOP_GET_LINK
3062 LC_HAVE_IN_COMPAT_SYSCALL
3063 LC_HAVE_XATTR_HANDLER_INODE_PARAM
3068 LC_GENERIC_WRITE_SYNC_2ARGS
3069 LC_FOPS_ITERATE_SHARED
3072 LC_HAVE_POSIX_ACL_VALID_USER_NS
3074 LC_FULL_NAME_HASH_3ARGS
3075 LC_STRUCT_POSIX_ACL_XATTR
3081 LC_POSIX_ACL_UPDATE_MODE
3084 LC_IOP_GENERIC_READLINK
3085 LC_HAVE_VM_FAULT_ADDRESS
3088 LC_INODEOPS_ENHANCED_GETATTR
3089 LC_VM_OPERATIONS_REMOVE_VMF_ARG
3090 LC_HAVE_KEY_USAGE_REFCOUNT
3091 LC_HAVE_CRYPTO_MAX_ALG_NAME_128
3095 LC_SUPER_BLOCK_S_UUID
3096 LC_SUPER_SETUP_BDI_NAME
3100 LC_BIO_INTEGRITY_ENABLED
3103 LC_PAGEVEC_INIT_ONE_PARAM
3114 LC_HAVE_SUNRPC_CACHE_HASH_LOCK_IS_A_SPINLOCK
3117 LC_UAPI_LINUX_MOUNT_H
3120 LC_HAS_LINUX_SELINUX_ENABLED
3123 LC_BIO_BI_PHYS_SEGMENTS
3124 LC_LM_COMPARE_OWNER_EXISTS
3126 # kernel patch to extend integrity interface
3127 LC_BIO_INTEGRITY_PREP_FN
3130 AS_IF([test "x$enable_server" != xno], [
3140 # Check whether to build the client side of Lustre
3142 AC_DEFUN([LC_CONFIG_CLIENT], [
3143 AC_MSG_CHECKING([whether to build Lustre client support])
3144 AC_ARG_ENABLE([client],
3145 AC_HELP_STRING([--disable-client],
3146 [disable Lustre client support]),
3147 [], [enable_client="yes"])
3148 AC_MSG_RESULT([$enable_client])
3149 ]) # LC_CONFIG_CLIENT
3154 AC_DEFUN([LB_CONFIG_MPITESTS], [
3155 AC_ARG_ENABLE([mpitests],
3156 AC_HELP_STRING([--enable-mpitests=<yes|no|mpicc wrapper>],
3157 [include mpi tests]), [
3158 enable_mpitests="yes"
3161 MPICC_WRAPPER="mpicc"
3162 MPI_BIN=$(eval which $MPICC_WRAPPER | xargs dirname)
3165 enable_mpitests="no"
3169 MPICC_WRAPPER=$enableval
3170 MPI_BIN=$(eval echo $MPICC_WRAPPER | xargs dirname)
3174 enable_mpitests="yes"
3175 MPICC_WRAPPER="mpicc"
3176 MPI_BIN=$(eval which $MPICC_WRAPPER | xargs dirname)
3179 if test "x$enable_mpitests" != "xno"; then
3182 AC_CACHE_CHECK([whether mpitests can be built],
3183 lb_cv_mpi_tests, [AC_COMPILE_IFELSE([AC_LANG_SOURCE([
3187 MPI_Initialized(&flag);
3190 ])], [lb_cv_mpi_tests="yes"], [lb_cv_mpi_tests="no"])
3192 enable_mpitests=$lb_cv_mpi_tests
3196 AC_SUBST(MPICC_WRAPPER)
3197 ]) # LB_CONFIG_MPITESTS
3202 # whether to enable quota support global control
3204 AC_DEFUN([LC_CONFIG_QUOTA], [
3205 AC_MSG_CHECKING([whether to enable quota support global control])
3206 AC_ARG_ENABLE([quota],
3207 AC_HELP_STRING([--enable-quota],
3208 [enable quota support]),
3209 [], [enable_quota="yes"])
3210 AS_IF([test "x$enable_quota" = xyes],
3211 [AC_MSG_RESULT([yes])],
3212 [AC_MSG_RESULT([no])])
3213 ]) # LC_CONFIG_QUOTA
3218 AC_DEFUN([LC_QUOTA], [
3222 AS_IF([test "x$enable_quota" != xno -a "x$enable_utils" != xno], [
3223 AC_CHECK_HEADER([sys/quota.h],
3224 [AC_DEFINE(HAVE_SYS_QUOTA_H, 1,
3225 [Define to 1 if you have <sys/quota.h>.])],
3226 [AC_MSG_ERROR([don't find <sys/quota.h> in your system])])
3233 # configure support for optional OSD implementation
3235 AC_DEFUN([LC_OSD_ADDON], [
3236 AC_MSG_CHECKING([whether to use OSD addon])
3238 AC_HELP_STRING([--with-osd=path],
3239 [set path to optional osd]),
3246 OSDADDON="$with_osd"
3253 AS_IF([test $ENABLEOSDADDON -eq 0], [
3257 OSDMODNAME=$(basename $OSDADDON)
3258 AS_IF([test -e $LUSTRE/$OSDMODNAME], [
3259 AC_MSG_RESULT([can't link])
3261 ], [ln -s $OSDADDON $LUSTRE/$OSDMODNAME], [
3262 AC_MSG_RESULT([$OSDMODNAME])
3263 OSDADDON="obj-m += $OSDMODNAME/"
3265 AC_MSG_RESULT([can't link])
3275 # other configure checks
3277 AC_DEFUN([LC_CONFIGURE], [
3278 AC_MSG_NOTICE([Lustre core checks
3279 ==============================================================================])
3281 AS_IF([test $target_cpu == "i686" -o $target_cpu == "x86_64"],
3282 [CFLAGS="$CFLAGS -Wall -Werror"])
3284 # maximum MDS thread count
3287 # lustre/utils/gss/gss_util.c
3288 # lustre/utils/gss/gssd_proc.c
3289 # lustre/utils/gss/krb5_util.c
3290 # lustre/utils/llog_reader.c
3291 # lustre/utils/create_iam.c
3292 # lustre/utils/libiam.c
3293 AC_CHECK_HEADERS([netdb.h endian.h])
3294 AC_CHECK_FUNCS([gethostbyname])
3296 # lustre/utils/llverfs.c
3297 AC_CHECK_HEADERS([ext2fs/ext2fs.h])
3299 # lustre/utils/lfs.c
3300 AS_IF([test "$enable_dist" = "no"], [
3301 AC_CHECK_LIB([z], [crc32], [
3302 AC_CHECK_HEADER([zlib.h], [], [
3303 AC_MSG_ERROR([zlib.h not found.])])
3306 zlib library not found. Please install zlib development package.])
3312 AC_CHECK_LIB([selinux], [is_selinux_enabled],
3313 [AC_CHECK_HEADERS([selinux/selinux.h],
3314 [SELINUX="-lselinux"
3315 AC_DEFINE([HAVE_SELINUX], 1,
3316 [support for selinux ])],
3319 No libselinux-devel package found, unable to build selinux enabled tools
3324 No selinux package found, unable to build selinux enabled tools
3330 AC_MSG_CHECKING([whether to report minimum OST free space])
3331 AC_ARG_ENABLE([mindf],
3332 AC_HELP_STRING([--enable-mindf],
3333 [Make statfs report the minimum available space on any single OST instead of the sum of free space on all OSTs]),
3334 [], [enable_mindf="no"])
3335 AC_MSG_RESULT([$enable_mindf])
3336 AS_IF([test "$enable_mindf" = "yes"],
3337 [AC_DEFINE([MIN_DF], 1, [Report minimum OST free space])])
3339 AC_MSG_CHECKING([whether to randomly failing memory alloc])
3340 AC_ARG_ENABLE([fail_alloc],
3341 AC_HELP_STRING([--disable-fail-alloc],
3342 [disable randomly alloc failure]),
3343 [], [enable_fail_alloc="yes"])
3344 AC_MSG_RESULT([$enable_fail_alloc])
3345 AS_IF([test "x$enable_fail_alloc" != xno],
3346 [AC_DEFINE([RANDOM_FAIL_ALLOC], 1,
3347 [enable randomly alloc failure])])
3349 AC_MSG_CHECKING([whether to check invariants (expensive cpu-wise)])
3350 AC_ARG_ENABLE([invariants],
3351 AC_HELP_STRING([--enable-invariants],
3352 [enable invariant checking (cpu intensive)]),
3353 [], [enable_invariants="no"])
3354 AC_MSG_RESULT([$enable_invariants])
3355 AS_IF([test "x$enable_invariants" = xyes],
3356 [AC_DEFINE([CONFIG_LUSTRE_DEBUG_EXPENSIVE_CHECK], 1,
3357 [enable invariant checking])])
3359 AC_MSG_CHECKING([whether to track references with lu_ref])
3360 AC_ARG_ENABLE([lu_ref],
3361 AC_HELP_STRING([--enable-lu_ref],
3362 [enable lu_ref reference tracking code]),
3363 [], [enable_lu_ref="no"])
3364 AC_MSG_RESULT([$enable_lu_ref])
3365 AS_IF([test "x$enable_lu_ref" = xyes],
3366 [AC_DEFINE([USE_LU_REF], 1,
3367 [enable lu_ref reference tracking code])])
3369 AC_MSG_CHECKING([whether to enable page state tracking])
3370 AC_ARG_ENABLE([pgstate-track],
3371 AC_HELP_STRING([--enable-pgstate-track],
3372 [enable page state tracking]),
3373 [], [enable_pgstat_track="no"])
3374 AC_MSG_RESULT([$enable_pgstat_track])
3375 AS_IF([test "x$enable_pgstat_track" = xyes],
3376 [AC_DEFINE([CONFIG_DEBUG_PAGESTATE_TRACKING], 1,
3377 [enable page state tracking code])])
3380 AC_MSG_CHECKING([systemd unit file directory])
3381 AC_ARG_WITH([systemdsystemunitdir],
3382 [AS_HELP_STRING([--with-systemdsystemunitdir=DIR],
3383 [Directory for systemd service files])],
3384 [], [with_systemdsystemunitdir=auto])
3385 AS_IF([test "x$with_systemdsystemunitdir" = "xyes" -o "x$with_systemdsystemunitdir" = "xauto"],
3386 [def_systemdsystemunitdir=$($PKG_CONFIG --variable=systemdsystemunitdir systemd)
3387 AS_IF([test "x$def_systemdsystemunitdir" = "x"],
3388 [AS_IF([test "x$with_systemdsystemunitdir" = "xyes"],
3389 [AC_MSG_ERROR([systemd support requested but pkg-config unable to query systemd package])])
3390 with_systemdsystemunitdir=no],
3391 [with_systemdsystemunitdir="$def_systemdsystemunitdir"])])
3392 AS_IF([test "x$with_systemdsystemunitdir" != "xno"],
3393 [AC_SUBST([systemdsystemunitdir], [$with_systemdsystemunitdir])])
3394 AC_MSG_RESULT([$with_systemdsystemunitdir])
3400 # AM_CONDITIONALS for lustre
3402 AC_DEFUN([LC_CONDITIONALS], [
3403 AM_CONDITIONAL(MPITESTS, test x$enable_mpitests = xyes, Build MPI Tests)
3404 AM_CONDITIONAL(CLIENT, test x$enable_client = xyes)
3405 AM_CONDITIONAL(SERVER, test x$enable_server = xyes)
3406 AM_CONDITIONAL(SPLIT, test x$enable_split = xyes)
3407 AM_CONDITIONAL(EXT2FS_DEVEL, test x$ac_cv_header_ext2fs_ext2fs_h = xyes)
3408 AM_CONDITIONAL(GSS, test x$enable_gss = xyes)
3409 AM_CONDITIONAL(GSS_KEYRING, test x$enable_gss_keyring = xyes)
3410 AM_CONDITIONAL(GSS_PIPEFS, test x$enable_gss_pipefs = xyes)
3411 AM_CONDITIONAL(GSS_SSK, test x$enable_ssk = xyes)
3412 AM_CONDITIONAL(LIBPTHREAD, test x$enable_libpthread = xyes)
3413 AM_CONDITIONAL(HAVE_SYSTEMD, test "x$with_systemdsystemunitdir" != "xno")
3414 AM_CONDITIONAL(XATTR_HANDLER, test "x$lb_cv_compile_xattr_handler_flags" = xyes)
3415 AM_CONDITIONAL(SELINUX, test "$SELINUX" = "-lselinux")
3416 AM_CONDITIONAL(GETSEPOL, test x$enable_getsepol = xyes)
3417 ]) # LC_CONDITIONALS
3422 # files that should be generated with AC_OUTPUT
3424 AC_DEFUN([LC_CONFIG_FILES],
3428 lustre/autoconf/Makefile
3429 lustre/conf/Makefile
3430 lustre/conf/resource/Makefile
3431 lustre/contrib/Makefile
3433 lustre/include/Makefile
3434 lustre/include/lustre/Makefile
3435 lustre/include/uapi/linux/lustre/Makefile
3436 lustre/kernel_patches/targets/4.18-rhel8.target
3437 lustre/kernel_patches/targets/3.10-rhel7.7.target
3438 lustre/kernel_patches/targets/3.10-rhel7.6.target
3439 lustre/kernel_patches/targets/3.10-rhel7.5.target
3440 lustre/kernel_patches/targets/4.14-rhel7.5.target
3441 lustre/kernel_patches/targets/4.14-rhel7.6.target
3442 lustre/kernel_patches/targets/3.0-sles11.target
3443 lustre/kernel_patches/targets/3.0-sles11sp3.target
3444 lustre/kernel_patches/targets/3.0-sles11sp4.target
3445 lustre/kernel_patches/targets/3.12-sles12.target
3446 lustre/kernel_patches/targets/4.4-sles12.target
3447 lustre/kernel_patches/targets/4.4-sles12sp3.target
3448 lustre/kernel_patches/targets/4.12-sles12sp4.target
3449 lustre/kernel_patches/targets/3.x-fc18.target
3450 lustre/ldlm/Makefile
3452 lustre/fid/autoMakefile
3453 lustre/llite/Makefile
3454 lustre/llite/autoMakefile
3456 lustre/lov/autoMakefile
3458 lustre/mdc/autoMakefile
3460 lustre/lmv/autoMakefile
3461 lustre/lfsck/Makefile
3462 lustre/lfsck/autoMakefile
3464 lustre/mdt/autoMakefile
3466 lustre/mdd/autoMakefile
3468 lustre/fld/autoMakefile
3469 lustre/obdclass/Makefile
3470 lustre/obdclass/autoMakefile
3471 lustre/obdecho/Makefile
3472 lustre/obdecho/autoMakefile
3474 lustre/ofd/autoMakefile
3476 lustre/osc/autoMakefile
3478 lustre/ost/autoMakefile
3479 lustre/osd-ldiskfs/Makefile
3480 lustre/osd-ldiskfs/autoMakefile
3481 lustre/osd-zfs/Makefile
3482 lustre/osd-zfs/autoMakefile
3484 lustre/mgc/autoMakefile
3486 lustre/mgs/autoMakefile
3487 lustre/target/Makefile
3488 lustre/ptlrpc/Makefile
3489 lustre/ptlrpc/autoMakefile
3490 lustre/ptlrpc/gss/Makefile
3491 lustre/ptlrpc/gss/autoMakefile
3492 lustre/quota/Makefile
3493 lustre/quota/autoMakefile
3494 lustre/scripts/Makefile
3495 lustre/scripts/systemd/Makefile
3496 lustre/tests/Makefile
3497 lustre/tests/mpi/Makefile
3498 lustre/tests/kernel/Makefile
3499 lustre/tests/kernel/autoMakefile
3500 lustre/utils/Makefile
3501 lustre/utils/gss/Makefile
3503 lustre/osp/autoMakefile
3505 lustre/lod/autoMakefile
3507 ]) # LC_CONFIG_FILES