clk: qcom: gdsc: treat optional supplies as optional
Subsystems (4)
PATCH 1/1 clk: qcom: gdsc: treat optional supplies as optional
Since commit deebc79b28d6 ("clk: qcom: gpucc-sc8280xp: Add external supply for GX gdsc") the GDSC supply must be treated as optional to avoid warnings like:
gpu_cc-sc8280xp 3d90000.clock-controller: supply vdd-gfx not found, using dummy regulator
on SC8280XP.
Fortunately, the driver is already prepared to handle this by checking that the regulator pointer is non-NULL before use.
This also avoids triggering a potential deadlock on SC8280XP even if the underlying issue still remains for the derivative platforms like SA8295P that actually use the supply.
--- drivers/clk/qcom/gdsc.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-)
drivers/clk/qcom/gdsc.c +8 -3
@@ -487,9 +487,14 @@ int gdsc_register(struct gdsc_desc *desc,if (!scs[i] || !scs[i]->supply)continue ; - scs[i]->rsupply =devm_regulator_get (dev, scs[i]->supply); -if (IS_ERR (scs[i]->rsupply)) -return PTR_ERR (scs[i]->rsupply); + scs[i]->rsupply =devm_regulator_get_optional (dev, scs[i]->supply); +if (IS_ERR (scs[i]->rsupply)) { + ret =PTR_ERR (scs[i]->rsupply); +if (ret != -ENODEV ) +return ret; + + scs[i]->rsupply =NULL ; + } } data->num_domains = num;
Signature · 1 line
2.43.0
Quoted 11 lines · Johan Hovold
Since commit
deebc79b28d6("clk: qcom: gpucc-sc8280xp: Add external supply for GX gdsc") the GDSC supply must be treated as optional to avoid warnings like:gpu_cc-sc8280xp 3d90000.clock-controller: supply vdd-gfx not found, using dummy regulatoron SC8280XP.
Fortunately, the driver is already prepared to handle this by checking that the regulator pointer is non-NULL before use.
Quoted 7 lines
This also avoids triggering a potential deadlock on SC8280XP even if the underlying issue still remains for the derivative platforms like SA8295P that actually use the supply.
Fixes deebc79b28d6 ("clk: qcom: gpucc-sc8280xp: Add external supply for GX gdsc")Signed-off-by Johan Hovold <[email protected]>
Thanks for fixing this, it never made it off my todo list...
Regards,
Bjorn
Quoted 29 lines
--- drivers/clk/qcom/gdsc.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-)drivers/clk/qcom/gdsc.c +8
-3@@ -487,9 +487,14 @@ int gdsc_register(struct gdsc_desc *desc,if (!scs[i] || !scs[i]->supply)continue ; - scs[i]->rsupply =devm_regulator_get (dev, scs[i]->supply); -if (IS_ERR (scs[i]->rsupply)) -return PTR_ERR (scs[i]->rsupply); + scs[i]->rsupply =devm_regulator_get_optional (dev, scs[i]->supply); +if (IS_ERR (scs[i]->rsupply)) { + ret =PTR_ERR (scs[i]->rsupply); +if (ret != -ENODEV ) +return ret; + + scs[i]->rsupply =NULL ; + } } data->num_domains = num;Signature · 1 line
2.43.0
Quoted 9 lines · Johan Hovold
Since commit
deebc79b28d6("clk: qcom: gpucc-sc8280xp: Add external supply for GX gdsc") the GDSC supply must be treated as optional to avoid warnings like:gpu_cc-sc8280xp 3d90000.clock-controller: supply vdd-gfx not found, using dummy regulatoron SC8280XP.
[...]
Applied, thanks!
[1/1] clk: qcom: gdsc: treat optional supplies as optional
commit: 6677196fb1932e60b88ad0794a7ae532df178654
Best regards,
Signature · 1 line
Bjorn Andersson <[email protected]>
Quoted 8 lines · Bjorn Andersson
Quoted 6 lines · Johan Hovold
Since commit
deebc79b28d6("clk: qcom: gpucc-sc8280xp: Add external supply for GX gdsc") the GDSC supply must be treated as optional to avoid warnings like:gpu_cc-sc8280xp 3d90000.clock-controller: supply vdd-gfx not found, using dummy regulator
Quoted 8 lines
Quoted 3 lines
on SC8280XP.
[...]
Applied, thanks!
[1/1] clk: qcom: gdsc: treat optional supplies as optional
commit: 6677196fb1932e60b88ad0794a7ae532df178654
Bjorn, quick question: this regression fix after more than two and a half weeks is not yet mainlined. Is there a reason? Or am I missing something here?
Ciao, Thorsten (wearing his 'the Linux kernel's regression tracker' hat) --
Everything you wanna know about Linux kernel regression tracking:
https://linux-regtracking.leemhuis.info/about/#tldr
If I did something stupid, please tell me, as explained on that page.
#regzbot poke
Bjorn Andersson
maintainerQuoted 13 lines · Linux regression tracking (Thorsten Leemhuis)
Quoted 12 lines · Bjorn Andersson
Quoted 9 lines · Johan Hovold
Since commit
deebc79b28d6("clk: qcom: gpucc-sc8280xp: Add external supply for GX gdsc") the GDSC supply must be treated as optional to avoid warnings like:gpu_cc-sc8280xp 3d90000.clock-controller: supply vdd-gfx not found, using dummy regulatoron SC8280XP.
[...]
Quoted 9 lines
Quoted 4 lines
Applied, thanks!
[1/1] clk: qcom: gdsc: treat optional supplies as optional
commit: 6677196fb1932e60b88ad0794a7ae532df178654Bjorn, quick question: this regression fix after more than two and a half weeks is not yet mainlined. Is there a reason? Or am I missing something here?
I failed to propagate it, until only a few days back. It should show up shortly.
Thanks,
Bjorn
Quoted 7 lines
Ciao, Thorsten (wearing his 'the Linux kernel's regression tracker' hat) --
Everything you wanna know about Linux kernel regression tracking:
https://linux-regtracking.leemhuis.info/about/#tldr
If I did something stupid, please tell me, as explained on that page.#regzbot poke