mirror of
https://github.com/italicsjenga/rp-hal-boards.git
synced 2025-01-11 04:51:31 +11:00
d6231bd3ec
It seems like the rom_table_lookup missed one level of pointer dereferencing. After comparing it to the working call to reset_usb_boot() in https://github.com/jannic/rp-microcontroller-rs/blob/master/util/rp2040-panic-usb-boot/src/lib.rs, I changed the code until it generated basically the same assembly. With that change, I was able to successfully call rom_data::reset_to_usb_boot() I still don't like the type RomTableLookupFn, which just returns some generic T without any checks, and I think rom_table_lookup should be unsafe. But as none of those are pub, it doesn't matter too much. So I just made the changes necessary to make the code work. |
||
---|---|---|
.. | ||
src | ||
.gitignore | ||
Cargo.toml |