Archived
14
0
Fork 0
This repository has been archived on 2022-02-17. You can view files and clone it, but cannot push or open issues or pull requests.
linux-2.6/include/asm-generic
Mike Travis aa6b54461c asm-generic: add node_to_cpumask_ptr macro
Create a simple macro to always return a pointer to the node_to_cpumask(node)
value.  This relies on compiler optimization to remove the extra indirection:

    #define node_to_cpumask_ptr(v, node) 		\
	    cpumask_t _##v = node_to_cpumask(node), *v = &_##v

For those systems with a large cpumask size, then a true pointer
to the array element can be used:

    #define node_to_cpumask_ptr(v, node)		\
	    cpumask_t *v = &(node_to_cpumask_map[node])

A node_to_cpumask_ptr_next() macro is provided to access another
node_to_cpumask value.

The other change is to always include asm-generic/topology.h moving the
ifdef CONFIG_NUMA to this same file.

Note: there are no references to either of these new macros in this patch,
only the definition.

Based on 2.6.25-rc5-mm1

# alpha
Cc: Richard Henderson <rth@twiddle.net>

# fujitsu
Cc: David Howells <dhowells@redhat.com>

# ia64
Cc: Tony Luck <tony.luck@intel.com>

# powerpc
Cc: Paul Mackerras <paulus@samba.org>
Cc: Anton Blanchard <anton@samba.org>

# sparc
Cc: David S. Miller <davem@davemloft.net>
Cc: William L. Irwin <wli@holomorphy.com>

# x86
Cc: H. Peter Anvin <hpa@zytor.com>

Signed-off-by: Mike Travis <travis@sgi.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
2008-04-19 19:44:58 +02:00
..
bitops ext4: Add ext4_find_next_bit() 2008-01-28 23:58:27 -05:00
4level-fixup.h add mm argument to pte/pmd/pud/pgd_free 2008-02-05 09:44:18 -08:00
atomic.h
audit_change_attr.h
audit_dir_write.h
audit_read.h
audit_signal.h
audit_write.h
bitops.h
bug.h debug: move WARN_ON() out of line 2008-01-30 13:32:50 +01:00
cmpxchg-local.h Add cmpxchg_local to asm-generic for per cpu atomic operations 2008-02-07 08:42:30 -08:00
cmpxchg.h Add cmpxchg_local to asm-generic for per cpu atomic operations 2008-02-07 08:42:30 -08:00
cputime.h taskstats scaled time cleanup 2008-02-06 10:41:00 -08:00
device.h
div64.h
dma-mapping-broken.h
dma-mapping.h
emergency-restart.h
errno-base.h
errno.h
fcntl.h
futex.h
gpio.h gpiolib: add gpio provider infrastructure 2008-02-05 09:44:12 -08:00
ide_iops.h
ioctl.h
iomap.h asm-generic: remove fastcall 2008-02-08 09:22:31 -08:00
irq_regs.h
Kbuild
Kbuild.asm kvm: provide kvm.h for all architecture: fixes headers_install 2008-04-02 15:28:18 -07:00
kdebug.h
libata-portmap.h
local.h
memory_model.h
mm_hooks.h
mman.h
mutex-dec.h asm-generic: remove fastcall 2008-02-08 09:22:31 -08:00
mutex-null.h
mutex-xchg.h asm-generic: remove fastcall 2008-02-08 09:22:31 -08:00
page.h
pci-dma-compat.h
pci.h
percpu.h percpu: fix DEBUG_PREEMPT per_cpu checking 2008-02-23 12:09:28 -08:00
pgtable-nopmd.h add mm argument to pte/pmd/pud/pgd_free 2008-02-05 09:44:18 -08:00
pgtable-nopud.h add mm argument to pte/pmd/pud/pgd_free 2008-02-05 09:44:18 -08:00
pgtable.h
poll.h
resource.h sched: SCHED_FIFO/SCHED_RR watchdog timer 2008-01-25 21:08:27 +01:00
rtc.h x86: fix RTC lockdep warning: potential hardirq recursion 2008-02-04 16:48:10 +01:00
sections.h remove support for un-needed _extratext section 2008-02-06 10:41:01 -08:00
siginfo.h
signal.h
statfs.h
termios.h tty: let architectures override the user/kernel macros. 2008-02-08 09:22:24 -08:00
tlb.h asm-generic/tlb.h: remove <linux/quicklist.h> 2008-02-04 16:48:00 +01:00
topology.h asm-generic: add node_to_cpumask_ptr macro 2008-04-19 19:44:58 +02:00
uaccess.h
unaligned.h
vmlinux.lds.h Add missing init section definitions 2008-02-19 21:00:18 +01:00
xor.h