On 02.12.2024 11:49, Muchun Song wrote:
On Dec 1, 2024, at 09:03, Dafna Hirschfeld <dafna.hirschfeld@xxxxxxxxx> wrote:
The error ENOSPC is translated in vmf_error to VM_FAULT_SIGBUS which is
further translated in EFAULT in i.e. pin/get_user_pages.
But when running out of pages/hugepages we expect to see ENOMEM and
not EFAULT.
Hi Dafna,
Refers to Documentation/mm/hugetlbfs_reserv.rst. I saw:
If no huge page exists at page fault time, the task is sent
a **SIGBUS** and often dies an unhappy death.
Seems SIGBUS is expected since it is introduced.
Hi, thanks for pointing this out, the question is wheather EFAULT
is the expected return code from pin/get_user_pages* funcs in such case.
Dafna
Thanks.