From: Greg Kroah-Hartman Date: Wed, 10 Oct 2012 00:32:15 +0000 (+0900) Subject: 3.4-stable patches X-Git-Tag: v3.0.46~20 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=9c37957c60cff39d6f78135e6e110d02cd2fa20f;p=thirdparty%2Fkernel%2Fstable-queue.git 3.4-stable patches added patches: r8169-8168c-and-later-require-bit-0x20-to-be-set-in-config2-for-pme-signaling.patch r8169-config1-is-read-only-on-8168c-and-later.patch --- diff --git a/queue-3.4/r8169-8168c-and-later-require-bit-0x20-to-be-set-in-config2-for-pme-signaling.patch b/queue-3.4/r8169-8168c-and-later-require-bit-0x20-to-be-set-in-config2-for-pme-signaling.patch new file mode 100644 index 00000000000..e4486674ae7 --- /dev/null +++ b/queue-3.4/r8169-8168c-and-later-require-bit-0x20-to-be-set-in-config2-for-pme-signaling.patch @@ -0,0 +1,44 @@ +From stable-owner@vger.kernel.org Sat Oct 6 18:39:51 2012 +From: Francois Romieu +Date: Sat, 6 Oct 2012 11:19:53 +0200 +Subject: r8169: 8168c and later require bit 0x20 to be set in Config2 for PME signaling. +To: stable@vger.kernel.org +Cc: Hayes Wang + +From: Francois Romieu + +commit d387b427c973974dd619a33549c070ac5d0e089f upstream. + +The new 84xx stopped flying below the radars. + +Signed-off-by: Francois Romieu +Cc: Hayes Wang +Acked-by: David S. Miller +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/net/ethernet/realtek/r8169.c | 6 ++++++ + 1 file changed, 6 insertions(+) + +--- a/drivers/net/ethernet/realtek/r8169.c ++++ b/drivers/net/ethernet/realtek/r8169.c +@@ -319,6 +319,8 @@ enum rtl_registers { + Config0 = 0x51, + Config1 = 0x52, + Config2 = 0x53, ++#define PME_SIGNAL (1 << 5) /* 8168c and later */ ++ + Config3 = 0x54, + Config4 = 0x55, + Config5 = 0x56, +@@ -1426,6 +1428,10 @@ static void __rtl8169_set_wol(struct rtl + RTL_W8(Config1, options); + break; + default: ++ options = RTL_R8(Config2) & ~PME_SIGNAL; ++ if (wolopts) ++ options |= PME_SIGNAL; ++ RTL_W8(Config2, options); + break; + } + diff --git a/queue-3.4/r8169-config1-is-read-only-on-8168c-and-later.patch b/queue-3.4/r8169-config1-is-read-only-on-8168c-and-later.patch new file mode 100644 index 00000000000..cece90b12a0 --- /dev/null +++ b/queue-3.4/r8169-config1-is-read-only-on-8168c-and-later.patch @@ -0,0 +1,61 @@ +From stable-owner@vger.kernel.org Sat Oct 6 18:39:51 2012 +From: Francois Romieu +Date: Sat, 6 Oct 2012 11:19:52 +0200 +Subject: r8169: Config1 is read-only on 8168c and later. +To: stable@vger.kernel.org +Cc: Hayes Wang + +From: Francois Romieu + +commit 851e60221926a53344b4227879858bef841b0477 upstream. + +Suggested by Hayes. + +Signed-off-by: Francois Romieu +Cc: Hayes Wang +Acked-by: David S. Miller +Signed-off-by: Greg Kroah-Hartman +--- + drivers/net/ethernet/realtek/r8169.c | 15 +++++++++++++-- + 1 file changed, 13 insertions(+), 2 deletions(-) + +--- a/drivers/net/ethernet/realtek/r8169.c ++++ b/drivers/net/ethernet/realtek/r8169.c +@@ -1400,7 +1400,6 @@ static void __rtl8169_set_wol(struct rtl + u16 reg; + u8 mask; + } cfg[] = { +- { WAKE_ANY, Config1, PMEnable }, + { WAKE_PHY, Config3, LinkUp }, + { WAKE_MAGIC, Config3, MagicPacket }, + { WAKE_UCAST, Config5, UWF }, +@@ -1408,16 +1407,28 @@ static void __rtl8169_set_wol(struct rtl + { WAKE_MCAST, Config5, MWF }, + { WAKE_ANY, Config5, LanWake } + }; ++ u8 options; + + RTL_W8(Cfg9346, Cfg9346_Unlock); + + for (i = 0; i < ARRAY_SIZE(cfg); i++) { +- u8 options = RTL_R8(cfg[i].reg) & ~cfg[i].mask; ++ options = RTL_R8(cfg[i].reg) & ~cfg[i].mask; + if (wolopts & cfg[i].opt) + options |= cfg[i].mask; + RTL_W8(cfg[i].reg, options); + } + ++ switch (tp->mac_version) { ++ case RTL_GIGA_MAC_VER_01 ... RTL_GIGA_MAC_VER_17: ++ options = RTL_R8(Config1) & ~PMEnable; ++ if (wolopts) ++ options |= PMEnable; ++ RTL_W8(Config1, options); ++ break; ++ default: ++ break; ++ } ++ + RTL_W8(Cfg9346, Cfg9346_Lock); + } + diff --git a/queue-3.4/series b/queue-3.4/series index 02d66177a48..d9041e0e905 100644 --- a/queue-3.4/series +++ b/queue-3.4/series @@ -96,3 +96,5 @@ cris-add-missing-rcu-idle-apis-on-idle-loop.patch m32r-add-missing-rcu-idle-apis-on-idle-loop.patch score-add-missing-rcu-idle-apis-on-idle-loop.patch rcu-fix-day-one-dyntick-idle-stall-warning-bug.patch +r8169-config1-is-read-only-on-8168c-and-later.patch +r8169-8168c-and-later-require-bit-0x20-to-be-set-in-config2-for-pme-signaling.patch