Repository navigation
feat(i2s): real deinitialize() on modern peripheral (#3526 Phase 2b) - #3541
Conversation
`I2sPeripheralEsp32DevEsp::deinitialize()` now calls `i2s_stop()` when `mBusy` is set at deinit time, so a mid-transmit teardown clears the peripheral's `tx_start` bit and stops DMA — no drift into the next caller's buffer. Note: this is not yet a FULL teardown. The ISR handle + DMA descriptor allocations from `i2s_init()` are still held onto so a re-init doesn't leak. That matches Yves's `gInitializedI2sInitialized` one-shot behavior. Full teardown lands with #3489 singleton migration since those resources are truly process-lifetime. ## Scope Small, safe, isolated change: - `deinitialize()` — real: calls `i2s_stop()` when busy. - Everything else unchanged. ## Verification - `bash test --cpp`: 345/345 pass. - `bash lint --cpp`: clean. - Bench: no invocation path currently exercises deinit + busy state (Bus::FLEX_IO,0 still binds to I2S_SPI; the modern peripheral isn't wired yet — Phase 2d), so this change is dormant on bench until Phase 2d lands. Confirmed by the previous PR (#3540) that the binary boots cleanly. Part of #3516 meta / #3526 Phase 2b. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
|
Warning Review limit reached
Next review available in: 3 seconds Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
deinitialize() now calls i2s_stop() when mBusy. Full teardown deferred to #3489 singleton migration. Test plan: bash test --cpp 345/345, bash lint clean.