linux/arch/m32r/kernel
David Howells d7627467b7 Make do_execve() take a const filename pointer
Make do_execve() take a const filename pointer so that kernel_execve() compiles
correctly on ARM:

arch/arm/kernel/sys_arm.c:88: warning: passing argument 1 of 'do_execve' discards qualifiers from pointer target type

This also requires the argv and envp arguments to be consted twice, once for
the pointer array and once for the strings the array points to.  This is
because do_execve() passes a pointer to the filename (now const) to
copy_strings_kernel().  A simpler alternative would be to cast the filename
pointer in do_execve() when it's passed to copy_strings_kernel().

do_execve() may not change any of the strings it is passed as part of the argv
or envp lists as they are some of them in .rodata, so marking these strings as
const should be fine.

Further kernel_execve() and sys_execve() need to be changed to match.

This has been test built on x86_64, frv, arm and mips.

Signed-off-by: David Howells <dhowells@redhat.com>
Tested-by: Ralf Baechle <ralf@linux-mips.org>
Acked-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2010-08-17 18:07:43 -07:00
..
align.c
asm-offsets.c
entry.S m32r: Move GET_THREAD_INFO definition out of asm/thread_info.h. 2009-09-23 00:29:39 +09:00
head.S m32r: Move the spi_stack_top and spu_stack_top into .init.data section. 2009-09-23 00:29:40 +09:00
init_task.c Use new __init_task_data macro in arch init_task.c files. 2009-09-21 06:27:08 +02:00
irq.c genirq: Convert irq_desc.lock to raw_spinlock 2009-12-14 23:55:33 +01:00
m32r_ksyms.c m32r: export delay loop symbols 2009-10-04 12:02:36 +09:00
Makefile m32r: build fix for __stringify macro 2009-05-02 21:43:26 +09:00
module.c module: cleanup FIXME comments about trimming exception table entries. 2009-06-12 21:47:05 +09:30
process.c Make do_execve() take a const filename pointer 2010-08-17 18:07:43 -07:00
ptrace.c m32r: use generic ptrace_resume code 2010-03-12 15:52:39 -08:00
setup.c procfs: constify function pointer tables 2008-02-08 09:22:38 -08:00
signal.c KEYS: Add missing linux/tracehook.h #inclusions 2009-09-09 18:30:02 +10:00
smp.c m32r: Should index be positive? 2009-11-04 08:39:26 +09:00
smpboot.c cpumask: Use accessors for cpu_*_mask: m32r 2009-09-24 09:34:47 +09:30
sys_m32r.c Make do_execve() take a const filename pointer 2010-08-17 18:07:43 -07:00
syscall_table.S Unify sys_mmap* 2009-12-11 06:44:29 -05:00
time.c m32r: Convert m32r to use read/update_peristent_clock 2010-03-13 01:14:12 +01:00
traps.c m32r: Fix IPI function calls for SMP 2009-10-04 12:02:37 +09:00
vmlinux.lds.S m32r: add NOTES to vmlinux.lds.S to remove .note.gnu.build-id section 2009-11-04 08:33:23 +09:00