WIP: Add more allowed values to TREQ_SEL in rp2040.svd #1063
No reviewers
Labels
No labels
bazel
bluetooth
board settings
boot_stage2
bug
build
c++
can't reproduce
clang
clib-interface
cmsis
code cleanliness
code size
compiler version issues
cyw43_driver
debug
discussion
documentation
duplicate
dynamic_clock
elf2uf2
enhancement
errata
filesystem
flash layout
floating point
FreeRTOS
hardware_adc
hardware_claim
hardware_clocks
hardware_dma
hardware_exception
hardware_flash
hardware_gpio
hardware_i2c
hardware_irq
hardware_pio
hardware_pwm
hardware_rcp
hardware_rtc
hardware_spi
hardware_sync
hardware_uart
hardware_vreg
hardware_watchdog
hardware_xosc
help wanted
host
IAR
installation
invalid
linker scripts
lto
lwip
mbedtls
missing API
needs reporter detail
networking
newlib
newlib-multicore
non-c
non-cmake
non-gcc
openocd
orphan PR
OS integration
pico_async_context
pico_base
pico_binary_info
pico_flash
picolibc
pico_lwip
pico_malloc
pico_multicore
pico_printf
pico_runtime
pico_stdio
pico_stdio_usb
pico_sync
pico_time
pico_util
pioasm
port
question
review
review2
rtos interop
runtime init
static library
svd
test
tinyusb
vscode
wifi integration
wontfix
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
gh-raspberrypi/pico-sdk!1063
Loading…
Reference in a new issue
No description provided.
Delete branch "treq_sel_values"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Fixes #1062
This change was previously made by @jounathaen in https://github.com/rp-rs/rp2040-pac/pull/59 for the rust PAC. I think it would be useful to add those values in the pico-sdk SVD as well.
Also removes the "(Optional)" annotation from the Timer 2/3 values, as those are always present on the rp2040.
rp2040.svdis autogenerated (using our internal-only tooling) from other files, so I'm afraid it doesn't make sense to edit it "manually" as it'll only get overwritten again in future. When I'm a bit less busy (which isn't likely to be for quite a while!), I'll look at including your changes here into our internal tooling. Thanks.P.S. Presumably you'd want https://github.com/raspberrypi/pico-sdk/blob/develop/src/rp2040/hardware_regs/include/hardware/regs/dma.h#L160 to be updated with this expanded list of values too? (as that also gets autogenerated using the same tooling)
Sure, if the svd is auto generated, it's more useful to fix the source files.
I didn't notice that dma.h has the same issue as I'm only using rust, but it makes sense to update it at the same time.
Just for reference, in case you don't already know: The rust files are usually also autogenerated from the svd files, using https://github.com/rust-embedded/svd2rust/.
To avoid manually editing the svd files in case some fix is needed, there is a patch tool available in https://github.com/stm32-rs/svdtools which allows for rather complex edits of the svd file: https://crates.io/crates/svdtools#device-and-peripheral-yaml-format
That's how https://github.com/rp-rs/rp2040-pac can already include those new enumeratedValues while still being based on the original rp2040.svd file.
Neat!
Haha 😄 Please do let us know about any other "bugs" you encounter in our SVD file, and we'll endeavour to fix them when we have the time.
I'm sure that comment was not referring to rp2040.svd! There might be a reason that tool was created by the stm32-rs developers.
While the current patch file https://github.com/rp-rs/rp2040-pac/blob/main/svd/rp2040.yaml is far from small, I think most changes are not due to bugs in rp2040.svd, but just tweaks to help svd2rust to generate nicer rust code.
What's the state if this pull request? I guess it doesn't make much sense to fix the merge conflicts, given that the svd is generated from some non-public source anyway.
We won't be merging this PR (so I've just set it to "draft" status), but it serves as a useful reminder of what changes are being requested 🙂
functionality is in 2.0.0
Pull request closed