|
@@ -318,7 +318,6 @@ static int rcu_boost(void)
|
|
t = container_of(tb, struct task_struct, rcu_node_entry);
|
|
t = container_of(tb, struct task_struct, rcu_node_entry);
|
|
rt_mutex_init_proxy_locked(&mtx, t);
|
|
rt_mutex_init_proxy_locked(&mtx, t);
|
|
t->rcu_boost_mutex = &mtx;
|
|
t->rcu_boost_mutex = &mtx;
|
|
- t->rcu_read_unlock_special |= RCU_READ_UNLOCK_BOOSTED;
|
|
|
|
raw_local_irq_restore(flags);
|
|
raw_local_irq_restore(flags);
|
|
rt_mutex_lock(&mtx);
|
|
rt_mutex_lock(&mtx);
|
|
rt_mutex_unlock(&mtx); /* Keep lockdep happy. */
|
|
rt_mutex_unlock(&mtx); /* Keep lockdep happy. */
|
|
@@ -550,6 +549,9 @@ static noinline void rcu_read_unlock_special(struct task_struct *t)
|
|
int empty_exp;
|
|
int empty_exp;
|
|
unsigned long flags;
|
|
unsigned long flags;
|
|
struct list_head *np;
|
|
struct list_head *np;
|
|
|
|
+#ifdef CONFIG_RCU_BOOST
|
|
|
|
+ struct rt_mutex *rbmp = NULL;
|
|
|
|
+#endif /* #ifdef CONFIG_RCU_BOOST */
|
|
int special;
|
|
int special;
|
|
|
|
|
|
/*
|
|
/*
|
|
@@ -615,10 +617,10 @@ static noinline void rcu_read_unlock_special(struct task_struct *t)
|
|
}
|
|
}
|
|
#ifdef CONFIG_RCU_BOOST
|
|
#ifdef CONFIG_RCU_BOOST
|
|
/* Unboost self if was boosted. */
|
|
/* Unboost self if was boosted. */
|
|
- if (special & RCU_READ_UNLOCK_BOOSTED) {
|
|
|
|
- t->rcu_read_unlock_special &= ~RCU_READ_UNLOCK_BOOSTED;
|
|
|
|
- rt_mutex_unlock(t->rcu_boost_mutex);
|
|
|
|
|
|
+ if (t->rcu_boost_mutex != NULL) {
|
|
|
|
+ rbmp = t->rcu_boost_mutex;
|
|
t->rcu_boost_mutex = NULL;
|
|
t->rcu_boost_mutex = NULL;
|
|
|
|
+ rt_mutex_unlock(rbmp);
|
|
}
|
|
}
|
|
#endif /* #ifdef CONFIG_RCU_BOOST */
|
|
#endif /* #ifdef CONFIG_RCU_BOOST */
|
|
local_irq_restore(flags);
|
|
local_irq_restore(flags);
|