setup_thread_stack
From: Mulyadi Santosa <hidden>
Date: 2012-07-18 02:31:18
Hi :) On Wed, Jul 18, 2012 at 2:15 AM, Francesco Scali [off-list ref] wrote:
What's this call supposed to do? Inside I can see a call to the "task_thread_info" macro, but I don't quite understand it: #define task_thread_info(task) ((struct thread_info *)(task)->stack)
IMHO, it means that (in the following order): 1. get the task_struct ( you probably already know this) 2. get its stack property (you probably already know this too :) ) And that's it. That's the function of task_thread_info() macro: to return the stack area of that task. IIRC too, stack area is where thread_info belongs to. -- regards, Mulyadi Santosa Freelance Linux trainer and consultant blog: the-hydra.blogspot.com training: mulyaditraining.blogspot.com