On 07/13/2016 06:23 AM, Pan Xinhui wrote:
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<[email protected]>
---
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);
}
Thanks for catching that. The statement shouldn't be there.
Reviewed-by: Waiman Long <[email protected]>