net: ethernet: ti: am65-cpsw: keep active if cpts enabled
Some K3 CPSW NUSS instances can lose context after PM runtime ON->OFF->ON transition depending on integration (including all submodules: CPTS, MDIO, etc), like J721E Main CPSW (CPSW9G). In case CPTS is enabled it's initialized during probe and does not expect to be reset. Hence, keep K3 CPSW active by forbidding PM runtime if CPTS is enabled. Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com> Reviewed-by: Jesse Brandeburg <jesse.brandeburg@intel.com> Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
parent
2d64a03432
commit
a9c7470072
drivers/net/ethernet/ti
|
@ -1727,6 +1727,13 @@ static int am65_cpsw_init_cpts(struct am65_cpsw_common *common)
|
|||
return ret;
|
||||
}
|
||||
common->cpts = cpts;
|
||||
/* Forbid PM runtime if CPTS is running.
|
||||
* K3 CPSWxG modules may completely lose context during ON->OFF
|
||||
* transitions depending on integration.
|
||||
* AM65x/J721E MCU CPSW2G: false
|
||||
* J721E MAIN_CPSW9G: true
|
||||
*/
|
||||
pm_runtime_forbid(dev);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue