From a0abd7c5ff981473ea526a0dcf4cdcb66882223f Mon Sep 17 00:00:00 2001 From: Rob Norris Date: Mon, 5 Aug 2024 22:19:15 +1000 Subject: [PATCH] config: remove HAVE_GET_LINK_COOKIE As far as I can tell, this never made it to a real release. It was introduced in 6b2553918d8b and removed a couple of weeks later in fceef393a538. This was all part of the development of what would become 4.5. So I assume this was OpenZFS chasing upstream development at the time. fceef393a538 viro 2015-12-30 switch ->get_link() to delayed_call, kill ->put_link() cd3417c8fc95 viro 2015-12-29 kill free_page_put_link() 0d0def49d05a viro 2015-12-08 teach nfs_get_link() to work in RCU mode 1a384eaac265 viro 2015-12-08 teach proc_self_get_link()/proc_thread_self_get_link() to work in RCU mode 6a6c99049635 viro 2015-12-08 teach shmem_get_link() to work in RCU mode d3883d4f9344 viro 2015-12-08 teach page_get_link() to work in RCU mode 6b2553918d8b viro 2015-12-08 replace ->follow_link() with new method that could stay in RCU mode Sponsored-by: https://despairlabs.com/sponsor/ Reviewed-by: Brian Behlendorf Reviewed-by: Tony Hutter Reviewed-by: Tino Reichardt Signed-off-by: Rob Norris Closes #16479 --- config/kernel-get-link.m4 | 42 ++++++++------------------------------- 1 file changed, 8 insertions(+), 34 deletions(-) diff --git a/config/kernel-get-link.m4 b/config/kernel-get-link.m4 index 31c7ac623..87ad948e3 100644 --- a/config/kernel-get-link.m4 +++ b/config/kernel-get-link.m4 @@ -13,16 +13,6 @@ AC_DEFUN([ZFS_AC_KERNEL_SRC_GET_LINK], [ }; ],[]) - ZFS_LINUX_TEST_SRC([inode_operations_get_link_cookie], [ - #include - static const char *get_link(struct dentry *de, struct - inode *ip, void **cookie) { return "symlink"; } - static struct inode_operations - iops __attribute__ ((unused)) = { - .get_link = get_link, - }; - ],[]) - ZFS_LINUX_TEST_SRC([inode_operations_follow_link], [ #include static const char *follow_link(struct dentry *de, @@ -48,34 +38,18 @@ AC_DEFUN([ZFS_AC_KERNEL_GET_LINK], [ AC_MSG_RESULT(no) dnl # - dnl # 4.5 API change - dnl # The follow_link() interface has been replaced by - dnl # get_link() which behaves the same as before except: - dnl # - An inode is passed as a separate argument - dnl # - When called in RCU mode a NULL dentry is passed. + dnl # 4.2 API change + dnl # This kernel retired the nameidata structure. dnl # - AC_MSG_CHECKING([whether iops->get_link() passes cookie]) - ZFS_LINUX_TEST_RESULT([inode_operations_get_link_cookie], [ + AC_MSG_CHECKING( + [whether iops->follow_link() passes cookie]) + ZFS_LINUX_TEST_RESULT([inode_operations_follow_link], [ AC_MSG_RESULT(yes) - AC_DEFINE(HAVE_GET_LINK_COOKIE, 1, - [iops->get_link() cookie]) + AC_DEFINE(HAVE_FOLLOW_LINK_COOKIE, 1, + [iops->follow_link() cookie]) ],[ AC_MSG_RESULT(no) - - dnl # - dnl # 4.2 API change - dnl # This kernel retired the nameidata structure. - dnl # - AC_MSG_CHECKING( - [whether iops->follow_link() passes cookie]) - ZFS_LINUX_TEST_RESULT([inode_operations_follow_link], [ - AC_MSG_RESULT(yes) - AC_DEFINE(HAVE_FOLLOW_LINK_COOKIE, 1, - [iops->follow_link() cookie]) - ],[ - AC_MSG_RESULT(no) - ZFS_LINUX_TEST_ERROR([get_link]) - ]) + ZFS_LINUX_TEST_ERROR([get_link]) ]) ]) ])