mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-22 02:27:36 +03:00
Linux 3.5 compat, end_writeback() changed to clear_inode()
The end_writeback() function was changed by moving the call to inode_sync_wait() earlier in to evict(). This effecitvely changes the ordering of the sync but it does not impact the details of the zfs implementation. However, as part of this change end_writeback() was renamed to clear_inode() to reflect the new semantics. This change does impact us and clear_inode() now maps to end_writeback() for kernels prior to 3.5. Signed-off-by: Richard Yao <ryao@cs.stonybrook.edu> Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Closes #784
This commit is contained in:
committed by
Brian Behlendorf
parent
ea1fdf46e2
commit
739a1a82e0
@@ -0,0 +1,29 @@
|
||||
dnl #
|
||||
dnl # 3.5.0 API change
|
||||
dnl # torvalds/linux@dbd5768f87ff6fb0a4fe09c4d7b6c4a24de99430 and
|
||||
dnl # torvalds/linux@7994e6f7254354e03028a11f98a27bd67dace9f1 reworked
|
||||
dnl # where inode_sync_wait() is called.
|
||||
dnl #
|
||||
dnl # Prior to these changes it would occur in end_writeback() but due
|
||||
dnl # to various issues (described in the above commits) it has been
|
||||
dnl # moved to evict(). This changes the ordering is which sync occurs
|
||||
dnl # but otherwise doesn't impact the zpl implementation.
|
||||
dnl #
|
||||
dnl # The major impact here is the renaming of end_writeback() to
|
||||
dnl # clear_inode(). However, care must be taken when detecting this
|
||||
dnl # API change because as recently as 2.6.35 there was a clear_inode()
|
||||
dnl # function. However, it was made obsolete by the evict_inode() API
|
||||
dnl # change at the same time.
|
||||
dnl #
|
||||
dnl # Therefore, to ensure we have the correct API we only allow the
|
||||
dnl # clear_inode() compatibility code to be defined iff the evict_inode()
|
||||
dnl # functionality is also detected.
|
||||
dnl #
|
||||
AC_DEFUN([ZFS_AC_KERNEL_CLEAR_INODE], [
|
||||
ZFS_CHECK_SYMBOL_EXPORT(
|
||||
[clear_inode],
|
||||
[fs/inode.c],
|
||||
[AC_DEFINE(HAVE_CLEAR_INODE, 1,
|
||||
[clear_inode() is available])],
|
||||
[])
|
||||
])
|
||||
@@ -51,6 +51,7 @@ AC_DEFUN([ZFS_AC_CONFIG_KERNEL], [
|
||||
ZFS_AC_KERNEL_CREATE_UMODE_T
|
||||
ZFS_AC_KERNEL_AUTOMOUNT
|
||||
ZFS_AC_KERNEL_ENCODE_FH_WITH_INODE
|
||||
ZFS_AC_KERNEL_CLEAR_INODE
|
||||
ZFS_AC_KERNEL_INSERT_INODE_LOCKED
|
||||
ZFS_AC_KERNEL_D_MAKE_ROOT
|
||||
ZFS_AC_KERNEL_D_OBTAIN_ALIAS
|
||||
|
||||
Reference in New Issue
Block a user