浏览代码

[PATCH] schedule_timeout(): improve warning message

Kyle is hitting this warning, and we don't have a clue what it's caused by.
Add the obligatory dump_stack().

Cc: kyle <kylewong@southa.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Andrew Morton 18 年之前
父节点
当前提交
5b149bcc23
共有 1 个文件被更改,包括 3 次插入4 次删除
  1. 3 4
      kernel/timer.c

+ 3 - 4
kernel/timer.c

@@ -1344,11 +1344,10 @@ fastcall signed long __sched schedule_timeout(signed long timeout)
 		 * should never happens anyway). You just have the printk()
 		 * should never happens anyway). You just have the printk()
 		 * that will tell you if something is gone wrong and where.
 		 * that will tell you if something is gone wrong and where.
 		 */
 		 */
-		if (timeout < 0)
-		{
+		if (timeout < 0) {
 			printk(KERN_ERR "schedule_timeout: wrong timeout "
 			printk(KERN_ERR "schedule_timeout: wrong timeout "
-				"value %lx from %p\n", timeout,
-				__builtin_return_address(0));
+				"value %lx\n", timeout);
+			dump_stack();
 			current->state = TASK_RUNNING;
 			current->state = TASK_RUNNING;
 			goto out;
 			goto out;
 		}
 		}