Re: [PATCH v2] ASoC: loongson: Fix invalid position error in ls_pcm_pointer

From: lijun

Date: Mon Jun 01 2026 - 20:53:26 EST


for example,the DMA controller is abnormal in hardware
the addr = 0,
addr = ((u64)desc->saddr_hi << 32) | desc->saddr;
x = bytes_to_frames(runtime, addr - runtime->dma_addr);
addr = 0 dma_addr=4195352576   x=-1048838144 i think the value of pos should not be a negative,return 0, maybe better.

2026/6/2 02:28, Mark Brown :
I'm not clear in what circumstances we see an address that's outside the
DMA buffer? Is this an error that should be reported as an XRUN instead
of silently masked (which will presumably lead to audible issues)?