diff options
Diffstat (limited to 'arch/parisc/mm/fault.c')
-rw-r--r-- | arch/parisc/mm/fault.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/arch/parisc/mm/fault.c b/arch/parisc/mm/fault.c index f247a3480e8e..d10d27a720c0 100644 --- a/arch/parisc/mm/fault.c +++ b/arch/parisc/mm/fault.c | |||
@@ -180,6 +180,10 @@ void do_page_fault(struct pt_regs *regs, unsigned long code, | |||
180 | if (in_atomic() || !mm) | 180 | if (in_atomic() || !mm) |
181 | goto no_context; | 181 | goto no_context; |
182 | 182 | ||
183 | if (user_mode(regs)) | ||
184 | flags |= FAULT_FLAG_USER; | ||
185 | if (acc_type & VM_WRITE) | ||
186 | flags |= FAULT_FLAG_WRITE; | ||
183 | retry: | 187 | retry: |
184 | down_read(&mm->mmap_sem); | 188 | down_read(&mm->mmap_sem); |
185 | vma = find_vma_prev(mm, address, &prev_vma); | 189 | vma = find_vma_prev(mm, address, &prev_vma); |
@@ -203,8 +207,7 @@ good_area: | |||
203 | * fault. | 207 | * fault. |
204 | */ | 208 | */ |
205 | 209 | ||
206 | fault = handle_mm_fault(mm, vma, address, | 210 | fault = handle_mm_fault(mm, vma, address, flags); |
207 | flags | ((acc_type & VM_WRITE) ? FAULT_FLAG_WRITE : 0)); | ||
208 | 211 | ||
209 | if ((fault & VM_FAULT_RETRY) && fatal_signal_pending(current)) | 212 | if ((fault & VM_FAULT_RETRY) && fatal_signal_pending(current)) |
210 | return; | 213 | return; |