]> git.proxmox.com Git - mirror_zfs-debian.git/blob - config/kernel-create-nameidata.m4
New upstream version 0.7.9
[mirror_zfs-debian.git] / config / kernel-create-nameidata.m4
1 dnl #
2 dnl # 3.6 API change
3 dnl #
4 AC_DEFUN([ZFS_AC_KERNEL_CREATE_NAMEIDATA], [
5 AC_MSG_CHECKING([whether iops->create() passes nameidata])
6 ZFS_LINUX_TRY_COMPILE([
7 #include <linux/fs.h>
8 #include <linux/sched.h>
9
10 #ifdef HAVE_MKDIR_UMODE_T
11 int inode_create(struct inode *inode ,struct dentry *dentry,
12 umode_t umode, struct nameidata *nidata) { return 0; }
13 #else
14 int inode_create(struct inode *inode,struct dentry *dentry,
15 int umode, struct nameidata * nidata) { return 0; }
16 #endif
17
18 static const struct inode_operations
19 iops __attribute__ ((unused)) = {
20 .create = inode_create,
21 };
22 ],[
23 ],[
24 AC_MSG_RESULT(yes)
25 AC_DEFINE(HAVE_CREATE_NAMEIDATA, 1,
26 [iops->create() passes nameidata])
27 ],[
28 AC_MSG_RESULT(no)
29 ])
30 ])