summaryrefslogtreecommitdiff
path: root/debian/patches/debian/dfsg/r8169-rtl8168d-1-2-disable.patch
blob: db385632886af2872327d06c6c7e336aa752ca9c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
From 8ee9e3b6b1f41934a67567aaefae986ff517587e Mon Sep 17 00:00:00 2001
From: Ben Hutchings <ben@decadent.org.uk>
Date: Tue, 3 Nov 2009 23:58:25 +0000
Subject: [PATCH 21/24] r8169: mark firmware for removal and mark code using it as broken

---
 drivers/net/r8169.c |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/drivers/net/r8169.c b/drivers/net/r8169.c
index fa49356..3495ff6 100644
--- a/drivers/net/r8169.c
+++ b/drivers/net/r8169.c
@@ -1719,6 +1719,7 @@ static void rtl8168d_1_hw_phy_config(void __iomem *ioaddr)
 		{ 0x05, 0x8332 },
 		{ 0x06, 0x5561 }
 	};
+#ifdef REMOVE_DFSG
 	static const struct phy_reg phy_reg_init_2[] = {
 		{ 0x1f, 0x0005 },
 		{ 0x05, 0xffc2 },
@@ -2074,6 +2075,7 @@ static void rtl8168d_1_hw_phy_config(void __iomem *ioaddr)
 		{ 0x0d, 0xf880 },
 		{ 0x1f, 0x0000 }
 	};
+#endif
 
 	rtl_phy_write(ioaddr, phy_reg_init_0, ARRAY_SIZE(phy_reg_init_0));
 
@@ -2131,7 +2133,9 @@ static void rtl8168d_1_hw_phy_config(void __iomem *ioaddr)
 	mdio_plus_minus(ioaddr, 0x02, 0x0100, 0x0600);
 	mdio_plus_minus(ioaddr, 0x03, 0x0000, 0xe000);
 
+#ifdef CONFIG_BROKEN
 	rtl_phy_write(ioaddr, phy_reg_init_2, ARRAY_SIZE(phy_reg_init_2));
+#endif
 }
 
 static void rtl8168d_2_hw_phy_config(void __iomem *ioaddr)
@@ -2161,6 +2165,7 @@ static void rtl8168d_2_hw_phy_config(void __iomem *ioaddr)
 		{ 0x05, 0x8332 },
 		{ 0x06, 0x5561 }
 	};
+#ifdef REMOVE_DFSG
 	static const struct phy_reg phy_reg_init_1[] = {
 		{ 0x1f, 0x0005 },
 		{ 0x05, 0xffc2 },
@@ -2473,6 +2478,7 @@ static void rtl8168d_2_hw_phy_config(void __iomem *ioaddr)
 		{ 0x0d, 0xf880 },
 		{ 0x1f, 0x0000 }
 	};
+#endif
 
 	rtl_phy_write(ioaddr, phy_reg_init_0, ARRAY_SIZE(phy_reg_init_0));
 
@@ -2526,7 +2532,9 @@ static void rtl8168d_2_hw_phy_config(void __iomem *ioaddr)
 	mdio_write(ioaddr, 0x1f, 0x0002);
 	mdio_patch(ioaddr, 0x0f, 0x0017);
 
+#ifdef CONFIG_BROKEN
 	rtl_phy_write(ioaddr, phy_reg_init_1, ARRAY_SIZE(phy_reg_init_1));
+#endif
 }
 
 static void rtl8168d_3_hw_phy_config(void __iomem *ioaddr)
-- 
1.6.5.2