From: Stefan Liebler <stli@linux.ibm.com>
To: Adhemerval Zanella <adhemerval.zanella@linaro.org>,
libc-alpha@sourceware.org
Subject: Re: [PATCH] Don't test nanoseconds for non-LFS interface in io/tst-stat.c
Date: Tue, 16 Mar 2021 17:30:56 +0100 [thread overview]
Message-ID: <7eb4bf10-0ce2-03cd-d50f-f6bc0c8f4129@linux.ibm.com> (raw)
In-Reply-To: <dfbeda05-3d9f-6ecc-9331-cad7f4ffb352@linaro.org>
On 16/03/2021 15:24, Adhemerval Zanella wrote:
>
>
> On 16/03/2021 10:56, Stefan Liebler wrote:
>> Both new tests io/tst-stat and io/tst-stat-lfs (_FILE_OFFSET_BITS=64)
>> are comparing the nanosecond fields with the statx result. Unfortunately
>> e.g. on s390(31bit) those fields are always zero if old KABI with non-LFS
>> support is used. With _FILE_OFFSET_BITS=64 stat is using statx internally.
>
> This might also happens for LFS interface if statx is not supported by the
> kernel, since the LFS call will fall back to the use the stat syscall that
> has this issue.
>
> Maybe it would be better to make it an internal tests and add a flag
> somewhere to just disable it for s390-32.
>
gcc is setting the macros __s390x__ and __s390__ on s390x(64bit), but
only __s390__ on s390(31bit). Thus I can detect s390(31bit) at
compile-time via "#if" and disable the nanoseconds checks on s390(31bit)
at all and run it on all other cases. Then I don't need to make the test
an internal test and don't need special flags. If this is okay for you,
I will prepare a further patch (also with a different subject).
Thanks,
Stefan
next prev parent reply other threads:[~2021-03-16 16:31 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-16 13:56 Stefan Liebler
2021-03-16 14:24 ` Adhemerval Zanella
2021-03-16 16:30 ` Stefan Liebler [this message]
2021-03-16 19:59 ` Adhemerval Zanella
2021-03-17 13:04 ` Stefan Liebler
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=7eb4bf10-0ce2-03cd-d50f-f6bc0c8f4129@linux.ibm.com \
--to=stli@linux.ibm.com \
--cc=adhemerval.zanella@linaro.org \
--cc=libc-alpha@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).