arch/arm/rp2040: Implement support for custom SWD DAP instance IDs #16841
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.
Summary
Both cores of this uC can have a custom SWD DAP instance ID set. Changing these from the default values is uncommon but can help with multi-drop debugging where more than one board is daisy-chained to the same debug probe.
Currently, this can be achieved with a custom OpenOCD config like in the following example, but such a technique needs more testing before it can be considered stable for a broader use.
rp2040-custom_instid.cfg
openocd.cfg
Impact
Users will be able to debug boards with non-standard SWD DAP IDs.
Testing
These changes were tested on a Linux host, targeting a custom Cortex-M0+ (RP2040) board using NuttX v12.8.0 as the baseline. They were then manually ported to the current master branch.
The OpenOCD version used in the tests was 0.12.0+dev-gcf9c0b4.