2
0
mirror of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git synced 2025-09-04 20:19:47 +08:00
linux/tools/testing
Hangbin Liu 47c84997c6 selftests: net: lib: fix shift count out of range
I got the following warning when writing other tests:

  + handle_test_result_pass 'bond 802.3ad' '(lacp_active off)'
  + local 'test_name=bond 802.3ad'
  + shift
  + local 'opt_str=(lacp_active off)'
  + shift
  + log_test_result 'bond 802.3ad' '(lacp_active off)' ' OK '
  + local 'test_name=bond 802.3ad'
  + shift
  + local 'opt_str=(lacp_active off)'
  + shift
  + local 'result= OK '
  + shift
  + local retmsg=
  + shift
  /net/tools/testing/selftests/net/forwarding/../lib.sh: line 315: shift: shift count out of range

This happens because an extra shift is executed even after all arguments
have been consumed. Remove the last shift in log_test_result() to avoid
this warning.

Fixes: a923af1cee ("selftests: forwarding: Convert log_test() to recognize RET values")
Signed-off-by: Hangbin Liu <liuhangbin@gmail.com>
Link: https://patch.msgid.link/20250709091244.88395-1-liuhangbin@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2025-07-10 18:11:52 -07:00
..
crypto/chacha20-s390 crypto: lib/chacha - strongly type the ChaCha state 2025-05-12 13:32:53 +08:00
cxl Merge branch 'for-6.16/cxl-features-ras' into cxl-for-next 2025-05-23 13:26:24 -07:00
fault-injection
ktest ktest: Fix Test Failures Due to Missing LOG_FILE Directories 2025-03-27 09:34:00 -04:00
kunit Revert "kunit: configs: Enable CONFIG_INIT_STACK_ALL_PATTERN in all_tests" 2025-06-03 11:20:21 +02:00
memblock memblock: add MEMBLOCK_RSRV_KERN flag 2025-05-12 23:50:38 -07:00
nvdimm
radix-tree maple_tree: add sufficient height 2025-05-11 17:48:29 -07:00
rbtree lib/interval_tree: add test case for span iteration 2025-03-17 12:17:01 -07:00
scatterlist
selftests selftests: net: lib: fix shift count out of range 2025-07-10 18:11:52 -07:00
shared test suite: use %zu to print size_t 2025-04-11 17:32:35 -07:00
vma mm: add mmap_prepare() compatibility layer for nested file systems 2025-06-12 21:39:02 -07:00
vsock vsock/test: Add test for an unexpectedly lingering close() 2025-05-27 11:05:22 +02:00