[PATCH 2/6] linux: Assume clock_getres CLOCK_{PROCESS,THREAD}_CPUTIME_ID

Adhemerval Zanella adhemerval.zanella@linaro.org
Tue Feb 12 21:42:00 GMT 2019



On 12/02/2019 19:11, Florian Weimer wrote:
> * Adhemerval Zanella:
> 
>>> It may make sense to add a note to check_clock_getres that we use
>>> INTERNAL_SYSCALL_CALL to avoid setting errno, so that the call can use
>>> errno to check whether sysconf recognized the parameter constant at all.
>>
>> Ack, I added:
>>
>>   /* Avoid setting errno so it can check whether the kernel supports
>>      the CLK_ID.  */
>>
>> As a side note I think we can also use INLINE_SYCALL_CALL and check
>> for EINVAL.
> 
> Sorry, what I meant is that the caller might want to set errno to 0
> and check this way if sysconf actually recognizes the passed _SC_*
> parameter.
> 
> At least that's why I think INLINE_SYCALL_CALL is used here.
> 

Ah right, anyway I kept INTERNAL_SYSCALL_CALL.



More information about the Libc-alpha mailing list