> Retain references to the pages backing ALSA's vmalloc buffer until its > queued I/O messages are freed. On NOMMU systems, use driver-owned memory > for DMA and copy playback data before submission and capture data after > completion, so ALSA buffer release cannot invalidate an active request. > > Validate the PCM buffer and each period before building scatterlists. > Require a successful full-period response for ordinary capture before > advancing its pointer. Each descriptor targets a fixed ring slice, so a > short response would expose the unwritten remainder as captured data. > > Require whole-byte periods whose total matches the negotiated buffer. > Check offset, length and the final message index before indexing the > message array, including empty transfers and arithmetic wraparound. > > Seed the ordinary capture ring once per prepare. Native STOP preserves > [ ... ] > > Retain PCM DMA pages and validate full fixed-slot completions. Account the > successfully seeded RX ring as full so completed capture data stays reserved > until appl_ptr consumes it. > > Bound ordinary indirect capture appl_ptr consumption to completed, > unacknowledged capture bytes before invoking the indirect transfer helper. > Reject positive advances before RX ring seeding and reject frame deltas not > aligned to runtime->min_align before byte conversion. > Signed-off-by: Joonho Lee <[email protected]>
Sashiko has reviewed this patch and found no issues. -- Sashiko AI review ยท https://sashiko.dev/#/patchset/[email protected]?part=7
