Skip to content

Commit

Permalink
wifi: wilc1000: Re-enable RTC clock on resume
Browse files Browse the repository at this point in the history
The wilc_sdio_suspend() does clk_disable_unprepare() on rtc_clk clock,
make sure wilc_sdio_resume() does matching clk_prepare_enable(), else
any suspend/resume cycle leads to clock disable/enable imbalance. Fix
the imbalance.

Signed-off-by: Marek Vasut <marex@denx.de>
Reviewed-by: Alexis Lothoré <alexis.lothore@bootlin.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://patch.msgid.link/20240821183717.163235-1-marex@denx.de
  • Loading branch information
Marek Vasut authored and Kalle Valo committed Sep 3, 2024
1 parent b0dc701 commit 0c896ec
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions drivers/net/wireless/microchip/wilc1000/sdio.c
Original file line number Diff line number Diff line change
Expand Up @@ -1006,6 +1006,9 @@ static int wilc_sdio_resume(struct device *dev)
if (!wilc->initialized)
return 0;

if (!IS_ERR(wilc->rtc_clk))
clk_prepare_enable(wilc->rtc_clk);

wilc_sdio_init(wilc, true);
wilc_sdio_enable_interrupt(wilc);

Expand Down

0 comments on commit 0c896ec

Please sign in to comment.