Skip to content

Commit f2057b4

Browse files
davidhildenbrandhcahca
authored andcommitted
s390/vmemmap: fallback to PTEs if mapping large PMD fails
Let's fallback to single pages if short on huge pages. No need to stop memory hotplug. Cc: Vasily Gorbik <[email protected]> Cc: Christian Borntraeger <[email protected]> Cc: Gerald Schaefer <[email protected]> Signed-off-by: David Hildenbrand <[email protected]> Message-Id: <[email protected]> Signed-off-by: Heiko Carstens <[email protected]>
1 parent b9ff810 commit f2057b4

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

arch/s390/mm/vmem.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -180,10 +180,10 @@ static int __ref modify_pmd_table(pud_t *pud, unsigned long addr,
180180
*/
181181
new_page = vmemmap_alloc_block(PMD_SIZE,
182182
NUMA_NO_NODE);
183-
if (!new_page)
184-
goto out;
185-
pmd_val(*pmd) = __pa(new_page) | prot;
186-
continue;
183+
if (new_page) {
184+
pmd_val(*pmd) = __pa(new_page) | prot;
185+
continue;
186+
}
187187
}
188188
pte = vmem_pte_alloc();
189189
if (!pte)

0 commit comments

Comments
 (0)