diff options
author | Michael Laß | 2023-06-21 21:54:37 +0200 |
---|---|---|
committer | Michael Laß | 2023-06-21 21:54:37 +0200 |
commit | 14eeb3d364efc5b88b59671d693960f10b8426ac (patch) | |
tree | d198cb3fd309171ae816f109a8e8d9182af2b015 | |
parent | 46062321c9dc341dd0b2d48b18d30995465be9d1 (diff) | |
download | aur-14eeb3d364efc5b88b59671d693960f10b8426ac.tar.gz |
Update to 1.8.10pre1
-rw-r--r-- | .SRCINFO | 18 | ||||
-rw-r--r-- | 0001-Linux-Replace-lru_cache_add-with-folio_add_lru.patch | 89 | ||||
-rw-r--r-- | 0002-LINUX-5.13-set-.proc_lseek-in-proc_ops.patch | 45 | ||||
-rw-r--r-- | 0003-Linux-6.3-Include-linux-filelock.h-if-available.patch | 101 | ||||
-rw-r--r-- | 0004-Linux-6.3-Use-mnt_idmap-for-inode-op-functions.patch | 284 | ||||
-rw-r--r-- | PKGBUILD | 35 |
6 files changed, 12 insertions, 560 deletions
@@ -1,7 +1,7 @@ pkgbase = openafs-modules-dkms pkgdesc = Kernel module for OpenAFS (dkms) - pkgver = 1.8.9 - pkgrel = 3 + pkgver = 1.8.10pre1 + pkgrel = 1 url = http://www.openafs.org arch = i686 arch = x86_64 @@ -10,22 +10,14 @@ pkgbase = openafs-modules-dkms depends = dkms depends = libelf depends = openafs - provides = openafs-modules=1.8.9 + provides = openafs-modules=1.8.10pre1 conflicts = openafs-features-libafs conflicts = openafs-modules conflicts = openafs<1.6.6-2 options = !emptydirs - source = http://openafs.org/dl/openafs/1.8.9/openafs-1.8.9-src.tar.bz2 + source = http://openafs.org/dl/openafs/candidate/1.8.10pre1/openafs-1.8.10pre1-src.tar.bz2 source = dkms.conf - source = 0001-Linux-Replace-lru_cache_add-with-folio_add_lru.patch - source = 0002-LINUX-5.13-set-.proc_lseek-in-proc_ops.patch - source = 0003-Linux-6.3-Include-linux-filelock.h-if-available.patch - source = 0004-Linux-6.3-Use-mnt_idmap-for-inode-op-functions.patch - sha256sums = d126178be1f42cca18cb7c0c2691ac354518e3790170150a76bbd25f4d151f06 + sha256sums = 0426a95c2a40e6f9654498e3d22d13080f693dab6db6dede9e05e5b1a15eba93 sha256sums = 5ea5e184f9b44f5ed45817d2b5a10149d15c8c54f49e0b5b4b773652673cb9b0 - sha256sums = e6c9a58f9f0f06a6b32e695548fce2178e7b34f324a3fc7bbe0a9e0e8e38d661 - sha256sums = 5bef56051f0a8f6cf9220fc9182baee53817db8f1bb9051908783196ddbf5109 - sha256sums = 6ff1b1fef24e7d89f99fe6f44b0cefc189f599305d62aaf8e99ca778b28d4a9a - sha256sums = 36ea501ab111a80156c52b951a7051a7bcf27d97cd675edea2e5d87c74e23287 pkgname = openafs-modules-dkms diff --git a/0001-Linux-Replace-lru_cache_add-with-folio_add_lru.patch b/0001-Linux-Replace-lru_cache_add-with-folio_add_lru.patch deleted file mode 100644 index 96a7165e3a70..000000000000 --- a/0001-Linux-Replace-lru_cache_add-with-folio_add_lru.patch +++ /dev/null @@ -1,89 +0,0 @@ -From 55ce972ab2c21115b374d56a20bf6b129635eaeb Mon Sep 17 00:00:00 2001 -From: Cheyenne Wills <cwills@sinenomine.net> -Date: Wed, 14 Dec 2022 13:40:48 -0700 -Subject: [PATCH 1/4] Linux: Replace lru_cache_add with folio_add_lru - -The Linux 6.2 commit: - "folio-compat: remove lru_cache_add()" (6e1ca48d0) -removed the lru_cache_add() function (which was introduced in Linux 5.8) - -The replacement function is folio_add_lru(), which was introduced with -the Linux 5.16 commit: - "mm/lru: Add folio_add_lru()" (0d31125d2d) - -Reviewed-on: https://gerrit.openafs.org/15227 -Reviewed-by: Benjamin Kaduk <kaduk@mit.edu> -Tested-by: Benjamin Kaduk <kaduk@mit.edu> -(cherry picked from commit cfac0df9cd7152be2672c665442aac84215494d6) - -Change-Id: I74535bf83cdd47c9dd60a7114ec7694ae9981c9b -Reviewed-on: https://gerrit.openafs.org/15281 -Reviewed-by: Andrew Deason <adeason@sinenomine.net> -Tested-by: BuildBot <buildbot@rampaginggeek.com> -Reviewed-by: Michael Meffie <mmeffie@sinenomine.net> -Reviewed-by: Stephan Wiesand <stephan.wiesand@desy.de> ---- - src/afs/LINUX/osi_vnodeops.c | 10 +++++++--- - src/cf/linux-kernel-func.m4 | 7 +++++++ - 2 files changed, 14 insertions(+), 3 deletions(-) - -diff --git a/src/afs/LINUX/osi_vnodeops.c b/src/afs/LINUX/osi_vnodeops.c -index bec30bb4c..06c00ac5b 100644 ---- a/src/afs/LINUX/osi_vnodeops.c -+++ b/src/afs/LINUX/osi_vnodeops.c -@@ -32,7 +32,7 @@ - #endif - #include <linux/pagemap.h> - #include <linux/writeback.h> --#if defined(HAVE_LINUX_LRU_CACHE_ADD_FILE) -+#if defined(HAVE_LINUX_FOLIO_ADD_LRU) || defined(HAVE_LINUX_LRU_CACHE_ADD_FILE) - # include <linux/swap.h> - #else - # include <linux/pagevec.h> -@@ -78,7 +78,8 @@ extern struct vcache *afs_globalVp; - - /* Handle interfacing with Linux's pagevec/lru facilities */ - --#if defined(HAVE_LINUX_LRU_CACHE_ADD_FILE) || defined(HAVE_LINUX_LRU_CACHE_ADD) -+#if defined(HAVE_LINUX_FOLIO_ADD_LRU) || \ -+ defined(HAVE_LINUX_LRU_CACHE_ADD_FILE) || defined(HAVE_LINUX_LRU_CACHE_ADD) - - /* - * Linux's lru_cache_add_file provides a simplified LRU interface without -@@ -97,7 +98,10 @@ afs_lru_cache_init(struct afs_lru_pages *alrupages) - static inline void - afs_lru_cache_add(struct afs_lru_pages *alrupages, struct page *page) - { --# if defined(HAVE_LINUX_LRU_CACHE_ADD) -+# if defined(HAVE_LINUX_FOLIO_ADD_LRU) -+ struct folio *folio = page_folio(page); -+ folio_add_lru(folio); -+# elif defined(HAVE_LINUX_LRU_CACHE_ADD) - lru_cache_add(page); - # elif defined(HAVE_LINUX_LRU_CACHE_ADD_FILE) - lru_cache_add_file(page); -diff --git a/src/cf/linux-kernel-func.m4 b/src/cf/linux-kernel-func.m4 -index d3abdf9ff..09cf10f4c 100644 ---- a/src/cf/linux-kernel-func.m4 -+++ b/src/cf/linux-kernel-func.m4 -@@ -173,10 +173,17 @@ AC_CHECK_LINUX_FUNC([in_compat_syscall], - - dnl lru_cache_add exported in Linux 5.8 - dnl replaces lru_cache_add_file -+dnl removed in linux 6.1. folio_add_lru is a replacement - AC_CHECK_LINUX_FUNC([lru_cache_add], - [#include <linux/swap.h>], - [lru_cache_add(NULL);]) - -+dnl Linux 5.16 added folio_add_lru as a replacement for -+dnl lru_cache_add -+AC_CHECK_LINUX_FUNC([folio_add_lru], -+ [#include <linux/swap.h>], -+ [folio_add_lru(NULL);]) -+ - dnl Linux 5.8 replaced kernel_setsockopt with helper functions - dnl e.g. ip_sock_set_mtu_discover, ip_sock_set_recverr - AC_CHECK_LINUX_FUNC([ip_sock_set], --- -2.40.1 - diff --git a/0002-LINUX-5.13-set-.proc_lseek-in-proc_ops.patch b/0002-LINUX-5.13-set-.proc_lseek-in-proc_ops.patch deleted file mode 100644 index d3ae2a6cdbde..000000000000 --- a/0002-LINUX-5.13-set-.proc_lseek-in-proc_ops.patch +++ /dev/null @@ -1,45 +0,0 @@ -From 9251a7010b77e2702d22addfe57e83d644339786 Mon Sep 17 00:00:00 2001 -From: Jeffrey Hutzelman <jhutz@cmu.edu> -Date: Tue, 1 Mar 2022 10:31:14 -0500 -Subject: [PATCH 2/4] LINUX 5.13: set .proc_lseek in proc_ops - -When using the proc_ops structure, set .proc_lseek explicitly rather -than leaving it unset. This field has always been present in proc_ops, -but prior to Linux 5.13, it could be unset, causing default_llseek to be -used. Starting with commit d4455faccd6 (proc: mandate ->proc_lseek in -"struct proc_ops"), this field is now mandatory. - -This fixes a problem which would cause an oops if llseek(2) is called -on /proc/fs/openafs/afs_ioctl. - -Reviewed-on: https://gerrit.openafs.org/14918 -Tested-by: BuildBot <buildbot@rampaginggeek.com> -Reviewed-by: Cheyenne Wills <cwills@sinenomine.net> -Reviewed-by: Michael Meffie <mmeffie@sinenomine.net> -Reviewed-by: Benjamin Kaduk <kaduk@mit.edu> -(cherry picked from commit 68851b782ca2cb5e4ae7457255841f44f3bef15c) - -Change-Id: Ifd3a517f595cfef7fd9dd1fdd3f3aca8fe1bc25f -Reviewed-on: https://gerrit.openafs.org/15286 -Tested-by: BuildBot <buildbot@rampaginggeek.com> -Reviewed-by: Michael Meffie <mmeffie@sinenomine.net> -Reviewed-by: Stephan Wiesand <stephan.wiesand@desy.de> ---- - src/afs/LINUX/osi_ioctl.c | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/src/afs/LINUX/osi_ioctl.c b/src/afs/LINUX/osi_ioctl.c -index 327520c02..fbdee29cb 100644 ---- a/src/afs/LINUX/osi_ioctl.c -+++ b/src/afs/LINUX/osi_ioctl.c -@@ -81,6 +81,7 @@ static struct proc_ops afs_syscall_ops = { - # ifdef STRUCT_PROC_OPS_HAS_PROC_COMPAT_IOCTL - .proc_compat_ioctl = afs_unlocked_ioctl, - # endif -+ .proc_lseek = default_llseek, - }; - #else - static struct file_operations afs_syscall_ops = { --- -2.40.1 - diff --git a/0003-Linux-6.3-Include-linux-filelock.h-if-available.patch b/0003-Linux-6.3-Include-linux-filelock.h-if-available.patch deleted file mode 100644 index 9dde8d281fc1..000000000000 --- a/0003-Linux-6.3-Include-linux-filelock.h-if-available.patch +++ /dev/null @@ -1,101 +0,0 @@ -From 2fcae60b52fd8f56f63fd51813081c754b77aa74 Mon Sep 17 00:00:00 2001 -From: Cheyenne Wills <cwills@sinenomine.net> -Date: Wed, 22 Mar 2023 16:56:09 -0600 -Subject: [PATCH 3/4] Linux 6.3: Include linux/filelock.h if available - -Linux 6.3 commit - 'filelock: move file locking definitions to separate header file' - (5970e15dbc) - -relocated file lock related declarations from 'linux/fs.h' into its own -header file, 'linux/filelock.h'. - -Add autoconf tests to check for the header file 'linux/filelock.h' and -update function checks for locks_lock_file_wait() and posix_lock_file(). - -Update osi_compat.h to include linux/filelock.h if it is available. - -Reviewed-on: https://gerrit.openafs.org/15346 -Tested-by: BuildBot <buildbot@rampaginggeek.com> -Reviewed-by: Benjamin Kaduk <kaduk@mit.edu> -Reviewed-by: Andrew Deason <adeason@sinenomine.net> -(cherry picked from commit 6873dc925c5acc0ce7d65cf778ffee09c82a9898) - -Change-Id: If131bee5b466a119f54b05388a065e6af23698cf -Reviewed-on: https://gerrit.openafs.org/15388 -Tested-by: BuildBot <buildbot@rampaginggeek.com> -Reviewed-by: Andrew Deason <adeason@sinenomine.net> -Reviewed-by: Michael Meffie <mmeffie@sinenomine.net> -Reviewed-by: Kailas Zadbuke <kailashsz@in.ibm.com> -Reviewed-by: Stephan Wiesand <stephan.wiesand@desy.de> -(cherry picked from commit 7a3ad3bc1c87e525698f7dda1e4b0fbbd913da03) ---- - src/afs/LINUX/osi_compat.h | 4 ++++ - src/cf/linux-kernel-func.m4 | 6 +++++- - src/cf/linux-kernel-header.m4 | 2 ++ - src/cf/linux-test4.m4 | 6 +++++- - 4 files changed, 16 insertions(+), 2 deletions(-) - -diff --git a/src/afs/LINUX/osi_compat.h b/src/afs/LINUX/osi_compat.h -index 9a080da31..808c608ad 100644 ---- a/src/afs/LINUX/osi_compat.h -+++ b/src/afs/LINUX/osi_compat.h -@@ -13,6 +13,10 @@ - # include <linux/freezer.h> - #endif - -+#if defined(HAVE_LINUX_FILELOCK_H) -+# include <linux/filelock.h> -+#endif -+ - #if defined(LINUX_KEYRING_SUPPORT) - # include <linux/rwsem.h> - # include <linux/key.h> -diff --git a/src/cf/linux-kernel-func.m4 b/src/cf/linux-kernel-func.m4 -index 09cf10f4c..fc26b98b5 100644 ---- a/src/cf/linux-kernel-func.m4 -+++ b/src/cf/linux-kernel-func.m4 -@@ -94,7 +94,11 @@ AC_CHECK_LINUX_FUNC([ktime_get_real_ts64], - [struct timespec64 *s; - ktime_get_real_ts64(s);]) - AC_CHECK_LINUX_FUNC([locks_lock_file_wait], -- [#include <linux/fs.h>], -+ [#ifdef HAVE_LINUX_FILELOCK_H -+ # include <linux/filelock.h> -+ #else -+ # include <linux/fs.h> -+ #endif], - [locks_lock_file_wait(NULL, NULL);]) - AC_CHECK_LINUX_FUNC([override_creds], - [#include <linux/cred.h>], -diff --git a/src/cf/linux-kernel-header.m4 b/src/cf/linux-kernel-header.m4 -index 8507eaaab..fc52830d2 100644 ---- a/src/cf/linux-kernel-header.m4 -+++ b/src/cf/linux-kernel-header.m4 -@@ -10,4 +10,6 @@ AC_CHECK_LINUX_HEADER([seq_file.h]) - AC_CHECK_LINUX_HEADER([sched/signal.h]) - AC_CHECK_LINUX_HEADER([uaccess.h]) - AC_CHECK_LINUX_HEADER([stdarg.h]) -+dnl Linux 6.3 relocated file locking related declarations into it's own header -+AC_CHECK_LINUX_HEADER([filelock.h]) - ]) -diff --git a/src/cf/linux-test4.m4 b/src/cf/linux-test4.m4 -index f7699cec3..0d6b645f4 100644 ---- a/src/cf/linux-test4.m4 -+++ b/src/cf/linux-test4.m4 -@@ -142,7 +142,11 @@ AC_DEFUN([LINUX_SCHED_STRUCT_TASK_STRUCT_HAS_SIGNAL_RLIM], [ - AC_DEFUN([LINUX_KERNEL_POSIX_LOCK_FILE_WAIT_ARG], [ - AC_CHECK_LINUX_BUILD([for 3rd argument in posix_lock_file found in new kernels], - [ac_cv_linux_kernel_posix_lock_file_wait_arg], -- [#include <linux/fs.h>], -+ [#ifdef HAVE_LINUX_FILELOCK_H -+ # include <linux/filelock.h> -+ #else -+ # include <linux/fs.h> -+ #endif], - [posix_lock_file(0,0,0);], - [POSIX_LOCK_FILE_WAIT_ARG], - [define if your kernel uses 3 arguments for posix_lock_file], --- -2.40.1 - diff --git a/0004-Linux-6.3-Use-mnt_idmap-for-inode-op-functions.patch b/0004-Linux-6.3-Use-mnt_idmap-for-inode-op-functions.patch deleted file mode 100644 index a343e55221a2..000000000000 --- a/0004-Linux-6.3-Use-mnt_idmap-for-inode-op-functions.patch +++ /dev/null @@ -1,284 +0,0 @@ -From 03583703045baa71f92be2bdf72a9d95ef0b5645 Mon Sep 17 00:00:00 2001 -From: Cheyenne Wills <cwills@sinenomine.net> -Date: Wed, 29 Mar 2023 12:11:38 -0600 -Subject: [PATCH 4/4] Linux 6.3: Use mnt_idmap for inode op functions - -Through a series of Linux 6.3 commits starting with: - 'f2fs: project ids aren't idmapped' (64b4cdf22f) and ending with - 'fs: move mnt_idmap' (3707d84c13) -the inode operations functions were changed to take a mnt_idmap -structure instead of a user_namespace structure. These were pulled in -via the the merge commit: - 'Pull vfs idmapping updates from Christian Brauner' (05e6295f7b) -The commit message for the merge contains background and overall -information for this conversion. - -The above change simply changes the functions to use a different -structure (mnt_idmap instead of user_namespace). For afs, it is a -simple change to swap the structures. But for some of the Linux calls -(generic_fillattr(), setattr_prepare(), and inode_op->setattr()) we -would like to use the Linux symbol nop_mnt_idmap, but that symbol is -exported as GPL only. Instead, we will obtain its address from the -current task structure at libafs initialization (much the same way as -obtaining current user namespace for afs_ns). - -Add autoconf tests to determine if inode_operations.create() uses the -mnt_idmap structure. If so set a generic configure define for -"IOP_TAKES_MNT_IDMAP". - -Update afs's inode operations functions to take and use a mnt_idmap -instead of a user_namespace. - -At libafs initialization, obtain the mnt_idmap from the current task -and save it as an afs global variable, afs_mnt_idmap, to be used where -needed. - -Reviewed-on: https://gerrit.openafs.org/15347 -Reviewed-by: Mark Vitale <mvitale@sinenomine.net> -Tested-by: BuildBot <buildbot@rampaginggeek.com> -Reviewed-by: Cheyenne Wills <cwills@sinenomine.net> -Reviewed-by: Benjamin Kaduk <kaduk@mit.edu> -(cherry picked from commit 858ee34545e57acab1e4e5813cd1b9a011538b9e) - -Change-Id: If89c6f401db04826ef45de83b91240f106cca616 -Reviewed-on: https://gerrit.openafs.org/15389 -Tested-by: BuildBot <buildbot@rampaginggeek.com> -Reviewed-by: Andrew Deason <adeason@sinenomine.net> -Reviewed-by: Mark Vitale <mvitale@sinenomine.net> -Reviewed-by: Michael Meffie <mmeffie@sinenomine.net> -Reviewed-by: Kailas Zadbuke <kailashsz@in.ibm.com> -Reviewed-by: Stephan Wiesand <stephan.wiesand@desy.de> -(cherry picked from commit f6fbb85c00411bf97e9855be73baf49bd6b061d7) ---- - src/afs/LINUX/osi_compat.h | 8 ++++-- - src/afs/LINUX/osi_machdep.h | 4 +++ - src/afs/LINUX/osi_module.c | 22 ++++++++++++++++ - src/afs/LINUX/osi_vnodeops.c | 51 ++++++++++++++++++++++++++++++------ - src/cf/linux-kernel-sig.m4 | 13 +++++++++ - 5 files changed, 88 insertions(+), 10 deletions(-) - -diff --git a/src/afs/LINUX/osi_compat.h b/src/afs/LINUX/osi_compat.h -index 808c608ad..bb4969ce8 100644 ---- a/src/afs/LINUX/osi_compat.h -+++ b/src/afs/LINUX/osi_compat.h -@@ -534,7 +534,9 @@ afs_inode_setattr(struct osi_file *afile, struct iattr *newattrs) { - - int code = 0; - struct inode *inode = OSIFILE_INODE(afile); --#if defined(IOP_TAKES_USER_NAMESPACE) -+#if defined(IOP_TAKES_MNT_IDMAP) -+ code = inode->i_op->setattr(afs_mnt_idmap, afile->filp->f_dentry, newattrs); -+#elif defined(IOP_TAKES_USER_NAMESPACE) - code = inode->i_op->setattr(afs_ns, afile->filp->f_dentry, newattrs); - #elif !defined(HAVE_LINUX_INODE_SETATTR) - code = inode->i_op->setattr(afile->filp->f_dentry, newattrs); -@@ -763,7 +765,9 @@ afs_d_path(struct dentry *dp, struct vfsmount *mnt, char *buf, int buflen) - static inline int - afs_setattr_prepare(struct dentry *dp, struct iattr *newattrs) - { --#if defined(IOP_TAKES_USER_NAMESPACE) -+#if defined(IOP_TAKES_MNT_IDMAP) -+ return setattr_prepare(afs_mnt_idmap, dp, newattrs); -+#elif defined(IOP_TAKES_USER_NAMESPACE) - return setattr_prepare(afs_ns, dp, newattrs); - #elif defined(HAVE_LINUX_SETATTR_PREPARE) - return setattr_prepare(dp, newattrs); -diff --git a/src/afs/LINUX/osi_machdep.h b/src/afs/LINUX/osi_machdep.h -index 34940c60d..2220e0530 100644 ---- a/src/afs/LINUX/osi_machdep.h -+++ b/src/afs/LINUX/osi_machdep.h -@@ -217,6 +217,10 @@ extern struct user_namespace *afs_ns; - # define afs_current_user_ns() ((struct user_namespace *)NULL) - # endif - -+#if defined(IOP_TAKES_MNT_IDMAP) -+extern struct mnt_idmap *afs_mnt_idmap; -+#endif -+ - static inline kuid_t afs_make_kuid(uid_t uid) { - return make_kuid(afs_ns, uid); - } -diff --git a/src/afs/LINUX/osi_module.c b/src/afs/LINUX/osi_module.c -index 79ba57c4d..fdc347d2c 100644 ---- a/src/afs/LINUX/osi_module.c -+++ b/src/afs/LINUX/osi_module.c -@@ -31,6 +31,10 @@ - #include <linux/sched.h> - #include <linux/kernel.h> - -+#if defined(IOP_TAKES_MNT_IDMAP) -+# include <linux/fs_struct.h> -+#endif -+ - #include "osi_pagecopy.h" - - extern struct file_system_type afs_fs_type; -@@ -46,6 +50,20 @@ int afs_global_owner = 0; - struct user_namespace *afs_ns; - #endif - -+#if defined(IOP_TAKES_MNT_IDMAP) -+struct mnt_idmap *afs_mnt_idmap; -+ -+static void -+afs_init_idmap(void) -+{ -+ struct path fs_root; -+ -+ get_fs_root(current->fs, &fs_root); -+ afs_mnt_idmap = mnt_idmap(fs_root.mnt); -+ path_put(&fs_root); -+} -+#endif -+ - int __init - afs_init(void) - { -@@ -55,6 +73,10 @@ afs_init(void) - afs_ns = afs_current_user_ns(); - #endif - -+#if defined(IOP_TAKES_MNT_IDMAP) -+ afs_init_idmap(); -+#endif -+ - osi_Init(); - - /* Initialize CellLRU since it is used while traversing CellServDB proc -diff --git a/src/afs/LINUX/osi_vnodeops.c b/src/afs/LINUX/osi_vnodeops.c -index 06c00ac5b..fd54821bd 100644 ---- a/src/afs/LINUX/osi_vnodeops.c -+++ b/src/afs/LINUX/osi_vnodeops.c -@@ -1146,7 +1146,10 @@ vattr2inode(struct inode *ip, struct vattr *vp) - * Linux version of setattr call. What to change is in the iattr struct. - * We need to set bits in both the Linux inode as well as the vcache. - */ --#if defined(IOP_TAKES_USER_NAMESPACE) -+#if defined(IOP_TAKES_MNT_IDMAP) -+static int -+afs_notify_change(struct mnt_idmap *idmap, struct dentry *dp, struct iattr *iattrp) -+#elif defined(IOP_TAKES_USER_NAMESPACE) - static int - afs_notify_change(struct user_namespace *mnt_userns, struct dentry *dp, struct iattr *iattrp) - #else -@@ -1180,7 +1183,18 @@ out: - return afs_convert_code(code); - } - --#if defined(IOP_TAKES_USER_NAMESPACE) -+#if defined(IOP_TAKES_MNT_IDMAP) -+static int -+afs_linux_getattr(struct mnt_idmap *idmap, const struct path *path, struct kstat *stat, -+ u32 request_mask, unsigned int sync_mode) -+{ -+ int err = afs_linux_revalidate(path->dentry); -+ if (!err) { -+ generic_fillattr(afs_mnt_idmap, path->dentry->d_inode, stat); -+ } -+ return err; -+} -+#elif defined(IOP_TAKES_USER_NAMESPACE) - static int - afs_linux_getattr(struct user_namespace *mnt_userns, const struct path *path, struct kstat *stat, - u32 request_mask, unsigned int sync_mode) -@@ -1661,7 +1675,11 @@ struct dentry_operations afs_dentry_operations = { - * name is in kernel space at this point. - */ - --#if defined(IOP_TAKES_USER_NAMESPACE) -+#if defined(IOP_TAKES_MNT_IDMAP) -+static int -+afs_linux_create(struct mnt_idmap *idmap, struct inode *dip, -+ struct dentry *dp, umode_t mode, bool excl) -+#elif defined(IOP_TAKES_USER_NAMESPACE) - static int - afs_linux_create(struct user_namespace *mnt_userns, struct inode *dip, - struct dentry *dp, umode_t mode, bool excl) -@@ -1953,7 +1971,11 @@ afs_linux_unlink(struct inode *dip, struct dentry *dp) - } - - --#if defined(IOP_TAKES_USER_NAMESPACE) -+#if defined(IOP_TAKES_MNT_IDMAP) -+static int -+afs_linux_symlink(struct mnt_idmap *idmap, struct inode *dip, -+ struct dentry *dp, const char *target) -+#elif defined(IOP_TAKES_USER_NAMESPACE) - static int - afs_linux_symlink(struct user_namespace *mnt_userns, struct inode *dip, - struct dentry *dp, const char *target) -@@ -1988,7 +2010,11 @@ out: - return afs_convert_code(code); - } - --#if defined(IOP_TAKES_USER_NAMESPACE) -+#if defined(IOP_TAKES_MNT_IDMAP) -+static int -+afs_linux_mkdir(struct mnt_idmap *idmap, struct inode *dip, -+ struct dentry *dp, umode_t mode) -+#elif defined(IOP_TAKES_USER_NAMESPACE) - static int - afs_linux_mkdir(struct user_namespace *mnt_userns, struct inode *dip, - struct dentry *dp, umode_t mode) -@@ -2068,7 +2094,13 @@ afs_linux_rmdir(struct inode *dip, struct dentry *dp) - } - - --#if defined(IOP_TAKES_USER_NAMESPACE) -+#if defined(IOP_TAKES_MNT_IDMAP) -+static int -+afs_linux_rename(struct mnt_idmap *idmap, -+ struct inode *oldip, struct dentry *olddp, -+ struct inode *newip, struct dentry *newdp, -+ unsigned int flags) -+#elif defined(IOP_TAKES_USER_NAMESPACE) - static int - afs_linux_rename(struct user_namespace *mnt_userns, - struct inode *oldip, struct dentry *olddp, -@@ -2092,7 +2124,7 @@ afs_linux_rename(struct inode *oldip, struct dentry *olddp, - struct dentry *rehash = NULL; - - #if defined(HAVE_LINUX_INODE_OPERATIONS_RENAME_TAKES_FLAGS) || \ -- defined(IOP_TAKES_USER_NAMESPACE) -+ defined(IOP_TAKES_MNT_IDMAP) || defined(IOP_TAKES_USER_NAMESPACE) - if (flags) - return -EINVAL; /* no support for new flags yet */ - #endif -@@ -3388,7 +3420,10 @@ done: - * Check access rights - returns error if can't check or permission denied. - */ - --#if defined(IOP_TAKES_USER_NAMESPACE) -+#if defined(IOP_TAKES_MNT_IDMAP) -+static int -+afs_linux_permission(struct mnt_idmap *idmap, struct inode *ip, int mode) -+#elif defined(IOP_TAKES_USER_NAMESPACE) - static int - afs_linux_permission(struct user_namespace *mnt_userns, struct inode *ip, int mode) - #elif defined(IOP_PERMISSION_TAKES_FLAGS) -diff --git a/src/cf/linux-kernel-sig.m4 b/src/cf/linux-kernel-sig.m4 -index e0cc9a2f3..5301f3503 100644 ---- a/src/cf/linux-kernel-sig.m4 -+++ b/src/cf/linux-kernel-sig.m4 -@@ -28,4 +28,17 @@ dnl define. - AS_IF([test AS_VAR_GET([ac_cv_linux_operation_inode_operations_create_user_namespace]) = yes], - [AC_DEFINE([IOP_TAKES_USER_NAMESPACE], 1, - [define if inodeops require struct user_namespace])]) -+dnl Linux 6.3 replaced the user_namespace parameter with mnt_idmap for -+dnl the inode operations functions. -+AC_CHECK_LINUX_OPERATION([inode_operations], [create], [mnt_idmap], -+ [#include <linux/fs.h>], -+ [int], -+ [struct mnt_idmap *idmap, -+ struct inode *inode, struct dentry *dentry, -+ umode_t umode, bool flag]) -+dnl if HAVE_LINUX_INODE_OPERATIONS_CREATE_MNT_IDMAP, create a more generic -+dnl define. -+AS_IF([test AS_VAR_GET([ac_cv_linux_operation_inode_operations_create_mnt_idmap]) = yes], -+ [AC_DEFINE([IOP_TAKES_MNT_IDMAP], 1, -+ [define if inodeops require struct mnt_idmap])]) - ]) -\ No newline at end of file --- -2.40.1 - @@ -6,8 +6,8 @@ pkgname=openafs-modules-dkms _srcname=openafs -pkgver=1.8.9 -pkgrel=3 +pkgver=1.8.10pre1 +pkgrel=1 pkgdesc="Kernel module for OpenAFS (dkms)" arch=('i686' 'x86_64' 'armv7h') url="http://www.openafs.org" @@ -16,36 +16,15 @@ depends=('dkms' 'libelf' 'openafs') provides=("openafs-modules=$pkgver") conflicts=('openafs-features-libafs' 'openafs-modules' 'openafs<1.6.6-2') options=(!emptydirs) -source=(http://openafs.org/dl/openafs/${pkgver}/${_srcname}-${pkgver}-src.tar.bz2 - dkms.conf - 0001-Linux-Replace-lru_cache_add-with-folio_add_lru.patch - 0002-LINUX-5.13-set-.proc_lseek-in-proc_ops.patch - 0003-Linux-6.3-Include-linux-filelock.h-if-available.patch - 0004-Linux-6.3-Use-mnt_idmap-for-inode-op-functions.patch) -sha256sums=('d126178be1f42cca18cb7c0c2691ac354518e3790170150a76bbd25f4d151f06' - '5ea5e184f9b44f5ed45817d2b5a10149d15c8c54f49e0b5b4b773652673cb9b0' - 'e6c9a58f9f0f06a6b32e695548fce2178e7b34f324a3fc7bbe0a9e0e8e38d661' - '5bef56051f0a8f6cf9220fc9182baee53817db8f1bb9051908783196ddbf5109' - '6ff1b1fef24e7d89f99fe6f44b0cefc189f599305d62aaf8e99ca778b28d4a9a' - '36ea501ab111a80156c52b951a7051a7bcf27d97cd675edea2e5d87c74e23287') +source=(http://openafs.org/dl/openafs/candidate/${pkgver}/${_srcname}-${pkgver}-src.tar.bz2 + dkms.conf) +sha256sums=('0426a95c2a40e6f9654498e3d22d13080f693dab6db6dede9e05e5b1a15eba93' + '5ea5e184f9b44f5ed45817d2b5a10149d15c8c54f49e0b5b4b773652673cb9b0') prepare() { cd "${srcdir}/${_srcname}-${pkgver}" - - # https://gerrit.openafs.org/#/c/15281/ - patch -p1 < "${srcdir}"/0001-Linux-Replace-lru_cache_add-with-folio_add_lru.patch - - # https://gerrit.openafs.org/#/c/15286/ - patch -p1 < "${srcdir}"/0002-LINUX-5.13-set-.proc_lseek-in-proc_ops.patch - - # https://gerrit.openafs.org/#/c/15388/ - patch -p1 < "${srcdir}"/0003-Linux-6.3-Include-linux-filelock.h-if-available.patch - - # https://gerrit.openafs.org/#/c/15389/ - patch -p1 < "${srcdir}"/0004-Linux-6.3-Use-mnt_idmap-for-inode-op-functions.patch - # Only needed when changes to configure were made - ./regen.sh -q + #./regen.sh -q } build() { |