From: Greg Kroah-Hartman Date: Thu, 29 Feb 2024 20:29:40 +0000 (+0100) Subject: 5.15-stable patches X-Git-Tag: v4.19.308~2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=7925ce690366ac1961cb865ed1f45fbdaf70d7b3;p=thirdparty%2Fkernel%2Fstable-queue.git 5.15-stable patches added patches: r8169-use-new-pm-macros.patch --- diff --git a/queue-5.15/r8169-use-new-pm-macros.patch b/queue-5.15/r8169-use-new-pm-macros.patch new file mode 100644 index 00000000000..be0624d7ed9 --- /dev/null +++ b/queue-5.15/r8169-use-new-pm-macros.patch @@ -0,0 +1,69 @@ +From 8fe6e670640e79adbe6fff5438cd324e468c280e Mon Sep 17 00:00:00 2001 +From: Heiner Kallweit +Date: Mon, 24 Jan 2022 22:17:17 +0100 +Subject: r8169: use new PM macros + +From: Heiner Kallweit + +commit 8fe6e670640e79adbe6fff5438cd324e468c280e upstream. + +This is based on series [0] that extended the PM core. Now the compiler +can see the PM callbacks also on systems not defining CONFIG_PM. +The optimizer will remove the functions then in this case. + +[0] https://lore.kernel.org/netdev/20211207002102.26414-1-paul@crapouillou.net/ + +Signed-off-by: Heiner Kallweit +Signed-off-by: David S. Miller +Cc: Guenter Roeck +Signed-off-by: Greg Kroah-Hartman +--- + drivers/net/ethernet/realtek/r8169_main.c | 14 +++++--------- + 1 file changed, 5 insertions(+), 9 deletions(-) + +--- a/drivers/net/ethernet/realtek/r8169_main.c ++++ b/drivers/net/ethernet/realtek/r8169_main.c +@@ -4897,8 +4897,6 @@ static void rtl8169_net_suspend(struct r + rtl8169_down(tp); + } + +-#ifdef CONFIG_PM +- + static int rtl8169_runtime_resume(struct device *dev) + { + struct rtl8169_private *tp = dev_get_drvdata(dev); +@@ -4914,7 +4912,7 @@ static int rtl8169_runtime_resume(struct + return 0; + } + +-static int __maybe_unused rtl8169_suspend(struct device *device) ++static int rtl8169_suspend(struct device *device) + { + struct rtl8169_private *tp = dev_get_drvdata(device); + +@@ -4927,7 +4925,7 @@ static int __maybe_unused rtl8169_suspen + return 0; + } + +-static int __maybe_unused rtl8169_resume(struct device *device) ++static int rtl8169_resume(struct device *device) + { + struct rtl8169_private *tp = dev_get_drvdata(device); + +@@ -4969,13 +4967,11 @@ static int rtl8169_runtime_idle(struct d + } + + static const struct dev_pm_ops rtl8169_pm_ops = { +- SET_SYSTEM_SLEEP_PM_OPS(rtl8169_suspend, rtl8169_resume) +- SET_RUNTIME_PM_OPS(rtl8169_runtime_suspend, rtl8169_runtime_resume, +- rtl8169_runtime_idle) ++ SYSTEM_SLEEP_PM_OPS(rtl8169_suspend, rtl8169_resume) ++ RUNTIME_PM_OPS(rtl8169_runtime_suspend, rtl8169_runtime_resume, ++ rtl8169_runtime_idle) + }; + +-#endif /* CONFIG_PM */ +- + static void rtl_wol_shutdown_quirk(struct rtl8169_private *tp) + { + /* WoL fails with 8168b when the receiver is disabled. */ diff --git a/queue-5.15/series b/queue-5.15/series index f66eeb3abe0..a24a45e6354 100644 --- a/queue-5.15/series +++ b/queue-5.15/series @@ -243,3 +243,4 @@ netfilter-nf_tables-fix-scheduling-while-atomic-splat.patch ext4-regenerate-buddy-after-block-freeing-failed-if-under-fc-replay.patch ext4-avoid-bb_free-and-bb_fragments-inconsistency-in-mb_free_blocks.patch netfilter-nf_tables-can-t-schedule-in-nft_chain_validate.patch +r8169-use-new-pm-macros.patch