zephyr/scripts
Andy Ross 098fce351f scripts/twister: Fix race with device-testing
CPython is sometimes described as "single threaded" due to the GIL,
but the interpreter will still "preemptively" switch between threads
(the details seem poorly documented).

So the time between checking whether acquire is 1 and decrementing the
count could result in more than one thread seeing an "available"
device, and more than one test being run (simultaneously, on the same
physical device!).  We have a big herd of threads all polling for
this, so in a large test run this would happen maybe one time out of
20-30 tries.

Use a lock.  Also remove the very similar looking
DUT.get_available_device() method, which had the same bug but appears
to be dead code.

Fixes #32679

Signed-off-by: Andy Ross <andrew.j.ross@intel.com>
2021-03-04 12:39:54 -05:00
..
checkpatch aarch64: mem_domain: Introduce k_mem_partition_attr_t 2021-03-01 09:25:44 -05:00
ci ci: limit CI to only changed architecture 2021-03-04 07:14:11 -06:00
coccinelle scripts: coccinelle: Scripts for finding wrong device instance usage 2020-09-02 13:48:13 +02:00
coredump debug: coredump: remove z_ prefix for stuff used outside subsys 2021-01-21 22:08:59 -05:00
dts dts: gen_defines: add CLI option to error out on deprecated props 2021-03-03 10:22:36 -06:00
footprint cleanup: rename sanitycheck references to twister 2021-01-14 07:50:52 -06:00
gitlint
kconfig Bluetooth: host: Log security keys needed by sniffer 2021-03-04 14:20:25 +02:00
net net: scripts: Make test runner script fully generic 2020-11-20 16:07:59 +02:00
pylib/twister scripts/twister: Fix race with device-testing 2021-03-04 12:39:54 -05:00
release twister: change all occurances of sanitycheck 2020-12-11 14:13:02 -05:00
schemas/twister cleanup: rename sanitycheck references to twister 2021-01-14 07:50:52 -06:00
support
tests twister: remove some leftover sanitycheck mentions 2020-12-14 14:13:16 -05:00
tracing tracing: scripts: add scripts for parsing ctf data 2020-08-24 13:21:12 +02:00
west_commands west: runners: jlink: prefer .hex over .bin 2021-02-25 10:59:13 -06:00
.gitignore cleanup: rename sanitycheck references to twister 2021-01-14 07:50:52 -06:00
checkpatch.pl scripts: update checkpatch based on current linux kernel version 2020-08-21 13:57:02 -04:00
checkstack.pl
coccicheck
dir_is_writeable.py
file2hex.py
filter-known-issues.py
gen_app_partitions.py linker: tweak section naming to feet all linkers 2020-09-05 10:22:56 -05:00
gen_cfb_font_header.py
gen_gcov_files.py
gen_handles.py device: add post-process of elf file to manage device handles 2021-02-19 15:46:16 -05:00
gen_kobject_list.py kernel: add vrfy hooks to support userspace with condvar 2021-01-19 08:55:47 -05:00
gen_offset_header.py
gen_relocate_app.py cmake: scripts: supporting gen_relocate_app feature in windows 2021-01-20 11:51:47 +01:00
gen_syscalls.py
get_maintainer.py scripts: add maintainer script 2020-07-24 17:07:48 +02:00
list_boards.py scripts: add list_boards.py 2021-01-15 15:07:49 -05:00
mergehex.py
parse_syscalls.py
process_gperf.py
requirements-base.txt scripts: move pip pykwalify from requirements-build-test to -base 2021-01-18 16:56:24 -05:00
requirements-build-test.txt scripts: move pip pykwalify from requirements-build-test to -base 2021-01-18 16:56:24 -05:00
requirements-compliance.txt requirements-compliance: restrict junitparser version < 2 2021-01-13 07:58:37 -05:00
requirements-doc.txt requirements-doc: add missing pkwalify 2021-01-11 14:51:45 -05:00
requirements-extras.txt scripts/requirements: Add required version to imgtool in extras 2021-01-18 16:59:29 -05:00
requirements-run-test.txt requirements: Update to pyocd 0.29 for LPC55S69 support 2021-01-21 15:53:22 -05:00
requirements.txt python3: add check_compliance package requirements 2020-08-11 14:49:48 -04:00
sanitycheck twister: add a wrapper script with old name 2020-12-11 14:13:02 -05:00
series-push-hook.sh scripts: series-push-hook: Fix behavior after rebase 2020-10-21 07:16:54 -05:00
spelling.txt
subfolder_list.py scripts: subfolder_list.py: refactor the code 2020-07-20 17:31:53 -04:00
tags.sh scripts: Update paths on tags.sh 2021-02-19 05:28:09 -06:00
twister twister: bugfix: Fix twister output 2021-02-09 06:55:41 -05:00
uf2conv.py cmake: Add UF2 as an additional build output option. 2021-02-23 21:11:04 +01:00
user_wordsize.py
valgrind.supp
west-commands.yml
zephyr_module.py scripts: modules: support west group feature 2021-01-29 08:06:17 -05:00