From fa0d1dbf7fb6b6f1af85d298a4054fe9edc914c9 Mon Sep 17 00:00:00 2001 From: Russell King Date: Fri, 30 Mar 2012 11:51:46 +0100 Subject: ARM: fix missing bug.h include in arch/arm/kernel/insn.c arch/arm/kernel/insn.c: In function '__arm_gen_branch_thumb2': arch/arm/kernel/insn.c:13: error: implicit declaration of function 'WARN_ON_ONCE' Signed-off-by: Russell King --- arch/arm/kernel/insn.c | 1 + 1 file changed, 1 insertion(+) (limited to 'arch') diff --git a/arch/arm/kernel/insn.c b/arch/arm/kernel/insn.c index ab312e51654..b760340b701 100644 --- a/arch/arm/kernel/insn.c +++ b/arch/arm/kernel/insn.c @@ -1,3 +1,4 @@ +#include #include #include -- cgit v1.2.3 From 5a4f5da543b169d555a19e889850780ddceb8f98 Mon Sep 17 00:00:00 2001 From: Will Deacon Date: Tue, 21 Feb 2012 12:29:03 +0100 Subject: ARM: 7337/1: ptrace: fix ptrace_read_user for !CONFIG_MMU platforms Commit 68b7f715 ("nommu: ptrace support") added definitions for PT_TEXT_ADDR and friends, as well as adding ptrace support for reading from these magic offsets. Unfortunately, this has probably never worked, since ptrace_read_user predicates reading on off < sizeof(struct user), returning -EIO otherwise. This patch moves the offset size check until after we have tried to match it against either a magic value or an offset into pt_regs. Cc: Paul Brook Signed-off-by: Will Deacon Signed-off-by: Russell King --- arch/arm/kernel/ptrace.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'arch') diff --git a/arch/arm/kernel/ptrace.c b/arch/arm/kernel/ptrace.c index 45956c9d0ef..80abafb9bf3 100644 --- a/arch/arm/kernel/ptrace.c +++ b/arch/arm/kernel/ptrace.c @@ -256,7 +256,7 @@ static int ptrace_read_user(struct task_struct *tsk, unsigned long off, { unsigned long tmp; - if (off & 3 || off >= sizeof(struct user)) + if (off & 3) return -EIO; tmp = 0; @@ -268,6 +268,8 @@ static int ptrace_read_user(struct task_struct *tsk, unsigned long off, tmp = tsk->mm->end_code; else if (off < sizeof(struct pt_regs)) tmp = get_user_reg(tsk, off >> 2); + else if (off >= sizeof(struct user)) + return -EIO; return put_user(tmp, ret); } -- cgit v1.2.3 From 3eb8d7099064ae61fa821d690d085abb8b7c4810 Mon Sep 17 00:00:00 2001 From: Russell King Date: Fri, 30 Mar 2012 21:03:54 +0100 Subject: ARM: fix bios32.c build warning arch/arm/kernel/bios32.c: In function 'pcibios_fixup_bus': arch/arm/kernel/bios32.c:302: warning: unused variable 'root' caused by 9f786d033 (arm/PCI: get rid of device resource fixups) Signed-off-by: Russell King --- arch/arm/kernel/bios32.c | 1 - 1 file changed, 1 deletion(-) (limited to 'arch') diff --git a/arch/arm/kernel/bios32.c b/arch/arm/kernel/bios32.c index 632df9a66f8..ede5f7741c4 100644 --- a/arch/arm/kernel/bios32.c +++ b/arch/arm/kernel/bios32.c @@ -299,7 +299,6 @@ static inline int pdev_bad_for_parity(struct pci_dev *dev) */ void pcibios_fixup_bus(struct pci_bus *bus) { - struct pci_sys_data *root = bus->sysdata; struct pci_dev *dev; u16 features = PCI_COMMAND_SERR | PCI_COMMAND_PARITY | PCI_COMMAND_FAST_BACK; -- cgit v1.2.3 From 6d008893e45ad5957a9a31afa00c4c6582504fe5 Mon Sep 17 00:00:00 2001 From: Russell King Date: Sat, 31 Mar 2012 09:07:30 +0100 Subject: ARM: fix more fallout from 9f97da78bf (Disintegrate asm/system.h for ARM) arch/arm/kernel/io.c: In function '_memcpy_toio': arch/arm/kernel/io.c:29: error: implicit declaration of function 'outer_sync' arch/arm/mach-omap2/omap_l3_noc.c: In function 'l3_interrupt_handler': arch/arm/mach-omap2/omap_l3_noc.c:100: error: implicit declaration of function 'outer_sync' kernel/irq/generic-chip.c: In function 'irq_gc_mask_disable_reg': kernel/irq/generic-chip.c:45: error: implicit declaration of function 'outer_sync' kernel/sched/rt.c: In function 'rt_set_overload': kernel/sched/rt.c:248: error: implicit declaration of function 'outer_sync' ... Signed-off-by: Russell King --- arch/arm/mach-omap2/include/mach/barriers.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'arch') diff --git a/arch/arm/mach-omap2/include/mach/barriers.h b/arch/arm/mach-omap2/include/mach/barriers.h index 4fa72c7cc7c..1c582a8592b 100644 --- a/arch/arm/mach-omap2/include/mach/barriers.h +++ b/arch/arm/mach-omap2/include/mach/barriers.h @@ -22,6 +22,8 @@ #ifndef __MACH_BARRIERS_H #define __MACH_BARRIERS_H +#include + extern void omap_bus_sync(void); #define rmb() dsb() -- cgit v1.2.3