Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/penberg/slab-2.6

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/penberg/slab-2.6:
slab: use NUMA_NO_NODE
slab: remove one NR_CPUS dependency

+4 -3
+4 -3
mm/slab.c
··· 3403 3403 cache_alloc_debugcheck_before(cachep, flags); 3404 3404 local_irq_save(save_flags); 3405 3405 3406 - if (nodeid == -1) 3406 + if (nodeid == NUMA_NO_NODE) 3407 3407 nodeid = slab_node; 3408 3408 3409 3409 if (unlikely(!cachep->nodelists[nodeid])) { ··· 3934 3934 3935 3935 struct ccupdate_struct { 3936 3936 struct kmem_cache *cachep; 3937 - struct array_cache *new[NR_CPUS]; 3937 + struct array_cache *new[0]; 3938 3938 }; 3939 3939 3940 3940 static void do_ccupdate_local(void *info) ··· 3956 3956 struct ccupdate_struct *new; 3957 3957 int i; 3958 3958 3959 - new = kzalloc(sizeof(*new), gfp); 3959 + new = kzalloc(sizeof(*new) + nr_cpu_ids * sizeof(struct array_cache *), 3960 + gfp); 3960 3961 if (!new) 3961 3962 return -ENOMEM; 3962 3963