Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3b9cf77d authored by Kirill A. Shutemov's avatar Kirill A. Shutemov Committed by Linus Torvalds
Browse files

frv: handle pgtable_page_ctor() fail

parent 0da5303b
Loading
Loading
Loading
Loading
+8 −4
Original line number Diff line number Diff line
@@ -37,11 +37,15 @@ pgtable_t pte_alloc_one(struct mm_struct *mm, unsigned long address)
#else
	page = alloc_pages(GFP_KERNEL|__GFP_REPEAT, 0);
#endif
	if (page) {
	if (!page)
		return NULL;

	clear_highpage(page);
		pgtable_page_ctor(page);
		flush_dcache_page(page);
	if (!pgtable_page_ctor(page)) {
		__free_page(page);
		return NULL;
	}
	flush_dcache_page(page);
	return page;
}