All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3 0/2] selftests/futex: Create test for robust list
@ 2024-10-10  1:11 André Almeida
  2024-10-10  1:11 ` [PATCH v3 1/2] selftests/futex: Add ASSERT_ macros André Almeida
  2024-10-10  1:11 ` [PATCH v3 2/2] selftests/futex: Create test for robust list André Almeida
  0 siblings, 2 replies; 5+ messages in thread
From: André Almeida @ 2024-10-10  1:11 UTC (permalink / raw)
  To: Thomas Gleixner, Ingo Molnar, Peter Zijlstra, Darren Hart,
	Davidlohr Bueso, Shuah Khan
  Cc: linux-kernel, linux-kselftest, kernel-dev, André Almeida

This patchset creates a selftest for the robust list interface, to track
regressions and assure that the interface keeps working as expected.

In this version I removed the kselftest_harness include, but I expanded the
current futex selftest API a little bit with basic ASSERT_ macros to make the
test easier to write and read. In the future, hopefully we can move all futex
selftests to the kselftest_harness API anyway.

Changes from v2:
- Create ASSERT_ macros for futex selftests
- Dropped kselftest_harness include, using just futex test API
- This is the expected output:
    
TAP version 13
1..6
ok 1 test_robustness
ok 2 test_set_robust_list_invalid_size
ok 3 test_get_robust_list_self
ok 4 test_get_robust_list_child
ok 5 test_set_list_op_pending
ok 6 test_robust_list_multiple_elements
# Totals: pass:6 fail:0 xfail:0 xpass:0 skip:0 error:0
https://lore.kernel.org/lkml/20240903134033.816500-1-andrealmeid@igalia.com

André Almeida (2):
  selftests/futex: Add ASSERT_ macros
  selftests/futex: Create test for robust list

 .../selftests/futex/functional/.gitignore     |   1 +
 .../selftests/futex/functional/Makefile       |   3 +-
 .../selftests/futex/functional/robust_list.c  | 512 ++++++++++++++++++
 .../testing/selftests/futex/include/logging.h |  28 +
 4 files changed, 543 insertions(+), 1 deletion(-)
 create mode 100644 tools/testing/selftests/futex/functional/robust_list.c

-- 
2.46.0


^ permalink raw reply	[flat|nested] 5+ messages in thread
* Re: [PATCH v3 2/2] selftests/futex: Create test for robust list
@ 2024-10-11 21:36 kernel test robot
  0 siblings, 0 replies; 5+ messages in thread
From: kernel test robot @ 2024-10-11 21:36 UTC (permalink / raw)
  To: oe-kbuild; +Cc: lkp

:::::: 
:::::: Manual check reason: "low confidence bisect report"
:::::: 

BCC: lkp@intel.com
CC: oe-kbuild-all@lists.linux.dev
In-Reply-To: <20241010011142.905297-3-andrealmeid@igalia.com>
References: <20241010011142.905297-3-andrealmeid@igalia.com>
TO: "André Almeida" <andrealmeid@igalia.com>
TO: Thomas Gleixner <tglx@linutronix.de>
TO: Ingo Molnar <mingo@redhat.com>
TO: Peter Zijlstra <peterz@infradead.org>
TO: Darren Hart <dvhart@infradead.org>
TO: Davidlohr Bueso <dave@stgolabs.net>
TO: Shuah Khan <skhan@linuxfoundation.org>
CC: linux-kernel@vger.kernel.org
CC: linux-kselftest@vger.kernel.org
CC: kernel-dev@igalia.com
CC: "André Almeida" <andrealmeid@igalia.com>

Hi André,

kernel test robot noticed the following build warnings:

[auto build test WARNING on tip/locking/core]
[also build test WARNING on linus/master v6.12-rc2 next-20241011]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]

url:    https://github.com/intel-lab-lkp/linux/commits/Andr-Almeida/selftests-futex-Add-ASSERT_-macros/20241010-091311
base:   tip/locking/core
patch link:    https://lore.kernel.org/r/20241010011142.905297-3-andrealmeid%40igalia.com
patch subject: [PATCH v3 2/2] selftests/futex: Create test for robust list
:::::: branch date: 2 days ago
:::::: commit date: 2 days ago
compiler: clang version 18.1.8 (https://github.com/llvm/llvm-project 3b5b5c1ec4a3095ab096dd780e84d7ab81f3d7ff)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20241012/202410120549.1KpTVqTu-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/r/202410120549.1KpTVqTu-lkp@intel.com/

All warnings (new ones prefixed by >>):

>> robust_list.c:121:44: warning: passing 'int *' to parameter of type 'unsigned int *' converts between pointers to integer types with different sign [-Wpointer-sign]
     121 |         if (atomic_compare_exchange_strong(futex, &zero, tid)) {
         |                                                   ^~~~~
   /opt/cross/clang-3b5b5c1ec4/lib/clang/18/include/stdatomic.h:144:112: note: expanded from macro 'atomic_compare_exchange_strong'
     144 | #define atomic_compare_exchange_strong(object, expected, desired) __c11_atomic_compare_exchange_strong(object, expected, desired, __ATOMIC_SEQ_CST, __ATOMIC_SEQ_CST)
         |                                                                                                                ^~~~~~~~
   1 warning generated.

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

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

end of thread, other threads:[~2024-10-11 23:03 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-10-10  1:11 [PATCH v3 0/2] selftests/futex: Create test for robust list André Almeida
2024-10-10  1:11 ` [PATCH v3 1/2] selftests/futex: Add ASSERT_ macros André Almeida
2024-10-10  1:11 ` [PATCH v3 2/2] selftests/futex: Create test for robust list André Almeida
2024-10-11 23:03   ` kernel test robot
  -- strict thread matches above, loose matches on Subject: below --
2024-10-11 21:36 kernel test robot

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.