lkml.org 
[lkml]   [2009]   [Dec]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: [PATCH 05/37] kdb: core for kgdb back end
Peter Zijlstra wrote:
> On Wed, 2009-12-23 at 15:19 -0600, Jason Wessel wrote:
>> +kdb_prio(char *name, struct rt_prio_array *array, kdb_printf_t xxx_printf,
[..]
>> +kdb_runqueue(unsigned long cpu, kdb_printf_t xxx_printf)
[..]
>
> So what is this code supposed to do? It looks like it simply cannot be
> correct.
>

Beyond the fact that the code may not be right, it is a small part of a kdb module which is not included, and these functions can immediately disappear. For reference, the original kdb module was called "kdbm_sched" and I believe it was intended as an aid to help debug the scheduler and process priorities in earlier versions of the kernel.

I have removed all this code and reduced the patch to kernel/sched.c to the following. The reason we need the attached patch is to be able to call curr_task() for kdb to perform some basic per cpu task analysis while the system is stopped.

Thanks,
Jason.

--- a/kernel/sched.c
+++ b/kernel/sched.c
@@ -9784,9 +9784,9 @@ void normalize_rt_tasks(void)

#endif /* CONFIG_MAGIC_SYSRQ */

-#ifdef CONFIG_IA64
+#if defined(CONFIG_IA64) || defined(CONFIG_KGDB_KDB)
/*
- * These functions are only useful for the IA64 MCA handling.
+ * These functions are only useful for the IA64 MCA handling, or kdb.
*
* They can only be called when the whole system has been
* stopped - every CPU needs to be quiescent, and no scheduling

\
 
 \ /
  Last update: 2009-12-28 17:37    [W:0.285 / U:0.448 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site