Thread (17 messages) 17 messages, 4 authors, 2021-10-01

Re: [PATCH v2 4/4] hugetlb: add hugetlb demote page support

From: Mike Kravetz <hidden>
Date: 2021-09-29 20:28:11
Also in: lkml

On 9/24/21 2:44 AM, David Hildenbrand wrote:
On 23.09.21 19:53, Mike Kravetz wrote:
quoted
+
+    if (alloc_huge_page_vmemmap(h, page)) {
+        /* Allocation of vmemmmap failed, we can not demote page */
+        spin_lock_irq(&hugetlb_lock);
+        set_page_refcounted(page);
+        add_hugetlb_page(h, page, false);
I dislike using 0/1 as return values as it will just hide the actual issue.

This here would be -ENOMEM, right?
I will pass along the return value from alloc_huge_page_vmemmap().  You
are right, -ENOMEM is the only non-zero value.

Thanks,
-- 
Mike Kravetz
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help