asm-generic: fncpy: Add function copying macros
authorRuss Dill <Russ.Dill@ti.com>
Fri, 6 Sep 2013 22:03:56 +0000 (15:03 -0700)
committer黄涛 <huangtao@rock-chips.com>
Thu, 21 Nov 2013 05:39:20 +0000 (13:39 +0800)
commit49d083bd72f8fe93b1d76078be1da897f5e41e98
treed92f2b9385272b730dbff44862a28e29f9c4f5ba
parent6e701bfc17f52d4a36802976ad6baa5ae8b4639d
asm-generic: fncpy: Add function copying macros

Under certain arches (ARM) function pointers cannot be
used naively. Specifically, for thumb functions, their 0 bit
is set, but they are contained on a word aligned address.

Add a fncpy macro to perform function copies correctly
along with two helpers, fnptr_to_address, and fnptr_translate.

Signed-off-by: Russ Dill <Russ.Dill@ti.com>
32 files changed:
arch/alpha/include/asm/fncpy.h [new file with mode: 0644]
arch/arc/include/asm/fncpy.h [new file with mode: 0644]
arch/arm/include/asm/fncpy.h
arch/arm/plat-omap/sram.c
arch/arm64/include/asm/fncpy.h [new file with mode: 0644]
arch/avr32/include/asm/fncpy.h [new file with mode: 0644]
arch/blackfin/include/asm/fncpy.h [new file with mode: 0644]
arch/c6x/include/asm/fncpy.h [new file with mode: 0644]
arch/cris/include/asm/fncpy.h [new file with mode: 0644]
arch/frv/include/asm/fncpy.h [new file with mode: 0644]
arch/h8300/include/asm/fncpy.h [new file with mode: 0644]
arch/hexagon/include/asm/fncpy.h [new file with mode: 0644]
arch/ia64/include/asm/fncpy.h [new file with mode: 0644]
arch/m32r/include/asm/fncpy.h [new file with mode: 0644]
arch/m68k/include/asm/fncpy.h [new file with mode: 0644]
arch/metag/include/asm/fncpy.h [new file with mode: 0644]
arch/microblaze/include/asm/fncpy.h [new file with mode: 0644]
arch/mips/include/asm/fncpy.h [new file with mode: 0644]
arch/mn10300/include/asm/fncpy.h [new file with mode: 0644]
arch/openrisc/include/asm/fncpy.h [new file with mode: 0644]
arch/parisc/include/asm/fncpy.h [new file with mode: 0644]
arch/powerpc/include/asm/fncpy.h [new file with mode: 0644]
arch/s390/include/asm/fncpy.h [new file with mode: 0644]
arch/score/include/asm/fncpy.h [new file with mode: 0644]
arch/sh/include/asm/fncpy.h [new file with mode: 0644]
arch/sparc/include/asm/fncpy.h [new file with mode: 0644]
arch/tile/include/asm/fncpy.h [new file with mode: 0644]
arch/um/include/asm/fncpy.h [new file with mode: 0644]
arch/unicore32/include/asm/fncpy.h [new file with mode: 0644]
arch/x86/include/asm/fncpy.h [new file with mode: 0644]
arch/xtensa/include/asm/fncpy.h [new file with mode: 0644]
include/asm-generic/fncpy.h [new file with mode: 0644]