linux/include/asm-generic
Kyle McMartin f5f5370da4 [PATCH] Decrapify asm-generic/local.h
Now that Christoph Lameter's atomic_long_t support is merged in mainline,
might as well convert asm-generic/local.h to use it, so the same code can
be used for both sizes of 32 and 64-bit unsigned longs.

akpm sayeth:

Q:

  Is there any particular reason why these routines weren't simply
  implemented with local_save/restore_flags, if they are only meant to
  guarantee atomicity to the local cpu?  I'm sure on most platforms this
  would be more efficient than using an atomic...

A:

  The whole _point_ of local_t is to avoid local_irq_disable().  It's
  designed to exploit the fact that many CPUs can do incs and decs in a way
  which is atomic wrt local interrupts, but not atomic wrt SMP.

But this patch makes sense, because asm-generic/local.h is just a fallback
implementation for architectures which either cannot perform these
local-irq-atomic operations, or its maintainers haven't yet got around to
implementing them.

We need more work done on local_t in the 2.6.17 timeframe - they're defined as
unsigned long, but some architectures implement them as signed long.

Signed-off-by: Kyle McMartin <kyle@parisc-linux.org>
Cc: Benjamin LaHaise <bcrl@kvack.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28 09:16:01 -08:00
..
bitops [PATCH] bitops: generic minix_{test,set,test_and_clear,test,find_first_zero}_bit() 2006-03-26 08:57:11 -08:00
4level-fixup.h
atomic.h [PATCH] Use atomic64_set for 64-bit case of atomic_long_set 2006-01-15 10:17:07 -08:00
bitops.h [PATCH] bitops: update include/asm-generic/bitops.h 2006-03-26 08:57:15 -08:00
bug.h [PATCH] make bug messages more consistent 2006-03-23 07:38:16 -08:00
cputime.h
div64.h
dma-mapping-broken.h
dma-mapping.h
emergency-restart.h
errno-base.h
errno.h
fcntl.h
futex.h [PATCH] lightweight robust futexes updates 2006-03-27 08:44:49 -08:00
ide_iops.h
ioctl.h
iomap.h
ipc.h
local.h [PATCH] Decrapify asm-generic/local.h 2006-03-28 09:16:01 -08:00
memory_model.h [PATCH] remove zone_mem_map 2006-03-27 08:44:47 -08:00
mman.h [PATCH] add asm-generic/mman.h 2006-02-15 15:32:22 -08:00
mutex-dec.h
mutex-null.h
mutex-xchg.h
page.h
pci-dma-compat.h
pci.h
percpu.h [PATCH] more for_each_cpu() conversions 2006-03-23 07:38:17 -08:00
pgtable-nopmd.h
pgtable-nopud.h
pgtable.h
resource.h
rtc.h
sections.h
siginfo.h
signal.h
statfs.h
termios.h
tlb.h
topology.h
uaccess.h
unaligned.h [PATCH] __get_unaligned() gcc-4 fix 2006-03-08 14:14:00 -08:00
vmlinux.lds.h [PATCH] add EXPORT_SYMBOL_GPL_FUTURE() 2006-03-20 13:42:58 -08:00
xor.h