All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] locking/pvqspinlock: Fix a bug in qstat_read()
@ 2016-07-13 10:23 Pan Xinhui
  2016-07-13 13:50 ` Waiman Long
  2016-08-10 18:06 ` [tip:locking/core] " tip-bot for Pan Xinhui
  0 siblings, 2 replies; 3+ messages in thread
From: Pan Xinhui @ 2016-07-13 10:23 UTC (permalink / raw)
  To: linux-kernel; +Cc: peterz, mingo, Waiman.Long, Pan Xinhui

It's obviously wrong to set stat to NULL. So lets remove it.
Otherwise it is always zero when we check the latency of kick/wake

Signed-off-by: Pan Xinhui <xinhui.pan@linux.vnet.ibm.com>
---
 kernel/locking/qspinlock_stat.h | 1 -
 1 file changed, 1 deletion(-)

diff --git a/kernel/locking/qspinlock_stat.h b/kernel/locking/qspinlock_stat.h
index 7b0f1b9..8fa1165 100644
--- a/kernel/locking/qspinlock_stat.h
+++ b/kernel/locking/qspinlock_stat.h
@@ -157,7 +157,6 @@ static ssize_t qstat_read(struct file *file, char __user *user_buf,
 		 */
 		if ((counter == qstat_pv_latency_kick) ||
 		    (counter == qstat_pv_latency_wake)) {
-			stat = 0;
 			if (kicks)
 				stat = DIV_ROUND_CLOSEST_ULL(stat, kicks);
 		}
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-08-10 21:16 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-07-13 10:23 [PATCH] locking/pvqspinlock: Fix a bug in qstat_read() Pan Xinhui
2016-07-13 13:50 ` Waiman Long
2016-08-10 18:06 ` [tip:locking/core] " tip-bot for Pan Xinhui

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.