From a36c360d8aab3b79c49bc3f0a03b7257db7180c5 Mon Sep 17 00:00:00 2001 From: Sasha Levin Date: Fri, 17 Jul 2020 13:15:26 -0400 Subject: [PATCH] Fixes for 5.4 Signed-off-by: Sasha Levin --- ...platform-set-pm-runtime-as-active-on.patch | 55 +++++++++++++++++ ...platform-fix-a-warning-when-hibernat.patch | 56 +++++++++++++++++ ...plat-set-pm-runtime-as-active-on-res.patch | 61 +++++++++++++++++++ queue-5.4/series | 3 + 4 files changed, 175 insertions(+) create mode 100644 queue-5.4/revert-usb-ehci-platform-set-pm-runtime-as-active-on.patch create mode 100644 queue-5.4/revert-usb-ohci-platform-fix-a-warning-when-hibernat.patch create mode 100644 queue-5.4/revert-usb-xhci-plat-set-pm-runtime-as-active-on-res.patch diff --git a/queue-5.4/revert-usb-ehci-platform-set-pm-runtime-as-active-on.patch b/queue-5.4/revert-usb-ehci-platform-set-pm-runtime-as-active-on.patch new file mode 100644 index 00000000000..98dd6f11a89 --- /dev/null +++ b/queue-5.4/revert-usb-ehci-platform-set-pm-runtime-as-active-on.patch @@ -0,0 +1,55 @@ +From 84a6d8f252454d1c6590668dff7bf85819abcfcd Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Fri, 17 Jul 2020 13:01:10 -0400 +Subject: Revert "usb/ehci-platform: Set PM runtime as active on resume" + +This reverts commit 335d720bb4bd9d2808cae5af6f3c636c87f19596. + +Eugeniu Rosca writes: + +On Thu, Jul 09, 2020 at 09:00:23AM +0200, Eugeniu Rosca wrote: +>After integrating v4.14.186 commit 5410d158ca2a50 ("usb/ehci-platform: +>Set PM runtime as active on resume") into downstream v4.14.x, we started +>to consistently experience below panic [1] on every second s2ram of +>R-Car H3 Salvator-X Renesas reference board. +> +>After some investigations, we concluded the following: +> - the issue does not exist in vanilla v5.8-rc4+ +> - [bisecting shows that] the panic on v4.14.186 is caused by the lack +> of v5.6-rc1 commit 987351e1ea7772 ("phy: core: Add consumer device +> link support"). Getting evidence for that is easy. Reverting +> 987351e1ea7772 in vanilla leads to a similar backtrace [2]. +> +>Questions: +> - Backporting 987351e1ea7772 ("phy: core: Add consumer device +> link support") to v4.14.187 looks challenging enough, so probably not +> worth it. Anybody to contradict this? +> - Assuming no plans to backport the missing mainline commit to v4.14.x, +> should the following three v4.14.186 commits be reverted on v4.14.x? +> * baef809ea497a4 ("usb/ohci-platform: Fix a warning when hibernating") +> * 9f33eff4958885 ("usb/xhci-plat: Set PM runtime as active on resume") +> * 5410d158ca2a50 ("usb/ehci-platform: Set PM runtime as active on resume") + +Signed-off-by: Sasha Levin +--- + drivers/usb/host/ehci-platform.c | 4 ---- + 1 file changed, 4 deletions(-) + +diff --git a/drivers/usb/host/ehci-platform.c b/drivers/usb/host/ehci-platform.c +index e9a49007cce4a..e4fc3f66d43bf 100644 +--- a/drivers/usb/host/ehci-platform.c ++++ b/drivers/usb/host/ehci-platform.c +@@ -455,10 +455,6 @@ static int ehci_platform_resume(struct device *dev) + + ehci_resume(hcd, priv->reset_on_resume); + +- pm_runtime_disable(dev); +- pm_runtime_set_active(dev); +- pm_runtime_enable(dev); +- + if (priv->quirk_poll) + quirk_poll_init(priv); + +-- +2.25.1 + diff --git a/queue-5.4/revert-usb-ohci-platform-fix-a-warning-when-hibernat.patch b/queue-5.4/revert-usb-ohci-platform-fix-a-warning-when-hibernat.patch new file mode 100644 index 00000000000..5a1a3dfe184 --- /dev/null +++ b/queue-5.4/revert-usb-ohci-platform-fix-a-warning-when-hibernat.patch @@ -0,0 +1,56 @@ +From 736617a27ec356d7ea4068a87dbbb9ebde0f3636 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Fri, 17 Jul 2020 13:00:47 -0400 +Subject: Revert "usb/ohci-platform: Fix a warning when hibernating" + +This reverts commit fbf719e5da126c6b391ea7b1f38d4493582d8aaf. + +Eugeniu Rosca writes: + +On Thu, Jul 09, 2020 at 09:00:23AM +0200, Eugeniu Rosca wrote: +>After integrating v4.14.186 commit 5410d158ca2a50 ("usb/ehci-platform: +>Set PM runtime as active on resume") into downstream v4.14.x, we started +>to consistently experience below panic [1] on every second s2ram of +>R-Car H3 Salvator-X Renesas reference board. +> +>After some investigations, we concluded the following: +> - the issue does not exist in vanilla v5.8-rc4+ +> - [bisecting shows that] the panic on v4.14.186 is caused by the lack +> of v5.6-rc1 commit 987351e1ea7772 ("phy: core: Add consumer device +> link support"). Getting evidence for that is easy. Reverting +> 987351e1ea7772 in vanilla leads to a similar backtrace [2]. +> +>Questions: +> - Backporting 987351e1ea7772 ("phy: core: Add consumer device +> link support") to v4.14.187 looks challenging enough, so probably not +> worth it. Anybody to contradict this? +> - Assuming no plans to backport the missing mainline commit to v4.14.x, +> should the following three v4.14.186 commits be reverted on v4.14.x? +> * baef809ea497a4 ("usb/ohci-platform: Fix a warning when hibernating") +> * 9f33eff4958885 ("usb/xhci-plat: Set PM runtime as active on resume") +> * 5410d158ca2a50 ("usb/ehci-platform: Set PM runtime as active on resume") + +Signed-off-by: Sasha Levin +--- + drivers/usb/host/ohci-platform.c | 5 ----- + 1 file changed, 5 deletions(-) + +diff --git a/drivers/usb/host/ohci-platform.c b/drivers/usb/host/ohci-platform.c +index 4a8456f12a73d..7addfc2cbadce 100644 +--- a/drivers/usb/host/ohci-platform.c ++++ b/drivers/usb/host/ohci-platform.c +@@ -299,11 +299,6 @@ static int ohci_platform_resume(struct device *dev) + } + + ohci_resume(hcd, false); +- +- pm_runtime_disable(dev); +- pm_runtime_set_active(dev); +- pm_runtime_enable(dev); +- + return 0; + } + #endif /* CONFIG_PM_SLEEP */ +-- +2.25.1 + diff --git a/queue-5.4/revert-usb-xhci-plat-set-pm-runtime-as-active-on-res.patch b/queue-5.4/revert-usb-xhci-plat-set-pm-runtime-as-active-on-res.patch new file mode 100644 index 00000000000..e26116e80a9 --- /dev/null +++ b/queue-5.4/revert-usb-xhci-plat-set-pm-runtime-as-active-on-res.patch @@ -0,0 +1,61 @@ +From ae92ce689d1a3992049ed47a45888e45a96ddc44 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Fri, 17 Jul 2020 13:01:26 -0400 +Subject: Revert "usb/xhci-plat: Set PM runtime as active on resume" + +This reverts commit 57a1cd87efb9279ab58aae2e5c41920150e31873. + +Eugeniu Rosca writes: + +On Thu, Jul 09, 2020 at 09:00:23AM +0200, Eugeniu Rosca wrote: +>After integrating v4.14.186 commit 5410d158ca2a50 ("usb/ehci-platform: +>Set PM runtime as active on resume") into downstream v4.14.x, we started +>to consistently experience below panic [1] on every second s2ram of +>R-Car H3 Salvator-X Renesas reference board. +> +>After some investigations, we concluded the following: +> - the issue does not exist in vanilla v5.8-rc4+ +> - [bisecting shows that] the panic on v4.14.186 is caused by the lack +> of v5.6-rc1 commit 987351e1ea7772 ("phy: core: Add consumer device +> link support"). Getting evidence for that is easy. Reverting +> 987351e1ea7772 in vanilla leads to a similar backtrace [2]. +> +>Questions: +> - Backporting 987351e1ea7772 ("phy: core: Add consumer device +> link support") to v4.14.187 looks challenging enough, so probably not +> worth it. Anybody to contradict this? +> - Assuming no plans to backport the missing mainline commit to v4.14.x, +> should the following three v4.14.186 commits be reverted on v4.14.x? +> * baef809ea497a4 ("usb/ohci-platform: Fix a warning when hibernating") +> * 9f33eff4958885 ("usb/xhci-plat: Set PM runtime as active on resume") +> * 5410d158ca2a50 ("usb/ehci-platform: Set PM runtime as active on resume") + +Signed-off-by: Sasha Levin +--- + drivers/usb/host/xhci-plat.c | 10 +--------- + 1 file changed, 1 insertion(+), 9 deletions(-) + +diff --git a/drivers/usb/host/xhci-plat.c b/drivers/usb/host/xhci-plat.c +index 60d06e9b600f8..52c625c023410 100644 +--- a/drivers/usb/host/xhci-plat.c ++++ b/drivers/usb/host/xhci-plat.c +@@ -410,15 +410,7 @@ static int __maybe_unused xhci_plat_resume(struct device *dev) + if (ret) + return ret; + +- ret = xhci_resume(xhci, 0); +- if (ret) +- return ret; +- +- pm_runtime_disable(dev); +- pm_runtime_set_active(dev); +- pm_runtime_enable(dev); +- +- return 0; ++ return xhci_resume(xhci, 0); + } + + static int __maybe_unused xhci_plat_runtime_suspend(struct device *dev) +-- +2.25.1 + diff --git a/queue-5.4/series b/queue-5.4/series index afc634f8fff..d61c13baf2b 100644 --- a/queue-5.4/series +++ b/queue-5.4/series @@ -58,3 +58,6 @@ of-of_mdio-correct-loop-scanning-logic.patch net-macb-call-pm_runtime_put_sync-on-failure-path.patch net-ethernet-mvneta-do-not-error-out-in-non-serdes-m.patch net-ethernet-mvneta-add-back-interface-mode-validati.patch +revert-usb-ohci-platform-fix-a-warning-when-hibernat.patch +revert-usb-ehci-platform-set-pm-runtime-as-active-on.patch +revert-usb-xhci-plat-set-pm-runtime-as-active-on-res.patch -- 2.47.3