Help: i.MX8MP AUDIOMIX BLK-CTRL CLK driver support
Peng Fan
peng.fan at oss.nxp.com
Mon Sep 26 20:26:53 PDT 2022
Hi Marek,
On 9/26/2022 8:04 AM, Marek Vasut wrote:
> On 9/23/22 05:41, Peng Fan wrote:
>> Hi All,
>
> Hi,
>
>> I would start a discussion about the A/B B/A lock issue when make
>> audiomix blk ctrl function as clk provider.
>>
>> I not have good idea on this, hope you have any suggestions.
>>
>> major issue is: the blk ctrl clk has a power domain supplier
>> The power domain supplier also use clk API to prepare_enable clks.
>> The blk ctrl clk driver has runtime pm enabled.
>>
>> The NXP downstream:
>> The dts:
>> https://github.com/nxp-imx/linux-imx/blob/lf-5.15.y/arch/arm64/boot/dts/freescale/imx8mp.dtsi#L1872
>>
>> The driver:
>> https://github.com/nxp-imx/linux-imx/blob/lf-5.15.y/drivers/clk/imx/clk-imx8mp.c
>> https://github.com/nxp-imx/linux-imx/blob/lf-5.15.y/drivers/clk/imx/clk-blk-ctrl.c
>>
>> Note: The following log was reproduced with NXP downstream. For upstream
>> I think we have similar issue if we still take audiomix blk ctrl as clk
>> driver. Because the gpcv2 also use clk prepare enable API.
>> 1. deadlock 1:
>> Callchain after enable some lock debug:
>> clk_ignore_unused will use lock seq: take prepare lock, take blk-ctrl
>> parent power domain genpd lock
>> genpd_power_off_work_fun will use lock seq: take the power domain
>> genpd lock, take prepare lock.
>
> There is also this driver which does not suffer from the problem, at
> least I didn't trigger it while using it for months:
>
> https://patchwork.kernel.org/project/linux-clk/patch/20220625013235.710346-3-marex@denx.de/
yes, I see that, I thought Abel picked up, but seems still not land in.
I'll use your patches and need apply to nxp 5.15 tree for some test.
Thanks,
Peng.
More information about the linux-arm-kernel
mailing list