Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 360622
b: refs/heads/master
c: b255188
h: refs/heads/master
v: v3
  • Loading branch information
Russell King committed Feb 25, 2013
1 parent fb3c34e commit 028859f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 8 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 5e4ba617c1b584b2e376f31a63bd4e734109318a
refs/heads/master: b255188f90e2bade1bd11a986dd1ca4861869f4d
11 changes: 4 additions & 7 deletions trunk/arch/arm/mm/alignment.c
Original file line number Diff line number Diff line change
Expand Up @@ -749,7 +749,6 @@ do_alignment(unsigned long addr, unsigned int fsr, struct pt_regs *regs)
unsigned long instr = 0, instrptr;
int (*handler)(unsigned long addr, unsigned long instr, struct pt_regs *regs);
unsigned int type;
mm_segment_t fs;
unsigned int fault;
u16 tinstr = 0;
int isize = 4;
Expand All @@ -760,16 +759,15 @@ do_alignment(unsigned long addr, unsigned int fsr, struct pt_regs *regs)

instrptr = instruction_pointer(regs);

fs = get_fs();
set_fs(KERNEL_DS);
if (thumb_mode(regs)) {
fault = __get_user(tinstr, (u16 *)(instrptr & ~1));
u16 *ptr = (u16 *)(instrptr & ~1);
fault = probe_kernel_address(ptr, tinstr);
if (!fault) {
if (cpu_architecture() >= CPU_ARCH_ARMv7 &&
IS_T32(tinstr)) {
/* Thumb-2 32-bit */
u16 tinst2 = 0;
fault = __get_user(tinst2, (u16 *)(instrptr+2));
fault = probe_kernel_address(ptr + 1, tinst2);
instr = (tinstr << 16) | tinst2;
thumb2_32b = 1;
} else {
Expand All @@ -778,8 +776,7 @@ do_alignment(unsigned long addr, unsigned int fsr, struct pt_regs *regs)
}
}
} else
fault = __get_user(instr, (u32 *)instrptr);
set_fs(fs);
fault = probe_kernel_address(instrptr, instr);

if (fault) {
type = TYPE_FAULT;
Expand Down

0 comments on commit 028859f

Please sign in to comment.