aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--kernel/rcutree.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/kernel/rcutree.c b/kernel/rcutree.c
index d8d98655c9e7..705f02ac7433 100644
--- a/kernel/rcutree.c
+++ b/kernel/rcutree.c
@@ -1647,7 +1647,8 @@ static void __init rcu_init_one(struct rcu_state *rsp)
1647 cpustride *= rsp->levelspread[i]; 1647 cpustride *= rsp->levelspread[i];
1648 rnp = rsp->level[i]; 1648 rnp = rsp->level[i];
1649 for (j = 0; j < rsp->levelcnt[i]; j++, rnp++) { 1649 for (j = 0; j < rsp->levelcnt[i]; j++, rnp++) {
1650 spin_lock_init(&rnp->lock); 1650 if (rnp != rcu_get_root(rsp))
1651 spin_lock_init(&rnp->lock);
1651 rnp->gpnum = 0; 1652 rnp->gpnum = 0;
1652 rnp->qsmask = 0; 1653 rnp->qsmask = 0;
1653 rnp->qsmaskinit = 0; 1654 rnp->qsmaskinit = 0;
@@ -1670,6 +1671,7 @@ static void __init rcu_init_one(struct rcu_state *rsp)
1670 INIT_LIST_HEAD(&rnp->blocked_tasks[1]); 1671 INIT_LIST_HEAD(&rnp->blocked_tasks[1]);
1671 } 1672 }
1672 } 1673 }
1674 spin_lock_init(&rcu_get_root(rsp)->lock);
1673} 1675}
1674 1676
1675/* 1677/*