diff options
| -rw-r--r-- | include/linux/mm.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/include/linux/mm.h b/include/linux/mm.h index c080af584ddd..c6fa9a255dbf 100644 --- a/include/linux/mm.h +++ b/include/linux/mm.h | |||
| @@ -2466,6 +2466,13 @@ static inline vm_fault_t vmf_insert_pfn(struct vm_area_struct *vma, | |||
| 2466 | return VM_FAULT_NOPAGE; | 2466 | return VM_FAULT_NOPAGE; |
| 2467 | } | 2467 | } |
| 2468 | 2468 | ||
| 2469 | static inline vm_fault_t vmf_error(int err) | ||
| 2470 | { | ||
| 2471 | if (err == -ENOMEM) | ||
| 2472 | return VM_FAULT_OOM; | ||
| 2473 | return VM_FAULT_SIGBUS; | ||
| 2474 | } | ||
| 2475 | |||
| 2469 | struct page *follow_page_mask(struct vm_area_struct *vma, | 2476 | struct page *follow_page_mask(struct vm_area_struct *vma, |
| 2470 | unsigned long address, unsigned int foll_flags, | 2477 | unsigned long address, unsigned int foll_flags, |
| 2471 | unsigned int *page_mask); | 2478 | unsigned int *page_mask); |
