Commit 1265755d authored by Linus Torvalds's avatar Linus Torvalds

Fix TASK_SIZE range check that got lost in recent

clear_page_range()/4-level page table updates.
parent 714d25d2
......@@ -1484,6 +1484,9 @@ static void free_pgtables(struct mmu_gather *tlb, struct vm_area_struct *prev,
unsigned long last = end + PGDIR_SIZE - 1;
struct mm_struct *mm = tlb->mm;
if (last > TASK_SIZE || last < end)
last = TASK_SIZE;
if (!prev) {
prev = mm->mmap;
if (!prev)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment