[PATCH v2 2/2] socket: Add socket timestamp test

Adhemerval Zanella adhemerval.zanella@linaro.org
Tue Jul 6 18:20:01 GMT 2021



On 06/07/2021 11:50, Adhemerval Zanella wrote:
> Changes from previous version:
> 
>   - Merged both recvmsg and recvmmsg on only one test and renamed
>     to tst-socket-timestamp-time64.c.
>   - Call setsockopt instead of xsetsockopt so it calls the possible
>     64-bit wrapper.
> 
> ---
> 
> The test check if SO_TIMESTAMP and SO_TIMESTAMPNS is correctly generated
> by recvmsg and recvmmsg for both _TIME_BITS.  The recvmsg()/recvmmsg()
> is called with different ancilliary data buffers, to check if the
> conversion for 64-bit time on 32-bit legacy ABIs are handled correctly.
> 
> For legacy ABI with 32-bit time_t support, depending of the remmaning
> ancially data space the timestamp can not be appended and MSG_TRUNC
> is returned instead.
> 
> Checked on x86_64-linux and on i686-linux-gnu on both 5.11 and
> 4.15 kernel.

I also noted that I haven't used support_next_to_fault_free, I will send
an update.


More information about the Libc-alpha mailing list