linux/arch/ia64/include/asm
H. Peter Anvin c41d68a513 compat: Make compat_alloc_user_space() incorporate the access_ok()
compat_alloc_user_space() expects the caller to independently call
access_ok() to verify the returned area.  A missing call could
introduce problems on some architectures.

This patch incorporates the access_ok() check into
compat_alloc_user_space() and also adds a sanity check on the length.
The existing compat_alloc_user_space() implementations are renamed
arch_compat_alloc_user_space() and are used as part of the
implementation of the new global function.

This patch assumes NULL will cause __get_user()/__put_user() to either
fail or access userspace on all architectures.  This should be
followed by checking the return value of compat_access_user_space()
for NULL in the callers, at which time the access_ok() in the callers
can also be removed.

Reported-by: Ben Hawkes <hawkes@sota.gen.nz>
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Acked-by: Chris Metcalf <cmetcalf@tilera.com>
Acked-by: David S. Miller <davem@davemloft.net>
Acked-by: Ingo Molnar <mingo@elte.hu>
Acked-by: Thomas Gleixner <tglx@linutronix.de>
Acked-by: Tony Luck <tony.luck@intel.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: Fenghua Yu <fenghua.yu@intel.com>
Cc: H. Peter Anvin <hpa@zytor.com>
Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
Cc: Helge Deller <deller@gmx.de>
Cc: James Bottomley <jejb@parisc-linux.org>
Cc: Kyle McMartin <kyle@mcmartin.ca>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: <stable@kernel.org>
2010-09-14 16:08:45 -07:00
..
native
sn
uv
xen
Kbuild archs: replace unifdef-y with header-y 2010-08-14 22:26:51 +02:00
acpi-ext.h
acpi.h
agp.h
asm-offsets.h
asmmacro.h
atomic.h [IA64] Fix 64-bit atomic routines to return "long" 2010-08-13 16:41:07 -07:00
auxvec.h
bitops.h
bitsperlong.h
break.h
bug.h
bugs.h
byteorder.h
cache.h
cacheflush.h
checksum.h
compat.h compat: Make compat_alloc_user_space() incorporate the access_ok() 2010-09-14 16:08:45 -07:00
cpu.h
cputime.h
current.h
cyclone.h
delay.h
device.h
div64.h
dma-mapping.h dma-mapping: remove dma_is_consistent API 2010-08-11 08:59:21 -07:00
dma.h
dmi.h
elf.h
emergency-restart.h
errno.h
esi.h
fb.h
fcntl.h
fpswa.h
fpu.h
ftrace.h
futex.h
gcc_intrin.h
hardirq.h
hpsim.h
hugetlb.h
hw_irq.h
ia64regs.h
idle.h
intel_intrin.h
intrinsics.h
io.h
ioctl.h
ioctls.h tty: Add EXTPROC support for LINEMODE 2010-08-10 13:47:39 -07:00
iommu.h
iosapic.h
ipcbuf.h
irq.h
irq_regs.h
kdebug.h
kexec.h
kmap_types.h
kprobes.h
kregs.h
kvm.h
kvm_host.h KVM: Remove unnecessary divide operations 2010-08-01 10:47:30 +03:00
kvm_para.h
libata-portmap.h
linkage.h
local.h
local64.h
machvec.h
machvec_dig.h
machvec_dig_vtd.h
machvec_hpsim.h
machvec_hpzx1.h
machvec_hpzx1_swiotlb.h
machvec_init.h
machvec_sn2.h
machvec_uv.h
machvec_xen.h
mc146818rtc.h
mca.h
mca_asm.h
meminit.h
mman.h
mmu.h
mmu_context.h
mmzone.h
module.h
msgbuf.h
msidef.h
mutex.h
nodedata.h
numa.h
page.h
pal.h
param.h
paravirt.h
paravirt_patch.h
paravirt_privop.h
parport.h
patch.h
pci.h
percpu.h
perfmon.h
perfmon_default_smpl.h
pgalloc.h
pgtable.h
poll.h
posix_types.h
processor.h
ptrace.h
ptrace_offsets.h
pvclock-abi.h
resource.h
rse.h
rwsem.h [IA64] Fix rwsem: RWSEM_WAITING_BIAS must not be unsigned. 2010-08-12 09:14:56 -07:00
sal.h
scatterlist.h remove needless ISA_DMA_THRESHOLD 2010-08-07 18:15:50 +02:00
sections.h
segment.h
sembuf.h
serial.h
setup.h
shmbuf.h
shmparam.h
sigcontext.h
siginfo.h
signal.h
smp.h
socket.h
sockios.h
sparsemem.h
spinlock.h
spinlock_types.h
stat.h
statfs.h
string.h
swab.h
swiotlb.h
sync_bitops.h
syscall.h
system.h
termbits.h tty: Add EXTPROC support for LINEMODE 2010-08-10 13:47:39 -07:00
termios.h
thread_info.h
timex.h
tlb.h
tlbflush.h
topology.h
types.h
uaccess.h
ucontext.h
unaligned.h
uncached.h
unistd.h [IA64] Fix build error: conflicting types for ‘sys_execve’ 2010-08-18 10:17:44 -07:00
unwind.h
user.h
ustack.h
vga.h
xor.h