lkml.org 
[lkml]   [2011]   [Jan]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
Subjectx86_64: could increment fp when getting wchan?
From
When getting wchan (wait channel?) the stack of given task is scanned
for IP that is not in the scheduling area. What looks odd is the IP
could be checked as many times as allowed in the loop without changing
the location on stack. Could the IP be checked up stair the stack?

Hillf
---

--- a/arch/x86/kernel/process_64.c 2011-01-05 08:50:20.000000000 +0800
+++ b/arch/x86/kernel/process_64.c 2011-01-21 21:46:04.000000000 +0800
@@ -543,7 +543,7 @@ unsigned long get_wchan(struct task_stru
ip = *(u64 *)(fp+8);
if (!in_sched_functions(ip))
return ip;
- fp = *(u64 *)fp;
+ fp += 8;
} while (count++ < 16);
return 0;
}

\
 
 \ /
  Last update: 2011-01-21 14:57    [W:0.045 / U:0.464 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site