[PATCH] linux: Add mseal syscall support
Collin Funk
collin.funk1@gmail.com
Fri Oct 10 19:41:11 GMT 2025
Adhemerval Zanella <adhemerval.zanella@linaro.org> writes:
> + if (errno == ENOSYS)
> + FAIL_UNSUPPORTED
> + ("kernel does not support memory protection keys");
> + if (errno == EINVAL)
> + FAIL_UNSUPPORTED
> + ("CPU does not support memory protection keys: %m");
Do any other syscalls fail with different errno's depending on if the
kernel or the CPU do not support them? I feel like it is better to use
ENOSYS in both cases, but maybe I am missing something.
Also, for formatting long lines like this I think the following looks
better:
FAIL_UNSUPPORTED ("CPU does not support "
"memory protection keys: %m");
Collin
More information about the Libc-alpha
mailing list