lockdep: Fix error due to incorrect pointer return
PATCH 1/1 lockdep: Fix error due to incorrect pointer return
From: "Joel Fernandes (Google)" <[email protected]>
The 0-day bot caught an issue which all my tests missed (will add it into my tests) where this_cpu_ptr is incorrectly returning the wrong pointer from get_lock_stats. Fix it.
Fixes f4ac253a8df0 ("lockdep: use this_cpu_ptr instead of get_cpu_var stats")
Signed-off-by Joel Fernandes (Google) <[email protected]>
--- kernel/locking/lockdep.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
kernel/locking/lockdep.c +1 -1
@@ -249,7 +249,7 @@ void clear_lock_stats(struct lock_class *class)static struct lock_class_stats *get_lock_stats (struct lock_class *class) { -return &this_cpu_ptr (&cpu_lock_stats)[class - lock_classes]; +return &this_cpu_ptr (cpu_lock_stats)[class - lock_classes]; }static void lock_release_holdtime (struct held_lock *hlock)
Signature · 1 line
2.18.0.345.g5c9ce644c3-goog