[PATCH] atomic_long_t & include/asm-generic/atomic.h V2
Several counters already have the need to use 64 atomic variables on 64 bit platforms (see mm_counter_t in sched.h). We have to do ugly ifdefs to fall back to 32 bit atomic on 32 bit platforms. The VM statistics patch that I am working on will also make more extensive use of atomic64. This patch introduces a new type atomic_long_t by providing definitions in asm-generic/atomic.h that works similar to the c "long" type. Its 32 bits on 32 bit platforms and 64 bits on 64 bit platforms. Also cleans up the determination of the mm_counter_t in sched.h. Signed-off-by:Christoph Lameter <clameter@sgi.com> Signed-off-by:
Andrew Morton <akpm@osdl.org> Signed-off-by:
Linus Torvalds <torvalds@osdl.org>
Showing
- include/asm-alpha/atomic.h 1 addition, 0 deletionsinclude/asm-alpha/atomic.h
- include/asm-arm/atomic.h 1 addition, 0 deletionsinclude/asm-arm/atomic.h
- include/asm-arm26/atomic.h 1 addition, 0 deletionsinclude/asm-arm26/atomic.h
- include/asm-cris/atomic.h 1 addition, 0 deletionsinclude/asm-cris/atomic.h
- include/asm-frv/atomic.h 1 addition, 0 deletionsinclude/asm-frv/atomic.h
- include/asm-generic/atomic.h 116 additions, 0 deletionsinclude/asm-generic/atomic.h
- include/asm-h8300/atomic.h 1 addition, 0 deletionsinclude/asm-h8300/atomic.h
- include/asm-i386/atomic.h 1 addition, 0 deletionsinclude/asm-i386/atomic.h
- include/asm-ia64/atomic.h 1 addition, 0 deletionsinclude/asm-ia64/atomic.h
- include/asm-m32r/atomic.h 1 addition, 0 deletionsinclude/asm-m32r/atomic.h
- include/asm-m68k/atomic.h 1 addition, 0 deletionsinclude/asm-m68k/atomic.h
- include/asm-m68knommu/atomic.h 1 addition, 0 deletionsinclude/asm-m68knommu/atomic.h
- include/asm-mips/atomic.h 1 addition, 0 deletionsinclude/asm-mips/atomic.h
- include/asm-parisc/atomic.h 1 addition, 0 deletionsinclude/asm-parisc/atomic.h
- include/asm-powerpc/atomic.h 1 addition, 0 deletionsinclude/asm-powerpc/atomic.h
- include/asm-s390/atomic.h 1 addition, 0 deletionsinclude/asm-s390/atomic.h
- include/asm-sh/atomic.h 1 addition, 0 deletionsinclude/asm-sh/atomic.h
- include/asm-sh64/atomic.h 1 addition, 0 deletionsinclude/asm-sh64/atomic.h
- include/asm-sparc/atomic.h 1 addition, 0 deletionsinclude/asm-sparc/atomic.h
- include/asm-sparc64/atomic.h 1 addition, 0 deletionsinclude/asm-sparc64/atomic.h
Loading
Please register or sign in to comment