feat(PeriphDrivers): Allow skipping GPIO and clock init in I2S drivers #1652
All Vouch review confidence checks passed
Residual risk 0.14 = Change Risk (0.36) × (1 − Review Confidence (0.60)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.36 · 209 lines diff across 2 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.320
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #1652"
general
weight: 0.35
ttmut
Description
MXC_I2S_Init()configures the I2S pins withMXC_GPIO_Config()and enables the I2S peripheral clock and its clock source.MXC_I2S_Shutdown()disables the peripheral clock. In Zephyr buildsMSDK_NO_GPIO_CLK_INITis defined: pinctrl owns the pins and the clock control driver owns the clocks. Eachi2s_configure()call therefore overwrote the pinctrl settings (pull, VDDIOH), and shutdown turned off a clock Zephyr had enabled.This PR skips the GPIO and clock handling when
MSDK_NO_GPIO_CLK_INITis defined, as the other drivers already do (UART, I2C, TRNG, ...). The I2S register reset inMXC_I2S_Shutdown()is kept, soMXC_I2S_Init()still starts from a clean state.Drivers changed:
I2S/i2s_me17.c(MAX32655/56)I2S/i2s_ai85.c(MAX78000),I2S/i2s_ai87.c(MAX78002)I2S/i2s_me12.c(MAX32662),I2S/i2s_me15.c(MAX32670/75),I2S/i2s_me18.c(MAX32690),I2S/i2s_me20.c(MAX32680),I2S/i2s_me21.c(MAX32672),I2S/i2s_me16.cSPIMSS/i2s_me10.c(MAX32650),SPIMSS/i2s_me11.c(MAX32660):MXC_I2S_Init()was already guarded; the clock disable inMXC_I2S_Shutdown()is now guarded too. On MAX32660 that clock is SPI1's, so I2S shutdown also stopped SPI1.Without
MSDK_NO_GPIO_CLK_INIT(normal MSDK builds), nothing changes.Testing
drivers.i2s.max32.pinctrltest failed before this change (pin config reset afteri2s_configure()) and passes with it.-Wall -Werror, both with and withoutMSDK_NO_GPIO_CLK_INIT.Signed-off-by: Dimitrije Lilic <Dimitrije.Lilic@analog.com>