Pico sync sw spinlock fix #3040

Merged
kilograham merged 8 commits from pico_sync-sw-spinlock-fix into develop 2026-07-01 13:02:22 -05:00
kilograham commented 2026-06-28 18:12:16 -05:00 (Migrated from github.com)
No description provided.
Wren6991 (Migrated from github.com) reviewed 2026-06-28 18:12:16 -05:00
peterharperuk (Migrated from github.com) reviewed 2026-06-28 18:12:16 -05:00
lurch commented 2026-06-28 19:03:41 -05:00 (Migrated from github.com)

Related to #1812? Or is that just coincidentally similar?

Related to #1812? Or is that just coincidentally similar?
will-v-pi (Migrated from github.com) reviewed 2026-06-29 06:34:13 -05:00
@ -0,0 +6,4 @@
cc_binary(
name = "pico_sync_test_hw",
testonly = True,
srcs = ["pico_sync_test.c"],
will-v-pi (Migrated from github.com) commented 2026-06-29 06:34:13 -05:00

This needs a:

    srcs = ["pico_sync_test.c"],
    target_compatible_with = compatible_with_rp2(),

along with load("//bazel:defs.bzl", "compatible_with_rp2") at the top

This needs a: ```suggestion srcs = ["pico_sync_test.c"], target_compatible_with = compatible_with_rp2(), ``` along with `load("//bazel:defs.bzl", "compatible_with_rp2")` at the top
kilograham (Migrated from github.com) reviewed 2026-06-29 11:15:03 -05:00
@ -0,0 +6,4 @@
cc_binary(
name = "pico_sync_test_hw",
testonly = True,
srcs = ["pico_sync_test.c"],
kilograham (Migrated from github.com) commented 2026-06-29 11:15:03 -05:00

thx

thx
kilograham commented 2026-06-29 11:15:46 -05:00 (Migrated from github.com)

Related to #1812? Or is that just coincidentally similar?

related - however the previous fix did not cover all cases

> Related to #1812? Or is that just coincidentally similar? related - however the previous fix did not cover all cases
will-v-pi (Migrated from github.com) requested changes 2026-07-01 04:33:20 -05:00
will-v-pi (Migrated from github.com) left a comment

This PR breaks the hardware tests on Arm - pico_thread_local_test and pico_thread_local_test_cpp are failing, they seem to be getting stuck in the first sem_acquire_blocking

And on Risc-V, the new pico_sync_test_sw test fails with Module SYNC: Section check low power lock_core wait loop with timeout : Failed test

This PR breaks the hardware tests on Arm - `pico_thread_local_test` and `pico_thread_local_test_cpp` are failing, they seem to be getting stuck in the first `sem_acquire_blocking` And on Risc-V, the new `pico_sync_test_sw` test fails with `Module SYNC: Section check low power lock_core wait loop with timeout : Failed test`
kilograham commented 2026-07-01 09:27:51 -05:00 (Migrated from github.com)

should fix #3052

should fix #3052
will-v-pi (Migrated from github.com) requested changes 2026-07-01 10:49:50 -05:00
will-v-pi (Migrated from github.com) left a comment

pico_sync_test_sw is still failing on Risc-V - the full test output was:

Starting Picotest for sync test
Module SYNC: Section check low power lock_core wait loop with timeout: ...
Waited 75648 times
Module SYNC: Expected exactly 2 waits
Module SYNC: Section check low power lock_core wait loop with timeout : Failed test

When running it locally it also fails, although with a slightly different number of times:

Starting Picotest for sync test
Module SYNC: Section check low power lock_core wait loop with timeout: ...
Waited 76422 times
Module SYNC: Expected exactly 2 waits
Module SYNC: Section check low power lock_core wait loop with timeout : Failed test
`pico_sync_test_sw` is still failing on Risc-V - the full test output was: ``` Starting Picotest for sync test Module SYNC: Section check low power lock_core wait loop with timeout: ... Waited 75648 times Module SYNC: Expected exactly 2 waits Module SYNC: Section check low power lock_core wait loop with timeout : Failed test ``` When running it locally it also fails, although with a slightly different number of times: ``` Starting Picotest for sync test Module SYNC: Section check low power lock_core wait loop with timeout: ... Waited 76422 times Module SYNC: Expected exactly 2 waits Module SYNC: Section check low power lock_core wait loop with timeout : Failed test ```
will-v-pi (Migrated from github.com) approved these changes 2026-07-01 12:04:02 -05:00
will-v-pi (Migrated from github.com) left a comment

All hardware tests passing now

All hardware tests passing now
Sign in to join this conversation.
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
gh-raspberrypi/pico-sdk!3040
No description provided.