]> git.proxmox.com Git - mirror_zfs.git/blame - config/kernel-security-inode-init.m4
FreeBSD: Add zfs_link_create() error handling
[mirror_zfs.git] / config / kernel-security-inode-init.m4
CommitLineData
166dd49d
BB
1dnl #
2dnl # 3.2 API change
3dnl # The security_inode_init_security() API has been changed to include
4dnl # a filesystem specific callback to write security extended attributes.
5dnl # This was done to support the initialization of multiple LSM xattrs
6dnl # and the EVM xattr.
7dnl #
608f8749
BB
8AC_DEFUN([ZFS_AC_KERNEL_SRC_SECURITY_INODE_INIT_SECURITY_CALLBACK], [
9 ZFS_LINUX_TEST_SRC([security_inode_init_security], [
166dd49d
BB
10 #include <linux/security.h>
11 ],[
12 struct inode *ip __attribute__ ((unused)) = NULL;
13 struct inode *dip __attribute__ ((unused)) = NULL;
14 const struct qstr *str __attribute__ ((unused)) = NULL;
15 initxattrs func __attribute__ ((unused)) = NULL;
16
17 security_inode_init_security(ip, dip, str, func, NULL);
608f8749
BB
18 ])
19])
20
21AC_DEFUN([ZFS_AC_KERNEL_SECURITY_INODE_INIT_SECURITY_CALLBACK], [
22 AC_MSG_CHECKING([whether security_inode_init_security wants callback])
23 ZFS_LINUX_TEST_RESULT([security_inode_init_security], [
166dd49d 24 AC_MSG_RESULT(yes)
166dd49d 25 ],[
066e8252 26 ZFS_LINUX_TEST_ERROR([security_inode_init_security callback])
166dd49d 27 ])
166dd49d 28])
608f8749
BB
29
30AC_DEFUN([ZFS_AC_KERNEL_SRC_SECURITY_INODE], [
608f8749
BB
31 ZFS_AC_KERNEL_SRC_SECURITY_INODE_INIT_SECURITY_CALLBACK
32])
33
34AC_DEFUN([ZFS_AC_KERNEL_SECURITY_INODE], [
608f8749
BB
35 ZFS_AC_KERNEL_SECURITY_INODE_INIT_SECURITY_CALLBACK
36])