[PATCH v2] driver: pwm: pwm-imx: fix probing on imx6

Tom Rini trini at konsulko.com
Tue Aug 13 18:16:07 CEST 2024


On Tue, Aug 13, 2024 at 03:57:08PM +0200, Heiko Schocher wrote:
> Hello Fabio, Tom,
> 
> On 13.08.24 14:27, Fabio Estevam wrote:
> > Hi Heiko,
> > 
> > On Wed, Aug 7, 2024 at 12:53 PM Heiko Schocher <hs at denx.de> wrote:
> > > 
> > > U-Boot 2024.07 drops on aristainetos2 board the following
> > > warning:
> > > 
> > >          Failed to enable per_clk
> > > 
> > > and bootlogo is not seen on LVDS display.
> > > 
> > > This patch uses old behaviour for systems without clock framework
> > > if CONFIG_CLK is not enabled.
> > > 
> > > Fixes: bfc778cb93a3 ("driver: pwm: pwm-imx: get and enable per/ipg clock using dm")
> > > 
> > > Signed-off-by: Heiko Schocher <hs at denx.de>
> > > ---
> > > 
> > > Changes in v2:
> > > use CONFIG_IS_ENABLED instead of IS_ENABLED
> > > as Anatolij suggested.
> > 
> > This causes build failures:
> > 
> > https://source.denx.de/u-boot/custodians/u-boot-imx/-/jobs/887503
> > 
> > Please fix and resend.
> 
> Hmm... yes ... I work/worked on aristainetos2 board update for 2024.07
> (or later)  ... and saw this
> 
>   Failed to enable per_clk
> 
> warning when 2024.07 boots ... and bootlogo did not work anymore, as
> backlight is pwm driven on this hardware...
> 
> I bet, for all the boards which fail in the azure run with this patch,
> PWM do not work anymore... because CONFIG_CLK is not enabled for them!
> 
> I am really unhappy, that I have no automated U-Boot runtime tests anymore
> running on real hardware... setup with tbot was very easy, but had no
> time for looking at the bugs poping up...
> 
> Hmm... looking in git history, there comes this commit in my eyes:
> 
> commit 4eea76574062e9079b6a267229962d6ec0be910a
> Author: Tom Rini <trini at konsulko.com>
> Date:   Sat Nov 19 18:45:18 2022 -0500
> 
>     pwm: imx: Remove unused references to CONFIG_IMX6_PWM_PER_CLK
> 
>     On platforms that use DM_PWM, we do not need to define this value
>     anymore, so remove it from config files.
> 
>     Signed-off-by: Tom Rini <trini at konsulko.com>
> 
> which exactly removes for all breaking boards this define...
> 
> Should we revert this patch?
> 
> I just can say for the aristianetos2 board, that I readded exactly this
> define in my work for the port to currentmainline ... and with my patch,
> pwm and so bootlogo works again ...

We can't do a strict revert, no, the symbol is now CFG_IMX6_PWM_PER_CLK.
But also, isn't this board using DM_PWM? And if so, that value isn't
used?

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: not available
URL: <https://lists.denx.de/pipermail/u-boot/attachments/20240813/b2d5a30f/attachment.sig>


More information about the U-Boot mailing list