mirror of
https://github.com/checkpoint-restore/criu.git
synced 2026-07-17 16:47:50 +00:00
kerndat: Mark memfd_create(MFD_HUGETLB) unavailable when ENOSYS is returned
Some users on Raspberry Pi report that the kerndat checking for memfd_create(MFD_HUGETLB) support returns ENOSYS even when memfd_create syscall is available. We currently treat this error as unexpected and return error. This commit marks the memfd_create(MFD_HUGETLB) as unavailable when ENOSYS is returned. Signed-off-by: Bui Quang Minh <minhquangbui99@gmail.com>
This commit is contained in:
parent
979c84209b
commit
614fb7de02
1 changed files with 1 additions and 1 deletions
|
|
@ -500,7 +500,7 @@ static bool kerndat_has_memfd_hugetlb(void)
|
|||
if (ret >= 0) {
|
||||
kdat.has_memfd_hugetlb = true;
|
||||
close(ret);
|
||||
} else if (ret == -1 && (errno == EINVAL || errno == ENOENT)) {
|
||||
} else if (ret == -1 && (errno == EINVAL || errno == ENOENT || errno == ENOSYS)) {
|
||||
kdat.has_memfd_hugetlb = false;
|
||||
} else {
|
||||
pr_perror("Unexpected error from memfd_create(\"\", MFD_HUGETLB)");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue