[PATCH] HAX timer: Describe the delayed_work for a freed timer

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Improve upon the

<3> [310.437368] ODEBUG: free active (active state 0) object type: timer_list hint: delayed_work_timer_fn+0x0/0x10

by describing what delayed_work was queued instead.

Signed-off-by: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx>
---
 kernel/time/timer.c | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/kernel/time/timer.c b/kernel/time/timer.c
index 4820823515e9..262eea5abb86 100644
--- a/kernel/time/timer.c
+++ b/kernel/time/timer.c
@@ -602,7 +602,14 @@ static struct debug_obj_descr timer_debug_descr;
 
 static void *timer_debug_hint(void *addr)
 {
-	return ((struct timer_list *) addr)->function;
+	struct timer_list *timer = addr;
+
+	if (timer->function == delayed_work_timer_fn) {
+		struct delayed_work *work = from_timer(work, timer, timer);
+		return work->work.func;
+	}
+
+	return timer->function;
 }
 
 static bool timer_is_static_object(void *addr)
-- 
2.20.1

_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/intel-gfx



[Index of Archives]     [AMD Graphics]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux