Re: [PATCH] PPC64 mmu_context_init needs to run earlier

From: Linus Torvalds
Date: Tue Nov 02 2004 - 17:16:18 EST




On Tue, 2 Nov 2004, Nathan Lynch wrote:
>
> Using idr_get_new_above in init_new_context lets us get rid of an
> awkward init function which wasn't running early enough in boot
> anyway.

Ok, call me stupid, but what's the difference between

idr_get_new(&mmu_context_idr, NULL, &index);

and

idr_get_new_above(&mmu_context_idr, NULL, 0, &index);

because as far as I can tell, they are exactly the same.

They both just do a "idr_get_new_above_int(idp, ptr, 0)".

So I don't see why one would need an awkward init function, and the other
wouldn't..

That said, maybe the problem is that we shouldn't even get far enough into
the fork() logic to ever get into a new MMU context if driver_init ends up
being called before we're ready.

Linus
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/