Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

phy: cadence-torrent: register resets even if the phy is already configured

Resets are needed during suspend and resume stages.
So they shall be registered during the probe even the phy is already
initialized.

The function cdns_torrent_reset is renamed cdns_torrent_of_get_reset() to
make it clear.

Signed-off-by: Thomas Richard <thomas.richard@bootlin.com>
Link: https://lore.kernel.org/r/20240412-j7200-phy-s2r-v1-5-f15815833974@bootlin.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>

authored by

Thomas Richard and committed by
Vinod Koul
8512b687 c2286092

+5 -5
+5 -5
drivers/phy/cadence/phy-cadence-torrent.c
··· 2678 2678 return 0; 2679 2679 } 2680 2680 2681 - static int cdns_torrent_reset(struct cdns_torrent_phy *cdns_phy) 2681 + static int cdns_torrent_of_get_reset(struct cdns_torrent_phy *cdns_phy) 2682 2682 { 2683 2683 struct device *dev = cdns_phy->dev; 2684 2684 ··· 2847 2847 if (ret) 2848 2848 return ret; 2849 2849 2850 + ret = cdns_torrent_of_get_reset(cdns_phy); 2851 + if (ret) 2852 + goto clk_cleanup; 2853 + 2850 2854 ret = cdns_torrent_of_get_clk(cdns_phy); 2851 2855 if (ret) 2852 2856 goto clk_cleanup; ··· 2858 2854 regmap_field_read(cdns_phy->phy_pma_cmn_ctrl_1, &already_configured); 2859 2855 2860 2856 if (!already_configured) { 2861 - ret = cdns_torrent_reset(cdns_phy); 2862 - if (ret) 2863 - goto clk_cleanup; 2864 - 2865 2857 ret = cdns_torrent_clk(cdns_phy); 2866 2858 if (ret) 2867 2859 goto clk_cleanup;