[ANNOUNCE] v5.15-rt17
From: Sebastian Andrzej Siewior
Date: Tue Nov 02 2021 - 07:05:47 EST
Dear RT folks!
I'm pleased to announce the v5.15-rt17 patch set.
Changes since v5.15-rt16:
- Remove put_cpu_var() in fscache which removal was overseen in the
last release.
- Redo the fs/dcache/start_dir_add() related patch and its
description.
- Drop preempt_disable_rt(), no more users.
Known issues
- netconsole triggers WARN.
- The "Memory controller" (CONFIG_MEMCG) has been disabled.
- Valentin Schneider reported a few splats on ARM64, see
https://lkml.kernel.org/r/20210810134127.1394269-1-valentin.schneider@xxxxxxx
The delta patch against v5.15-rt16 is appended below and can be found here:
https://cdn.kernel.org/pub/linux/kernel/projects/rt/5.15/incr/patch-5.15-rt16-rt17.patch.xz
You can get this release via the git tree at:
git://git.kernel.org/pub/scm/linux/kernel/git/rt/linux-rt-devel.git v5.15-rt17
The RT patch against v5.15 can be found here:
https://cdn.kernel.org/pub/linux/kernel/projects/rt/5.15/older/patch-5.15-rt17.patch.xz
The split quilt queue is available at:
https://cdn.kernel.org/pub/linux/kernel/projects/rt/5.15/older/patches-5.15-rt17.tar.xz
Sebastian
diff --git a/fs/dcache.c b/fs/dcache.c
index f34344ceece70..02db80f2817fc 100644
--- a/fs/dcache.c
+++ b/fs/dcache.c
@@ -2537,11 +2537,16 @@ EXPORT_SYMBOL(d_rehash);
static inline unsigned start_dir_add(struct inode *dir)
{
-
- preempt_disable_rt();
+ /*
+ * The caller has a spinlock_t (dentry::d_lock) acquired which disables
+ * preemption on !PREEMPT_RT. On PREEMPT_RT the lock does not disable
+ * preemption and it has be done explicitly.
+ */
+ if (IS_ENABLED(CONFIG_PREEMPT_RT))
+ preempt_disable();
for (;;) {
- unsigned n = dir->__i_dir_seq;
- if (!(n & 1) && cmpxchg(&dir->__i_dir_seq, n, n + 1) == n)
+ unsigned n = dir->i_dir_seq;
+ if (!(n & 1) && cmpxchg(&dir->i_dir_seq, n, n + 1) == n)
return n;
cpu_relax();
}
@@ -2549,8 +2554,9 @@ static inline unsigned start_dir_add(struct inode *dir)
static inline void end_dir_add(struct inode *dir, unsigned n)
{
- smp_store_release(&dir->__i_dir_seq, n + 2);
- preempt_enable_rt();
+ smp_store_release(&dir->i_dir_seq, n + 2);
+ if (IS_ENABLED(CONFIG_PREEMPT_RT))
+ preempt_enable();
}
static void d_wait_lookup(struct dentry *dentry)
@@ -2586,7 +2592,7 @@ struct dentry *d_alloc_parallel(struct dentry *parent,
retry:
rcu_read_lock();
- seq = smp_load_acquire(&parent->d_inode->__i_dir_seq);
+ seq = smp_load_acquire(&parent->d_inode->i_dir_seq);
r_seq = read_seqbegin(&rename_lock);
dentry = __d_lookup_rcu(parent, name, &d_seq);
if (unlikely(dentry)) {
@@ -2614,7 +2620,7 @@ struct dentry *d_alloc_parallel(struct dentry *parent,
}
hlist_bl_lock(b);
- if (unlikely(READ_ONCE(parent->d_inode->__i_dir_seq) != seq)) {
+ if (unlikely(READ_ONCE(parent->d_inode->i_dir_seq) != seq)) {
hlist_bl_unlock(b);
rcu_read_unlock();
goto retry;
diff --git a/fs/fscache/object.c b/fs/fscache/object.c
index 78f332f2e98c8..7a972d144b546 100644
--- a/fs/fscache/object.c
+++ b/fs/fscache/object.c
@@ -814,8 +814,6 @@ void fscache_enqueue_object(struct fscache_object *object)
wake_up(&fscache_object_cong_wait);
} else
fscache_put_object(object, fscache_obj_put_queue);
-
- put_cpu_var(fscache_object_cong_wait);
}
}
diff --git a/fs/inode.c b/fs/inode.c
index 0c46c1a98c2ac..ed0cab8a32db1 100644
--- a/fs/inode.c
+++ b/fs/inode.c
@@ -157,7 +157,7 @@ int inode_init_always(struct super_block *sb, struct inode *inode)
inode->i_pipe = NULL;
inode->i_cdev = NULL;
inode->i_link = NULL;
- inode->__i_dir_seq = 0;
+ inode->i_dir_seq = 0;
inode->i_rdev = 0;
inode->dirtied_when = 0;
diff --git a/include/linux/fs.h b/include/linux/fs.h
index 5ff6117d59f54..e7a633353fd20 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -711,7 +711,7 @@ struct inode {
struct pipe_inode_info *i_pipe;
struct cdev *i_cdev;
char *i_link;
- unsigned __i_dir_seq;
+ unsigned i_dir_seq;
};
__u32 i_generation;
diff --git a/include/linux/preempt.h b/include/linux/preempt.h
index dc8158a459859..3da73c9682119 100644
--- a/include/linux/preempt.h
+++ b/include/linux/preempt.h
@@ -331,14 +331,6 @@ do { \
set_preempt_need_resched(); \
} while (0)
-#ifdef CONFIG_PREEMPT_RT
-# define preempt_disable_rt() preempt_disable()
-# define preempt_enable_rt() preempt_enable()
-#else
-# define preempt_disable_rt() barrier()
-# define preempt_enable_rt() barrier()
-#endif
-
#ifdef CONFIG_PREEMPT_NOTIFIERS
struct preempt_notifier;
diff --git a/localversion-rt b/localversion-rt
index 1199ebade17b4..1e584b47c987e 100644
--- a/localversion-rt
+++ b/localversion-rt
@@ -1 +1 @@
--rt16
+-rt17