iirc there is a macro defined already "for_each_process" that you canuse to get all the processes
struct task_struct *p;
for_each_process (p) { .... }
hth kind regards anupam
for_each_task(p){
...
}> Hi.... > > I would like to know which file i can find the struct > that list all processes executing in linux... > > Thanks, > Luis Henrique.
for_each_task(p) { ... }
#define for_each_task(p) \ for (p = &init_task ; (p = p->next_task) != &init_task ; )
-- Kernelnewbies: Help each other learn about the Linux kernel. Archive: http://mail.nl.linux.org/kernelnewbies/ FAQ: http://kernelnewbies.org/faq/