Skip to contentSkip to conversation

locking/qspinlock: Modify comments to adapt to code modification.

PATCH In review Xiangyang Yu 2 participants 2 messages Dec 28, 2020 – Jan 12, 2021 Locking primitives

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 locking/qspinlock: Modify comments to adapt to code modification.

The function 'pv_wait_head_or_lock' comment is not modified in commit 625e88be1f41 ("locking/qspinlock: Merge 'struct __qspinlock' into 'struct qspinlock'"). Fix it.

---
 kernel/locking/qspinlock_paravirt.h | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
kernel/locking/qspinlock_paravirt.h +4 -4
index e84d21aa0722..0b7ecf4eb8b8 100644
@@ -393,7 +393,7 @@ static void pv_kick_node(struct qspinlock *lock, struct mcs_spinlock *node)
 }
 
 /*
- * Wait for l->locked to become clear and acquire the lock;
+ * Wait for lock->locked to become clear and acquire the lock;
  * halt the vcpu after a short spin.
  * __pv_queued_spin_unlock() will wake us.
  *
@@ -447,9 +447,9 @@ pv_wait_head_or_lock(struct qspinlock *lock, struct mcs_spinlock *node)
 			 * when we observe _Q_SLOW_VAL in __pv_queued_spin_unlock()
 			 * we'll be sure to be able to observe our hash entry.
 			 *
-			 *   [S] <hash>                 [Rmw] l->locked == _Q_SLOW_VAL
-			 *       MB                           RMB
-			 * [RmW] l->locked = _Q_SLOW_VAL  [L] <unhash>
+			 *   [S] <hash>                    [Rmw] lock->locked == _Q_SLOW_VAL
+			 *       MB                              RMB
+			 * [RmW] lock->locked = _Q_SLOW_VAL  [L] <unhash>
 			 *
 			 * Matches the smp_rmb() in __pv_queued_spin_unlock().
 			 */
Signature · 1 line
2.23.0
maintainer Acked-by on v1 1/1
#1 lore raw
Quoted 8 lines · Xiangyang Yu

The function 'pv_wait_head_or_lock' comment is not modified in commit 625e88be1f41 ("locking/qspinlock: Merge 'struct __qspinlock' into 'struct qspinlock'"). Fix it.

---
 kernel/locking/qspinlock_paravirt.h | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

Will