diff options
Diffstat (limited to 'arch/arm/mm/fault.c')
-rw-r--r-- | arch/arm/mm/fault.c | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/arch/arm/mm/fault.c b/arch/arm/mm/fault.c index c5e0622c7765..f0943d160ffe 100644 --- a/arch/arm/mm/fault.c +++ b/arch/arm/mm/fault.c | |||
@@ -131,10 +131,11 @@ __do_user_fault(struct task_struct *tsk, unsigned long addr, | |||
131 | force_sig_info(sig, &si, tsk); | 131 | force_sig_info(sig, &si, tsk); |
132 | } | 132 | } |
133 | 133 | ||
134 | void | 134 | void do_bad_area(unsigned long addr, unsigned int fsr, struct pt_regs *regs) |
135 | do_bad_area(struct task_struct *tsk, struct mm_struct *mm, unsigned long addr, | ||
136 | unsigned int fsr, struct pt_regs *regs) | ||
137 | { | 135 | { |
136 | struct task_struct *tsk = current; | ||
137 | struct mm_struct *mm = tsk->active_mm; | ||
138 | |||
138 | /* | 139 | /* |
139 | * If we are in kernel mode at this point, we | 140 | * If we are in kernel mode at this point, we |
140 | * have no context to handle this fault with. | 141 | * have no context to handle this fault with. |
@@ -319,7 +320,6 @@ static int | |||
319 | do_translation_fault(unsigned long addr, unsigned int fsr, | 320 | do_translation_fault(unsigned long addr, unsigned int fsr, |
320 | struct pt_regs *regs) | 321 | struct pt_regs *regs) |
321 | { | 322 | { |
322 | struct task_struct *tsk; | ||
323 | unsigned int index; | 323 | unsigned int index; |
324 | pgd_t *pgd, *pgd_k; | 324 | pgd_t *pgd, *pgd_k; |
325 | pmd_t *pmd, *pmd_k; | 325 | pmd_t *pmd, *pmd_k; |
@@ -351,9 +351,7 @@ do_translation_fault(unsigned long addr, unsigned int fsr, | |||
351 | return 0; | 351 | return 0; |
352 | 352 | ||
353 | bad_area: | 353 | bad_area: |
354 | tsk = current; | 354 | do_bad_area(addr, fsr, regs); |
355 | |||
356 | do_bad_area(tsk, tsk->active_mm, addr, fsr, regs); | ||
357 | return 0; | 355 | return 0; |
358 | } | 356 | } |
359 | 357 | ||
@@ -364,8 +362,7 @@ bad_area: | |||
364 | static int | 362 | static int |
365 | do_sect_fault(unsigned long addr, unsigned int fsr, struct pt_regs *regs) | 363 | do_sect_fault(unsigned long addr, unsigned int fsr, struct pt_regs *regs) |
366 | { | 364 | { |
367 | struct task_struct *tsk = current; | 365 | do_bad_area(addr, fsr, regs); |
368 | do_bad_area(tsk, tsk->active_mm, addr, fsr, regs); | ||
369 | return 0; | 366 | return 0; |
370 | } | 367 | } |
371 | 368 | ||