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

Re: kdb: task_has_cpu not found



On Wed, 2002-02-13 at 17:44, Ionut Georgescu wrote:
> 
> Yes ... it was somewhere there on the list :)) It seemed that the
> original files had all gone into *.orig's after applying the patch ...
> Therefore my grep -r theory.
> 
> Is there a way to solve this ? I have turned kdb off meanwhile and I'm
> prepairing to reboot.

>From the 2.5 tree:

int
kdb_ps(int argc, const char **argv, const char **envp, struct pt_regs *regs)
{
        struct task_struct      *p;

        kdb_printf("%-*s Pid      Parent   [*] cpu  State %-*s Command\n",
                (int)(2*sizeof(void *))+2, "Task Addr",
                (int)(2*sizeof(void *))+2, "Thread");
        for_each_task(p) {
                kdb_printf("0x%p %08d %08d  %1.1d  %3.3d  %s  0x%p%c%s\n",
                           (void *)p, p->pid, p->p_pptr->pid,
                           p->state == TASK_RUNNING, p->thread_info->cpu,
                           (p->state == 0)?"run ":(p->state>0)?"stop":"unrn",
                           (void *)(&p->thread),
                           (p == current) ? '*': ' ',
                           p->comm);
        }

        return 0;
}

I think this should work - since this is where the scheduler went in
first.

Steve


-- 

Steve Lord                                      voice: +1-651-683-3511
Principal Engineer, Filesystem Software         email: lord@sgi.com