2 dnl # 2.6.35 API change,
3 dnl # The 'struct xattr_handler' was constified in the generic
4 dnl # super_block structure.
6 AC_DEFUN([ZFS_AC_KERNEL_CONST_XATTR_HANDLER],
7 [AC_MSG_CHECKING([whether super_block uses const struct xattr_hander])
8 ZFS_LINUX_TRY_COMPILE([
10 #include <linux/xattr.h>
12 const struct xattr_handler xattr_test_handler = {
18 const struct xattr_handler *xattr_handlers[] = {
22 struct super_block sb __attribute__ ((unused));
24 sb.s_xattr = xattr_handlers;
27 AC_DEFINE(HAVE_CONST_XATTR_HANDLER, 1,
28 [super_block uses const struct xattr_hander])
35 dnl # 2.6.33 API change,
36 dnl # The xattr_hander->get() callback was changed to take a dentry
37 dnl # instead of an inode, and a handler_flags argument was added.
39 AC_DEFUN([ZFS_AC_KERNEL_XATTR_HANDLER_GET], [
40 AC_MSG_CHECKING([whether xattr_handler->get() wants dentry])
41 ZFS_LINUX_TRY_COMPILE([
42 #include <linux/xattr.h>
44 int (*get)(struct dentry *dentry, const char *name,
45 void *buffer, size_t size, int handler_flags) = NULL;
46 struct xattr_handler xops __attribute__ ((unused));
51 AC_DEFINE(HAVE_DENTRY_XATTR_GET, 1,
52 [xattr_handler->get() wants dentry])
59 dnl # 2.6.33 API change,
60 dnl # The xattr_hander->set() callback was changed to take a dentry
61 dnl # instead of an inode, and a handler_flags argument was added.
63 AC_DEFUN([ZFS_AC_KERNEL_XATTR_HANDLER_SET], [
64 AC_MSG_CHECKING([whether xattr_handler->set() wants dentry])
65 ZFS_LINUX_TRY_COMPILE([
66 #include <linux/xattr.h>
68 int (*set)(struct dentry *dentry, const char *name,
69 const void *buffer, size_t size, int flags,
70 int handler_flags) = NULL;
71 struct xattr_handler xops __attribute__ ((unused));
76 AC_DEFINE(HAVE_DENTRY_XATTR_SET, 1,
77 [xattr_handler->set() wants dentry])