mirror of
https://github.com/raspberrypi/linux.git
synced 2025-12-06 10:00:17 +00:00
atlantic: Fix driver resume flow.
[ Upstream commit57f780f1c4] Driver crashes when restoring from the Hibernate. In the resume flow, driver need to clean up the older nic/vec objects and re-initialize them. Fixes:8aaa112a57("net: atlantic: refactoring pm logic") Signed-off-by: Sudarsana Reddy Kalluru <skalluru@marvell.com> Signed-off-by: Igor Russkikh <irusskikh@marvell.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
cb996dc9f9
commit
26fae720c1
@@ -417,6 +417,9 @@ static int atl_resume_common(struct device *dev, bool deep)
|
|||||||
pci_restore_state(pdev);
|
pci_restore_state(pdev);
|
||||||
|
|
||||||
if (deep) {
|
if (deep) {
|
||||||
|
/* Reinitialize Nic/Vecs objects */
|
||||||
|
aq_nic_deinit(nic, !nic->aq_hw->aq_nic_cfg->wol);
|
||||||
|
|
||||||
ret = aq_nic_init(nic);
|
ret = aq_nic_init(nic);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto err_exit;
|
goto err_exit;
|
||||||
|
|||||||
Reference in New Issue
Block a user