projects
/
firefly-linux-kernel-4.4.55.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
[NETFILTER]: remove remaining ASSERT_{READ,WRITE}_LOCK
[firefly-linux-kernel-4.4.55.git]
/
mm
/
hugetlb.c
diff --git
a/mm/hugetlb.c
b/mm/hugetlb.c
index 2dbec90dc3bad98cab038db4513f566360e8de8d..a088f593a807532aa9b37307a04b5427becfd449 100644
(file)
--- a/
mm/hugetlb.c
+++ b/
mm/hugetlb.c
@@
-478,6
+478,9
@@
int hugetlb_no_page(struct mm_struct *mm, struct vm_area_struct *vma,
retry:
page = find_lock_page(mapping, idx);
if (!page) {
+ size = i_size_read(mapping->host) >> HPAGE_SHIFT;
+ if (idx >= size)
+ goto out;
if (hugetlb_get_quota(mapping))
goto out;
page = alloc_huge_page(vma, address);