summaryrefslogtreecommitdiff
path: root/arch/mips/kernel
AgeCommit message (Collapse)Author
2010-10-20Merge branch 'upstream' of git://git.linux-mips.org/pub/scm/upstream-linusLinus Torvalds
* 'upstream' of git://git.linux-mips.org/pub/scm/upstream-linus: MIPS: O32 compat/N32: Fix to use compat syscall wrappers for AIO syscalls. MAINTAINERS: Change list for ioc_serial to linux-serial. SERIAL: ioc3_serial: Return -ENOMEM on memory allocation failure MIPS: jz4740: Fix Kbuild Platform file. MIPS: Repair Kbuild make clean breakage.
2010-10-19MIPS: O32 compat/N32: Fix to use compat syscall wrappers for AIO syscalls.Michel Thebeau
[Ralf: Michel's original patch only fixed N32; I replicated the same fix for O32.] Signed-off-by: Michel Thebeau <michel.thebeau@windriver.com> Cc: paul.gortmaker@windriver.com Cc: bruce.ashfield@windriver.com Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-10-18Merge branch 'upstream' of git://git.linux-mips.org/pub/scm/upstream-linusLinus Torvalds
* 'upstream' of git://git.linux-mips.org/pub/scm/upstream-linus: MIPS: Enable ISA_DMA_API config to fix build failure MIPS: 32-bit: Fix build failure in asm/fcntl.h MIPS: Remove all generated vmlinuz* files on "make clean" MIPS: do_sigaltstack() expects userland pointers MIPS: Fix error values in case of bad_stack MIPS: Sanitize restart logics MIPS: secure_computing, syscall audit: syscall number should in r2, not r0. MIPS: Don't block signals if we'd failed to setup a sigframe
2010-10-18MIPS: do_sigaltstack() expects userland pointersAl Viro
o32 compat does the right thing, native and n32 compat do not... Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Cc: linux-kernel@vger.kernel.org Cc: linux-arch@vger.kernel.org Cc: linux-mips@linux-mips.org Patchwork: http://patchwork.linux-mips.org/patch/1700/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-10-18MIPS: Fix error values in case of bad_stackAl Viro
We want EFAULT, not -<syscall number> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Cc: linux-kernel@vger.kernel.org Cc: linux-arch@vger.kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/1699/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-10-18MIPS: Sanitize restart logicsAl Viro
Put the original syscall number into ->regs[0] when we leave syscall with error. Use it in restart logics. Everything else will have it 0 since we pass through SAVE_SOME on all the ways in. Note that in places like bad_stack and inllegal_syscall we leave it 0 - it's not restartable. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Cc: linux-kernel@vger.kernel.org Cc: linux-arch@vger.kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/1698/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-10-18MIPS: secure_computing, syscall audit: syscall number should in r2, not r0.Al Viro
As it is, audit_syscall_entry() and secure_computing() get the bogus value (0, in fact) Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Cc: linux-kernel@vger.kernel.org Cc: linux-arch@vger.kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/1697/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-10-18MIPS: Don't block signals if we'd failed to setup a sigframeAl Viro
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Cc: linux-kernel@vger.kernel.org Cc: linux-arch@vger.kernel.org Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/1696/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-10-04MIPS: Fix syscall 64 bit number comments.Ralf Baechle
Noticed and original patch by Philby John <pjohn@mvista.com>. Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-10-04MIPS: Hookup fanotify_init, fanotify_mark, and prlimit64 syscalls.David Daney
Signed-off-by: David Daney <ddaney@caviumnetworks.com> To: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/1553/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-10-04MIPS: N32: Fix getdents64 syscall for n32Bernhard Walle
Commit 31c984a5acabea5d8c7224dc226453022be46f33 introduced a new syscall getdents64. However, in the syscall table, the new syscall still refers to the old getdents which doesn't work. The problem appeared with a system that uses the eglibc 2.12-r11187 (that utilizes that new syscall) is very confused. The fix has been tested with that eglibc version. Signed-off-by: Bernhard Walle <walle@corscience.de> To: linux-mips@linux-mips.org Cc: ddaney@caviumnetworks.com Cc: akpm@linux-foundation.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/1567/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-10-04MIPS: Remove pr_<level> uses of KERN_<level>Joe Perches
These would result in KERN_<level> actually getting printed. Signed-off-by: Joe Perches <joe@perches.com> To: Jiri Kosina <trivial@kernel.org> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/1581/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-10-04MIPS: GIC: Remove dependencies from Malta files.Ralf Baechle
This prevents the GIC code from being reusable sanely. Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-10-04MIPS: kspd: Adjust confusing if indentationJulia Lawall
Indent the branch of an if. The semantic match that finds this problem is as follows: (http://coccinelle.lip6.fr/) // <smpl> @r disable braces4@ position p1,p2; statement S1,S2; @@ ( if (...) { ... } | if (...) S1@p1 S2@p2 ) @script:python@ p1 << r.p1; p2 << r.p2; @@ if (p1[0].column == p2[0].column): cocci.print_main("branch",p1) cocci.print_secs("after",p2) // </smpl> Signed-off-by: Julia Lawall <julia@diku.dk> To: linux-mips@linux-mips.org To: linux-kernel@vger.kernel.org To: kernel-janitors@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/1539/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-10-04MIPS: Fix a typo.Andrea Gelmini
"Userpace" -> "Userspace" Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Cc: Andrea Gelmini <andrea.gelmini@gelma.net> Cc: Jason Wessel <jason.wessel@windriver.com> Cc: Martin Hicks <mort@sgi.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/1536/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-08-17Make do_execve() take a const filename pointerDavid Howells
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-13Mark arguments to certain syscalls as being constDavid Howells
Mark arguments to certain system calls as being const where they should be but aren't. The list includes: (*) The filename arguments of various stat syscalls, execve(), various utimes syscalls and some mount syscalls. (*) The filename arguments of some syscall helpers relating to the above. (*) The buffer argument of various write syscalls. Signed-off-by: David Howells <dhowells@redhat.com> Acked-by: David S. Miller <davem@davemloft.net> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2010-08-05Merge branch 'for_linus' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/jwessel/linux-2.6-kgdb * 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jwessel/linux-2.6-kgdb: debug_core,kdb: fix crash when arch does not have single step kgdb,x86: use macro HBP_NUM to replace magic number 4 kgdb,mips: remove unused kgdb_cpu_doing_single_step operations mm,kdb,kgdb: Add a debug reference for the kdb kmap usage KGDB: Remove set but unused newPC ftrace,kdb: Allow dumping a specific cpu's buffer with ftdump ftrace,kdb: Extend kdb to be able to dump the ftrace buffer kgdb,powerpc: Replace hardcoded offset by BREAK_INSTR_SIZE arm,kgdb: Add ability to trap into debugger on notify_die gdbstub: do not directly use dbg_reg_def[] in gdb_cmd_reg_set() gdbstub: Implement gdbserial 'p' and 'P' packets kgdb,arm: Individual register get/set for arm kgdb,mips: Individual register get/set for mips kgdb,x86: Individual register get/set for x86 kgdb,kdb: individual register set and and get API gdbstub: Optimize kgdb's "thread:" response for the gdb serial protocol kgdb: remove custom hex_to_bin()implementation
2010-08-05kgdb,mips: remove unused kgdb_cpu_doing_single_step operationsJason Wessel
The mips kgdb specific code does not support software or HW single stepping so it should not implement Signed-off-by: Jason Wessel <jason.wessel@windriver.com> Signed-off-by: Dongdong Deng <dongdong.deng@windriver.com> Acked-by: Ralf Baechle <ralf@linux-mips.org> CC: linux-mips@linux-mips.org
2010-08-05kgdb,mips: Individual register get/set for mipsJason Wessel
Implement the ability to individually get and set registers for kdb and kgdb for mips. Signed-off-by: Jason Wessel <jason.wessel@windriver.com> Acked-by: Ralf Baechle <ralf@linux-mips.org> CC: linux-mips@linux-mips.org
2010-08-05MIPS: Clean up notify_die() usage.David Daney
The sixth argument of notify_die() is a signal number, the fifth is a trap number. Instead of passing a signal number in a randomly selected argument, pass it in the sixth. Extract the exception code from regs and pass that as the trap number. Get rid of redundant cast, and remove some gratuitous spaces. Nobody actually does anything with the signal number or trap number, but we might as well populate them with sensible values. Signed-off-by: David Daney <ddaney@caviumnetworks.com> To: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/1532/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-08-05MIPS: Remove unused task_struct.trap_no field.David Daney
It is initialized to zero and only ever read. Remove it, and pass zero in its place. Signed-off-by: David Daney <ddaney@caviumnetworks.com> To: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/1531/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-08-05MIPS: kprobe: Add support.David Daney
This patch is based on previous work by Sony and Himanshu Chauhan. I have done some cleanup and implemented JProbes and KRETPROBES. The KRETPROBES part is pretty much copied verbatim from powerpc. A possible future enhance might be to factor out the common code. Signed-off-by: David Daney <ddaney@caviumnetworks.com> Cc: Himanshu Chauhan <hschauhan@nulltrace.org> To: linux-mips@linux-mips.org To: ananth@in.ibm.com, To: anil.s.keshavamurthy@intel.com To: davem@davemloft.net To: masami.hiramatsu.pt@hitachi.com Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/1525/ Patchwork: https://patchwork.linux-mips.org/patch/1530/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-08-05MIPS: Decode core number for R2 CPUs.David Daney
The struct cpuinfo_mips.core field should be populated with the physical core number. For R2 CPUs, this is carried in the low 10 bits of Ebase. Signed-off-by: David Daney <ddaney@caviumnetworks.com> To: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/1505/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-08-05MIPS: SMTC: Use %p to format pointersKulikov Vasiliy
While at it, drop 0x prefix. Signed-off-by: Kulikov Vasiliy <segooon@gmail.com> To: kernel-janitors@vger.kernel.org Cc: Chris Dearman <chris@mips.com> Cc: "Robert P. J. Day" <rpjday@crashcourse.ca> Cc: Rusty Russell <rusty@rustcorp.com.au> Cc: André Goddard Rosa <andre.goddard@gmail.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/1458/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-08-05MIPS: Export __cpu_number_map and __cpu_logical_map.David Daney
The forthcoming Octeon watchdog driver will use them. Signed-off-by: David Daney <ddaney@caviumnetworks.com> To: linux-mips@linux-mips.org To: wim@iguana.be Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/1499/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-08-05MIPS: uasm: Add option to export uasm API.David Daney
A 'select EXPORT_UASM' in Kconfig will cause the uasm to be exported for use in modules. When it is exported, all the uasm data and code cease to be __init and __initdata. Also daddiu_bug cannot be __cpuinitdata if uasm is exported. The cleanest thing is to just make it normal data. Signed-off-by: David Daney <ddaney@caviumnetworks.com> To: linux-mips@linux-mips.org To: wim@iguana.be Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/1500/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-08-05MIPS: JZ4740: Add base support for Ingenic JZ4740 System-on-a-ChipLars-Peter Clausen
Adds a new cpu type for the JZ4740 to the Linux MIPS architecture code. It also adds the iomem addresses for the different components found on a JZ4740 SoC. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org Patchwork: https://patchwork.linux-mips.org/patch/1464/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-08-05MIPS: tracing: Fix the indentation of mcount.SWu Zhangjin
The commit "MIPS: Tracing: Cleanup the arguments passing of prepare_ftrace_return" has moved the "jal prepare_ftrace_return" instruction after the handling of the 3rd argument but forgot to remove the superfluous space before the related instructions. Signed-off-by: Wu Zhangjin <wuzhangjin@gmail.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/1475/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-08-05MIPS: Enable heap randomization.David Daney
Based somewhat on the PPC implementation. 32-bit processes have the heap randomized in an 8MB space, 256MB for 64-bit processes. Signed-off-by: David Daney <ddaney@caviumnetworks.com> To: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/1479/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-08-05MIPS: Randomize mmap if randomize_va_space is setDavid Daney
Fairly straight forward: For 32-bit address spaces randomize within a 16MB space, for 64-bit within a 256MB space. Signed-off-by: David Daney <ddaney@caviumnetworks.com> To: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/1480/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-08-05MIPS: Provide more elevant interface cu2_notifier for CP2 extensions.Ralf Baechle
Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Signed-off-by: David Daney <ddaney@caviumnetworks.com> Patchwork: https://patchwork.linux-mips.org/patch/1504/
2010-08-05MIPS: Add -Werror to arch/mips/KbuildSam Ravnborg
Adding subdirs-ccflags-y := -Werror to arch/mips/Kbuild let us in one go cover all files with -Werror. In addition this allows us to remove the individual -Werror definition in various Makefile. Adding the definition to Kbuild as a recursive option help us not to forget to do so. With this change we now compile arch/mips/kernel/cpufreq with -Werror One drawback: When specifying a subdirectory covered by the Kbuild file like this: make arch/mips/kernel/ then kbuild fails to pick up the -Werror definition. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> To: linux-mips <linux-mips@linux-mips.org> To: Wu Zhangjin <wuzhangjin@gmail.com> Patchwork: https://patchwork.linux-mips.org/patch/1301/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-08-05MIPS: N32: Fix syscall number comments.David Daney
Signed-off-by: David Daney <ddaney@caviumnetworks.com> To: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/1515/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-08-05MIPS: Don't overflow cevt-r4k.c calculations at high clock rates.David Daney
The 'mult' element of struct clock_event_device must never be wider than 32-bits. If it were, it would get truncated when used by clockevent_delta2ns() when this calls do_div(). We can meet this requirement by using clockevent_set_clock() to set the MULT and SHIFT values. Signed-off-by: David Daney <ddaney@caviumnetworks.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/1253/ Acked-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-07-26MIPS: N32: Define getdents64.Ralf Baechle
As a relativly new ABI N32 should only have received the getdents64(2) but instead it only had getdents(2). This was noticed as a performance anomaly in glibc. Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-07-26MIPS: Make init_vdso a subsys_initcall.David Daney
Quoting from Jiri Slaby's patch of a similar nature for x86: When initrd is in use and a driver does request_module() in its module_init (i.e. __initcall or device_initcall), a modprobe process is created with VDSO mapping. But VDSO is inited even in __initcall, i.e. on the same level (at the same time), so it may not be inited yet (link order matters). Move init_vdso up to subsys_initcall to avoid the issue. Signed-off-by: David Daney <ddaney@caviumnetworks.com> To: linux-mips@linux-mips.org Cc: David Daney <ddaney@caviumnetworks.com> Cc: Jiri Slaby <jslaby@suse.cz> Patchwork: http://patchwork.linux-mips.org/patch/1386/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-07-26MIPS: "Fix" useless 'init_vdso successfully' message.David Daney
In addition to being useless, it was mis-spelled. Signed-off-by: David Daney <ddaney@caviumnetworks.com> To: linux-mips@linux-mips.org Cc: David Daney <ddaney@caviumnetworks.com> Patchwork: http://patchwork.linux-mips.org/patch/1385/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-07-05MIPS: Return after handling coprocessor 2 exceptionJesper Nilsson
Breaking here dropped us to the default code which always sends a SIGILL to the current process, no matter what the CU2 notifier says. [Ralf: Currently this only hurts on Cavium and possibly some out of tree platforms.] Signed-off-by: Jesper Nilsson <jesper@jni.nu> To: linux-mips@linux-mips.org To: linux-kernel@vger.kernel.org Patchwork: http://patchwork.linux-mips.org/patch/1391/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-07-05MIPS: MT: Fix FPU affinity.Ralf Baechle
The fragile MT sys_sched_setaffinity wrapper needs its regular dose of fixes. Nose-poked-at-pile-o-crap-by: Julia Lawall <julia@diku.dk> Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-07-05MIPS: Tracing: Cleanup of address space checkingWu Zhangjin
This patch adds an inline function in_module() to check which space the instruction pointer in, kernel space or module space. Note: This will not work when the kernel space and module space are the same. If they are the same, we need to modify scripts/recordmcount.pl, ftrace_make_nop/call() and the other related parts to ensure the enabling/disabling of the calling site to _mcount is right for both kernel and module. [Ralf: It also is still incorrect for some 64-bit kernels.] Signed-off-by: Wu Zhangjin <wuzhangjin@gmail.com> Cc: linux-mips <linux-mips@linux-mips.org> Cc: David Daney <david.s.daney@gmail.com> Patchwork: http://patchwork.linux-mips.org/patch/1232/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-07-05MIPS: Tracing: Cleanup of function graph tracerWu Zhangjin
Cleans up comments and ftrace_get_parent_addr() of function graph tracer. Signed-off-by: Wu Zhangjin <wuzhangjin@gmail.com> Cc: linux-mips <linux-mips@linux-mips.org> Cc: David Daney <david.s.daney@gmail.com> Patchwork: http://patchwork.linux-mips.org/patch/1231/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-07-05MIPS: Tracing: Reduce the overhead of dynamic Function TracerWu Zhangjin
With the help of uasm this patch encodes the instructions of the dynamic function tracer in ftrace_dyn_arch_init() when initializing it. As a result we can remove the dynamic encoding of instructions in ftrace_make_nop()/call(), ftrace_enable_ftrace_graph_caller() and remove the macro jump_insn_encode() and at last this reduce the overhead of dynamic Function Tracer. This also is cleaner. Signed-off-by: Wu Zhangjin <wuzhangjin@gmail.com> Cc: linux-mips <linux-mips@linux-mips.org> Cc: David Daney <david.s.daney@gmail.com> Patchwork: http://patchwork.linux-mips.org/patch/1230/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-07-05MIPS: Tracing: Cleanup of instructions usedWu Zhangjin
This patch adds some cleanups of the instructions: o use macros instead of magic numbers o use macros instead of variables to reduce some overhead o add new macro for the jal instruction Signed-off-by: Wu Zhangjin <wuzhangjin@gmail.com> Cc: linux-mips <linux-mips@linux-mips.org> Cc: David Daney <david.s.daney@gmail.com> Patchwork: http://patchwork.linux-mips.org/patch/1229/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-07-05MIPS: Tracing: Fix 32-bit support with -mmcount-ra-addressWu Zhangjin
For 32-bit kernel the -mmcount-ra-address option of gcc 4.5 emits one extra instruction before calling to _mcount so we need to use a different "b 1f" for it. Signed-off-by: Wu Zhangjin <wuzhangjin@gmail.com> Cc: linux-mips <linux-mips@linux-mips.org> Cc: David Daney <david.s.daney@gmail.com> Patchwork: http://patchwork.linux-mips.org/patch/1228/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-07-05MIPS: Tracing: Fix argument passing of the 32bit support with gcc 4.5Wu Zhangjin
As documented in the GCC 4.5 docs [1] -mmcount-ra-address uses register $12 to pass the stack offset of the return address to the _mcount function. On 64-bit kernels $12 is t0 but in 32-bit kernels it is t4 so we need to use $12 instead of t0 here to be correct for both kernel types. [1] GCC documentation: MIPS Options http://gcc.gnu.org/onlinedocs/gcc/MIPS-Options.html Signed-off-by: Wu Zhangjin <wuzhangjin@gmail.com> Cc: linux-mips <linux-mips@linux-mips.org> Cc: David Daney <david.s.daney@gmail.com> Patchwork: http://patchwork.linux-mips.org/patch/1227/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-07-05MIPS: Tracing: Cleanup commentsWu Zhangjin
Signed-off-by: Wu Zhangjin <wuzhangjin@gmail.com> Cc: linux-mips <linux-mips@linux-mips.org> Cc: David Daney <david.s.daney@gmail.com> Patchwork: http://patchwork.linux-mips.org/patch/1225/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-07-05MIPS: Tracing: Cleanup the arguments passing of prepare_ftrace_returnWu Zhangjin
Signed-off-by: Wu Zhangjin <wuzhangjin@gmail.com> Cc: linux-mips <linux-mips@linux-mips.org> Cc: David Daney <david.s.daney@gmail.com> Patchwork: http://patchwork.linux-mips.org/patch/1226/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-07-05MIPS: Tracing: Merge adjacent #ifdefs with same condition.Wu Zhangjin
Signed-off-by: Wu Zhangjin <wuzhangjin@gmail.com> Cc: linux-mips <linux-mips@linux-mips.org> Cc: David Daney <david.s.daney@gmail.com> Patchwork: http://patchwork.linux-mips.org/patch/1224/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2010-05-21Merge branch 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linusLinus Torvalds
* 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus: (25 commits) MIPS: Use GCC __builtin_prefetch() to implement prefetch(). MIPS: Octeon: Serial port fixes for OCTEON simulator. MIPS: Octeon: Get rid of early serial. MIPS: AR7: prevent race between clock initialization and devices registration MIPS: AR7: use ar7_has_high_vlynq() to determine watchdog base address MIPS: BCM63xx: Avoid namespace clash on GPIO_DIR_{IN,OUT} MIPS: MTX-1: Update defconfig MIPS: BCM47xx: Update defconfig MIPS: RB532: Update defconfig MIPS: AR7: Update defconfig RTC: rtc-cmos: Fix binary mode support MIPS: Oprofile: Loongson: Cleanup the comments MIPS: Oprofile: Loongson: Cleanup of the macros MIPS: Oprofile: Loongson: Remove unused variable from loongson2_cpu_setup() MIPS: Oprofile: Loongson: Remove useless parentheses MIPS: Oprofile: Loongson: Unify macro for setting events MIPS: nofpu and nodsp only affect CPU0 MIPS: Clean up tables for bootmem allocation MIPS: Coding style cleanups of access of FCSR rounding mode bits MIPS: Loongson 2F: Add gpio/gpioilb support ...