Coresight: Add support for new APB clock name

Add support for new APB clock-name. If the function fails
to obtain the clock with the name "apb_pclk", it will
attempt to acquire the clock with the name "apb".

Reviewed-by: James Clark <james.clark@linaro.org>
Signed-off-by: Jie Gan <quic_jiegan@quicinc.com>
Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com>
Link: https://lore.kernel.org/r/20250303032931.2500935-2-quic_jiegan@quicinc.com
This commit is contained in:
Jie Gan 2025-03-03 11:29:22 +08:00 committed by Suzuki K Poulose
parent 1e4e454223
commit dc872c5f52

View File

@ -471,8 +471,11 @@ static inline struct clk *coresight_get_enable_apb_pclk(struct device *dev)
int ret;
pclk = clk_get(dev, "apb_pclk");
if (IS_ERR(pclk))
return NULL;
if (IS_ERR(pclk)) {
pclk = clk_get(dev, "apb");
if (IS_ERR(pclk))
return NULL;
}
ret = clk_prepare_enable(pclk);
if (ret) {