[Cbe-oss-dev] [RFC 2/5] spufs: add kalloc_spu_context()
Arnd Bergmann
arnd at arndb.de
Wed Jun 13 17:10:22 EST 2007
On Wednesday 13 June 2007, Sebastian Siewior wrote:
>
> > I just noticed that this function is almost the same as your
> > new alloc_spu_context() function. I think you should try to
> > keep more of the code common, by passing the mm_struct and
> > the task_struct down to the __alloc_spu_context()
> > function.
>
> Okey. This will work for prio but not for mm because init_task.mm is null.
>
That's why I wrote 'mm_struct and task_struct'. You either call
__alloc_spu_context(gang, current, get_task_mm(current)), or
__alloc_spu_context(NULL, &init_task, &init_mm).
Arnd <><
More information about the cbe-oss-dev
mailing list