<div dir="ltr"><div dir="ltr"><div class="gmail_default" style="font-size:small"><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, Apr 22, 2020 at 7:40 PM Jan Stancek <<a href="mailto:jstancek@redhat.com">jstancek@redhat.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">/sys/kernel/mm/hugepages is not present when there are no<br>
supported hugepage sizes. This is common for ppc64le KVM guests,<br>
when hypervisor does not enable hugepages. Guest will boot with:<br>
hugetlbfs: disabling because there are no supported hugepage sizes<br>
<br>
# cat /proc/filesystems | grep huge; echo $?<br>
1<br>
<br>
Move the check up in setup to check it as first thing to avoid<br>
running into TBROK on mount or set_sys_tune when hugetlbfs is<br>
not available:<br>
safe_macros.c:766: BROK: hugemmap01.c:82: mount(none, /mnt/testarea/ltp-07Kg6lCOmm/Ai9D0M, hugetlbfs, 0, (nil)) failed: ENODEV (19)<br>
safe_macros.c:766: BROK: hugemmap02.c:129: mount(none, /mnt/testarea/ltp-07Kg6lCOmm/Cxf7A6, hugetlbfs, 0, (nil)) failed: ENODEV (19)<br>
safe_macros.c:766: BROK: hugemmap04.c:100: mount(none, /mnt/testarea/ltp-07Kg6lCOmm/kS60Mk, hugetlbfs, 0, (nil)) failed: ENODEV (19)<br>
safe_file_ops.c:219: BROK: Expected 1 conversions got 0 at hugemmap06.c:42<br>
safe_file_ops.c:155: BROK: The FILE '/proc/sys/vm/nr_hugepages' ended prematurely at mem.c:836<br>
safe_file_ops.c:219: BROK: Expected 1 conversions got 0 at hugeshmat05.c:39<br>
<br>
Signed-off-by: Jan Stancek <<a href="mailto:jstancek@redhat.com" target="_blank">jstancek@redhat.com</a>><br></blockquote><div><span class="gmail_default" style="font-size:small"></span></div><div><span class="gmail_default" style="font-size:small">Acked-by: Li Wang <<a href="mailto:liwang@redhat.com">liwang@redhat.com</a>></span></div><div><span class="gmail_default" style="font-size:small"><br></span></div><div><span class="gmail_default" style="font-size:small">This is obviously right! ACK.</span></div><div><span class="gmail_default" style="font-size:small"></span> </div></div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div>Regards,<br></div><div>Li Wang<br></div></div></div></div>