diff options
author | Roy Pledge <roy.pledge@nxp.com> | 2020-11-03 23:05:55 +0300 |
---|---|---|
committer | Li Yang <leoyang.li@nxp.com> | 2021-04-06 19:22:39 +0300 |
commit | c4e38b2a27a852ed1507163a9cc5b3a9d2a2da97 (patch) | |
tree | f5f9dee65580fa5da69368d3e2052bca9147a558 /drivers/soc/fsl/qbman/qman_portal.c | |
parent | a38fd8748464831584a19438cbb3082b5a2dab15 (diff) | |
download | linux-c4e38b2a27a852ed1507163a9cc5b3a9d2a2da97.tar.xz |
soc: fsl: qbman: Ensure device cleanup is run for kexec
Make sure that the QBMan device cleanup routines are executed
when the device was previously initialized. This is needed for
kexec since the device will keep it's state from the previous
kernel that was executing.
Signed-off-by: Roy Pledge <roy.pledge@nxp.com>
Signed-off-by: Li Yang <leoyang.li@nxp.com>
Diffstat (limited to 'drivers/soc/fsl/qbman/qman_portal.c')
-rw-r--r-- | drivers/soc/fsl/qbman/qman_portal.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/soc/fsl/qbman/qman_portal.c b/drivers/soc/fsl/qbman/qman_portal.c index 5685b6706893..4274bd1b0f99 100644 --- a/drivers/soc/fsl/qbman/qman_portal.c +++ b/drivers/soc/fsl/qbman/qman_portal.c @@ -302,7 +302,7 @@ static int qman_portal_probe(struct platform_device *pdev) __qman_portals_probed = 1; /* unassigned portal, skip init */ spin_unlock(&qman_lock); - return 0; + goto check_cleanup; } cpumask_set_cpu(cpu, &portal_cpus); @@ -323,6 +323,7 @@ static int qman_portal_probe(struct platform_device *pdev) if (!cpu_online(cpu)) qman_offline_cpu(cpu); +check_cleanup: if (__qman_portals_probed == 1 && qman_requires_cleanup()) { /* * QMan wasn't reset prior to boot (Kexec for example) |