3 dnl # i_mutex is changed to i_rwsem. Instead of directly using
4 dnl # i_mutex/i_rwsem, we should use inode_lock() and inode_lock_shared()
5 dnl # We test inode_lock_shared because inode_lock is introduced earlier.
7 AC_DEFUN([SPL_AC_INODE_LOCK], [
8 AC_MSG_CHECKING([whether inode_lock_shared() exists])
9 tmp_flags="$EXTRA_KCFLAGS"
10 EXTRA_KCFLAGS="-Werror"
11 SPL_LINUX_TRY_COMPILE([
14 struct inode *inode = NULL;
15 inode_lock_shared(inode);
18 AC_DEFINE(HAVE_INODE_LOCK_SHARED, 1, [yes])
22 EXTRA_KCFLAGS="$tmp_flags"