From: Xiao Yang <yangx.jy@cn.fujitsu.com>
To: ltp@lists.linux.it
Subject: [LTP] [PATCH] syscalls/stime: Use 3 variants via test_multiplex()
Date: Thu, 28 Mar 2019 17:40:25 +0800 [thread overview]
Message-ID: <5C9C9689.8060508@cn.fujitsu.com> (raw)
In-Reply-To: <20190328065243.GB11011@x230>
On 2019/03/28 14:52, Petr Vorel wrote:
> Hi Xiao,
>
>> diff --git a/testcases/kernel/syscalls/stime/stime01.c b/testcases/kernel/syscalls/stime/stime01.c
> ...
>> +static int do_stime(time_t *ntime)
>> +{
>> + switch (tst_variant) {
>> + case 0:
>> +#ifdef __ANDROID__
>> + tst_brk(TCONF, "libc stime() is not implemented for Android");
> IMHO this is not optimal. 1) That might change in the future, 2) Why not to fix
> it for other foo libc implementations, which might suffer the same problem.
> Therefore IMHO autotools check should be used.
>
Hi Petr,
Sorry, i pushed roughly. :-(
I have sent a patch set as you suggested, so could you help me review it?
Best Regards,
Xiao Yang
>> +#else
>> + return stime(ntime);
>> +#endif
>> + case 1:
>> + return tst_syscall(__NR_stime, ntime);
>> + case 2: {
>> + struct timeval tv;
>> +
>> + tv.tv_sec = *ntime;
>> + tv.tv_usec = 0;
>> +
>> + return tst_syscall(__NR_settimeofday,&tv, (struct timezone *) 0);
>> + }
>> + }
> Kind regards,
> Petr
>
>
>
next prev parent reply other threads:[~2019-03-28 9:40 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-03-27 6:30 [LTP] [PATCH] syscalls/stime: Use 3 variants via test_multiplex() Xiao Yang
2019-03-27 6:36 ` Xiao Yang
2019-03-27 20:13 ` Steve Muckle
2019-03-28 5:24 ` Xiao Yang
2019-03-28 6:52 ` Petr Vorel
2019-03-28 9:40 ` Xiao Yang [this message]
2019-03-28 13:40 ` Petr Vorel
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=5C9C9689.8060508@cn.fujitsu.com \
--to=yangx.jy@cn.fujitsu.com \
--cc=ltp@lists.linux.it \
/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