Re: [PATCH 0/5] ASoC: mediatek: mt8186: Fix clock error handling
Bui Duc Phuc <[email protected]>
| Newsgroups | org.infradead.lists.linux-mediatek,org.infradead.lists.linux-arm-kernel,org.kernel.vger.linux-kernel,org.kernel.vger.linux-sound |
|---|---|
| Message-ID | <CAABR9nErEB6c-nQH+mvP2V+oz-tACQsiH0hY54p17CNovmZraQ@mail.gmail.com> |
> The changes therefore assume that the clocks used by the driver are > required. If these clocks are intended to be optional and > devm_clk_get_optional() is preferred, the clock users would also need > to check for missing clocks before calling clock APIs such as > clk_prepare_enable(), clk_disable_unprepare(), and clk_set_parent(). > > If that is the preferred approach, I can rework the series accordingly. I apologize for the confusion. clk_prepare_enable(), clk_disable_unprepare(), and clk_set_parent() already handle missing clocks and return 0 in that case. So I only need to confirm whether an optional clock is intended to be used here, so that I can revise the patch series accordingly. Best regards, Phuc