2012-10-12 15:20:58 +00:00
|
|
|
dnl #
|
|
|
|
dnl # 3.6 API change
|
|
|
|
dnl #
|
|
|
|
AC_DEFUN([ZFS_AC_KERNEL_CREATE_NAMEIDATA], [
|
2015-07-15 17:54:26 +00:00
|
|
|
AC_MSG_CHECKING([whether iops->create() passes nameidata])
|
2012-10-12 15:20:58 +00:00
|
|
|
ZFS_LINUX_TRY_COMPILE([
|
|
|
|
#include <linux/fs.h>
|
2013-02-14 23:54:04 +00:00
|
|
|
|
2012-10-12 15:20:58 +00:00
|
|
|
#ifdef HAVE_MKDIR_UMODE_T
|
2013-02-14 23:54:04 +00:00
|
|
|
int inode_create(struct inode *inode ,struct dentry *dentry,
|
|
|
|
umode_t umode, struct nameidata *nidata) { return 0; }
|
2012-10-12 15:20:58 +00:00
|
|
|
#else
|
2013-02-14 23:54:04 +00:00
|
|
|
int inode_create(struct inode *inode,struct dentry *dentry,
|
|
|
|
int umode, struct nameidata * nidata) { return 0; }
|
2012-10-12 15:20:58 +00:00
|
|
|
#endif
|
2013-02-14 23:54:04 +00:00
|
|
|
|
|
|
|
static const struct inode_operations
|
|
|
|
iops __attribute__ ((unused)) = {
|
2012-10-12 15:20:58 +00:00
|
|
|
.create = inode_create,
|
|
|
|
};
|
2013-02-14 23:54:04 +00:00
|
|
|
],[
|
2012-10-12 15:20:58 +00:00
|
|
|
],[
|
|
|
|
AC_MSG_RESULT(yes)
|
|
|
|
AC_DEFINE(HAVE_CREATE_NAMEIDATA, 1,
|
2015-07-15 17:54:26 +00:00
|
|
|
[iops->create() passes nameidata])
|
2012-10-12 15:20:58 +00:00
|
|
|
],[
|
|
|
|
AC_MSG_RESULT(no)
|
|
|
|
])
|
|
|
|
])
|