Andrew Morton wrote: > Matthew Dobson wrote: > >>Okee dokee... Here's the real core of the patch. > > > Looks saneish to me. I'd like to see thorough benchmark results when it is > complete. And it would be nice to make address_space.binding go away if > !CONFIG_NUMA. Yeah... I figured the one pointer wouldn't be a big deal, and it would save a few more ifdefs, but I guess consistency is better. If I ifdef most of it, may as well ifdef it all! > The explicit knowledge of ZONE_DMA/ZONE_NORMAL/ZONE_HIGHMEM in get_zonetype() > should not be necessary - you don't want it to explode if ZONE_DMA32 is > added. It should be indexing into node_zonelists in some manner. > > Will this code work if all memory is in ZONE_DMA, as some architectures do? Well, what I do for now is use the gfp_mask in the address_space that is already there for the shm segments. This means I have to look at that to decide if they want DMA, NORMAL, or HIGHMEM. So it already would need to be changed if we added a new zone. If the thing we're creating a binding for only can use DMA, for example, I need to make sure I use only the DMA zones. I can't easily see a way to make sure I add only the appropriate zones to the zonelist, and also don't look at the gfp_flag to determine the zones they want. I'll ponder it more deeply tonight, though. New patch, sans binding pointer attatched. Cheers! -Matt