From: Mark Brown Date: Tue, 28 Feb 2023 17:59:15 +0000 (+0000) Subject: ASoC: mchp-pdmc: fix poc noises when starting X-Git-Tag: v6.6.17~5359^2~4^2~3 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=11d4e474861aa3443e52251660e5928103380715;p=platform%2Fkernel%2Flinux-rpi.git ASoC: mchp-pdmc: fix poc noises when starting Merge series from Claudiu Beznea : To start capture on Microchip PDMC the enable bits for each supported microphone need to be set. After this bit is set the PDMC starts to receive data from microphones and it considers this data as valid data. Thus if microphones are not ready the PDMC captures anyway data from its lines. This data is interpreted by the human ear as poc noises. To avoid this the following software workaround need to be applied when starting capture: 1/ enable PDMC channel 2/ wait 150ms 3/ execute 16 dummy reads from RHR 4/ clear interrupts 5/ enable interrupts 6/ enable DMA channel For this workaround to work step 6 need to be executed at the end. For step 6 was added patch 1/3 from this series. With this, component DAI driver sets its struct snd_soc_component_driver::start_dma_last = 1 and proper action is taken based on this flag when starting DAI trigger vs DMA. --- 11d4e474861aa3443e52251660e5928103380715