All of lore.kernel.org
 help / color / mirror / Atom feed
* [LTP] [PATCH] futex: return TCONF if FUTEX_WAIT_BITSET operation is not supported
@ 2015-03-17  3:33 Xiaoguang Wang
  2015-03-17 12:53 ` Cyril Hrubis
  0 siblings, 1 reply; 2+ messages in thread
From: Xiaoguang Wang @ 2015-03-17  3:33 UTC (permalink / raw)
  To: ltp-list

Signed-off-by: Xiaoguang Wang <wangxg.fnst@cn.fujitsu.com>
---
 testcases/kernel/syscalls/futex/futex_wait_bitset.h | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/testcases/kernel/syscalls/futex/futex_wait_bitset.h b/testcases/kernel/syscalls/futex/futex_wait_bitset.h
index 2f8ddb8..73d87da 100644
--- a/testcases/kernel/syscalls/futex/futex_wait_bitset.h
+++ b/testcases/kernel/syscalls/futex/futex_wait_bitset.h
@@ -42,6 +42,12 @@ static void verify_futex_wait_bitset(long long wait_us, clock_t clk_id)
 		return;
 	}
 
+	if (TEST_ERRNO == EOPNOTSUPP || TEST_ERRNO == ENOSYS) {
+		tst_resm(TCONF, "In this kernel, futex() does not support "
+			 "FUTEX_WAIT_BITSET operation");
+		return;
+	}
+
 	if (TEST_ERRNO != ETIMEDOUT) {
 		tst_resm(TFAIL | TTERRNO, "expected %s",
 		         tst_strerrno(ETIMEDOUT));
-- 
1.8.2.1


------------------------------------------------------------------------------
Dive into the World of Parallel Programming The Go Parallel Website, sponsored
by Intel and developed in partnership with Slashdot Media, is your hub for all
things parallel software development, from weekly thought leadership blogs to
news, videos, case studies, tutorials and more. Take a look and join the 
conversation now. http://goparallel.sourceforge.net/
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [LTP] [PATCH] futex: return TCONF if FUTEX_WAIT_BITSET operation is not supported
  2015-03-17  3:33 [LTP] [PATCH] futex: return TCONF if FUTEX_WAIT_BITSET operation is not supported Xiaoguang Wang
@ 2015-03-17 12:53 ` Cyril Hrubis
  0 siblings, 0 replies; 2+ messages in thread
From: Cyril Hrubis @ 2015-03-17 12:53 UTC (permalink / raw)
  To: Xiaoguang Wang; +Cc: ltp-list

Hi!
> Signed-off-by: Xiaoguang Wang <wangxg.fnst@cn.fujitsu.com>
> ---
>  testcases/kernel/syscalls/futex/futex_wait_bitset.h | 6 ++++++
>  1 file changed, 6 insertions(+)
> 
> diff --git a/testcases/kernel/syscalls/futex/futex_wait_bitset.h b/testcases/kernel/syscalls/futex/futex_wait_bitset.h
> index 2f8ddb8..73d87da 100644
> --- a/testcases/kernel/syscalls/futex/futex_wait_bitset.h
> +++ b/testcases/kernel/syscalls/futex/futex_wait_bitset.h
> @@ -42,6 +42,12 @@ static void verify_futex_wait_bitset(long long wait_us, clock_t clk_id)
>  		return;
>  	}
>  
> +	if (TEST_ERRNO == EOPNOTSUPP || TEST_ERRNO == ENOSYS) {
> +		tst_resm(TCONF, "In this kernel, futex() does not support "
> +			 "FUTEX_WAIT_BITSET operation");
> +		return;
> +	}

On which system did you get EOPNOTSUPP? The (incomplete) futex man page
only defines ENOSYS if futex op is not defined. Or was that only for
FUTEX_CLOCK_REALTIME?

A bit more background info in the commit message would not harm,
otherwise the patch looks OK.

-- 
Cyril Hrubis
chrubis@suse.cz

------------------------------------------------------------------------------
Dive into the World of Parallel Programming The Go Parallel Website, sponsored
by Intel and developed in partnership with Slashdot Media, is your hub for all
things parallel software development, from weekly thought leadership blogs to
news, videos, case studies, tutorials and more. Take a look and join the 
conversation now. http://goparallel.sourceforge.net/
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2015-03-17 12:54 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-03-17  3:33 [LTP] [PATCH] futex: return TCONF if FUTEX_WAIT_BITSET operation is not supported Xiaoguang Wang
2015-03-17 12:53 ` Cyril Hrubis

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.