Re: [PATCH] stop null ptr deference in __alloc_pages

From: Martin J. Bligh (Martin.Bligh@us.ibm.com)
Date: Fri Mar 08 2002 - 16:50:49 EST


>> I should have also mentioned that:
>>
>> 1) I shouldn't need the SGI patch, though it might help performance.
>
> Why shouldn't you need it ? It is NUMA generic, and totally arch
> independent.

I just mean the kernel shouldn't panic if I don't have it.

> And it actually helps performance. I also allows the kernel to have a
> single memory allocation path. I think it is cleaner than calling _alloc_pages()
> from numa.c
>
>> 2) The kernel panics without my fix, and runs fine with it.
> I hope so :-)
> But your fix is at the same time useless and harmless for UMA machines.

Yup, though I suppose we could shave off a couple of nanoseconds by
surrounding my little check with #ifdef CONFIG_NUMA.

> OTOH, the SGI patch doesn't modify __alloc_pages(). I think I'm a little
> too picky here...

With the #ifdef, I won't really do this either (at least for the code generated).

The SGI patch is probably a good thing, and I'll pick it up and try it
sometime soon. The only real problem is that it's not in the mainline
already. Until such time as it gets there, the fix I posted is trivial,
and easily seen to be correct (well, I'm biased ;-) ), and should get
shoved into the mainline much easier.

M.

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



This archive was generated by hypermail 2b29 : Fri Mar 15 2002 - 22:00:10 EST