stm32/gpio: make port G work on U5.

This commit is contained in:
Dario Nieuwenhuis 2023-10-23 18:12:31 +02:00
parent a39ae12edc
commit 82593bd404
2 changed files with 9 additions and 2 deletions

4
ci.sh
View file

@ -221,8 +221,8 @@ rm out/tests/stm32wb55rg/wpan_ble
# unstable, I think it's running out of RAM?
rm out/tests/stm32f207zg/eth
# doesn't work. Wire in D0-D1 might be bad, or the special IOVDD2 PGx pins.
rm out/tests/stm32u5a5zj/{gpio,usart*}
# doesn't work, gives "noise error", no idea why. usart_dma does pass.
rm out/tests/stm32u5a5zj/usart
if [[ -z "${TELEPROBE_TOKEN-}" ]]; then
echo No teleprobe token found, skipping running HIL tests

View file

@ -763,6 +763,13 @@ pub(crate) unsafe fn init(_cs: CriticalSection) {
<crate::peripherals::AFIO as crate::rcc::sealed::RccPeripheral>::enable_and_reset_with_cs(_cs);
crate::_generated::init_gpio();
// Setting this bit is mandatory to use PG[15:2].
#[cfg(stm32u5)]
crate::pac::PWR.svmcr().modify(|w| {
w.set_io2sv(true);
w.set_io2vmen(true);
});
}
mod eh02 {