[PATCH] pwm/mtk-disp: change mm clock as optional

AngeloGioacchino Del Regno angelogioacchino.delregno at collabora.com
Mon Jan 13 00:51:16 PST 2025


Il 13/01/25 07:15, Bincai Liu ha scritto:
> mt8196 doesn't have mm clock. Make this clock optional for mt8196.
> 

This commit is okay, but you have to reflect that change in the bindings as well,
otherwise you get validation errors in devicetrees.

Cheers,
Angelo

> Signed-off-by: Bincai Liu <bincai.liu at mediatek.com>
> ---
>   drivers/pwm/pwm-mtk-disp.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/pwm/pwm-mtk-disp.c b/drivers/pwm/pwm-mtk-disp.c
> index bafd6b6195f6..ad7928cd607f 100644
> --- a/drivers/pwm/pwm-mtk-disp.c
> +++ b/drivers/pwm/pwm-mtk-disp.c
> @@ -250,7 +250,7 @@ static int mtk_disp_pwm_probe(struct platform_device *pdev)
>   		return dev_err_probe(&pdev->dev, PTR_ERR(mdp->clk_main),
>   				     "Failed to get main clock\n");
>   
> -	mdp->clk_mm = devm_clk_get(&pdev->dev, "mm");
> +	mdp->clk_mm = devm_clk_get_optional(&pdev->dev, "mm");
>   	if (IS_ERR(mdp->clk_mm))
>   		return dev_err_probe(&pdev->dev, PTR_ERR(mdp->clk_mm),
>   				     "Failed to get mm clock\n");





More information about the Linux-mediatek mailing list