Re: [PATCH] Put modules into linear mapping

From: Andi Kleen (ak@suse.de)
Date: Fri Sep 27 2002 - 10:36:35 EST


Roman Zippel <zippel@linux-m68k.org> writes:

> Why is i386 only? This is generic code and other archs will benefit from
> it as well (or at least it won't hurt).

Because some arcitectures have a different module_map() (e.g. x86-64 or
sparc64) and because the VMALLOC_START/END trick doesn't work on all.

> > +
> > +void *alloc_exact(unsigned int size)
> > +{
> > + struct page *p, *w;
> > + int order = get_order(size);
> > +
> > + p = alloc_pages(GFP_KERNEL, order);
>
> Wouldn't it be better to add a gfp argument?

I don't see a need for it. GFP_ATOMIC doesn't make sense for > order 0,
and > order 0 is the only case that is interesting for alloc_exact.
GFP_DMA is not needed here, and GFP_HIGHUSER neither supports > order 0
properly (because of kmap)

-Andi
-
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 : Mon Sep 30 2002 - 22:00:31 EST