Repository navigation
Pump link resource watchdogs outside the Transport jobs section - #103
Merged
attermann merged 1 commit intoNov 10, 2026
Merged
Conversation
Transport::jobs() sets _jobs_running and then calls Link::tick_resources(). A resource watchdog can send a packet (e.g. a Resource advertisement retry), which ends up in Transport::outbound(). outbound() spins while _jobs_running is set, so on single-threaded targets the loop never returns and the hardware watchdog resets the device. Collect the active links during jobs() and tick them after _jobs_running is cleared, the same way announce retransmissions in `outgoing` are sent. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Owner
|
Thanks @tostolaza, nice find, and thanks for the clear repro and the hardware soak test. Collecting the links and ticking them after One small thing I'll check before merging: the new tick loop now sits outside the |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Transport::jobs()sets_jobs_running = trueand then callsLink::tick_resources()for every active link. A resource watchdog can send a packet, for exampleResource::advertise_jobre-sending an advertisement that got no part request. That packet goes throughTransport::outbound(), which spins while_jobs_runningis set. On single-threaded targets nothing clears the flag, so the loop never returns and the hardware watchdog resets the device.Reproduce: nRF52840 node in transport mode serving a NomadNet page. A remote client opens a Link and requests the page over a lossy LoRa path. The log ends with:
and the device resets after the 60 s watchdog.
Solution
Collect the active, non-closed links during
jobs()and calltick_resources()after_jobs_runningis cleared. This is the same pattern already used for announce retransmissions inoutgoing.Testing
wiscore_rak4631,masn-ht-ra62) and ESP32-S3 (heltec_wifi_lora_32_V3).🤖 Generated with Claude Code