summaryrefslogtreecommitdiffstats
path: root/target/linux/ar7/patches-2.6.24/150-cpmac_up_and_running.diff
diff options
context:
space:
mode:
authornbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73>2009-03-14 15:52:42 +0000
committernbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73>2009-03-14 15:52:42 +0000
commit26e3776a22bf894ced5af4c28968dc1dc99968eb (patch)
tree2d38a3789e27a423439c37a45a09cae31990a615 /target/linux/ar7/patches-2.6.24/150-cpmac_up_and_running.diff
parent4bd70fc26256cf485f19e0c8b881e078dc36134f (diff)
nuke obsolete kernel stuff
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@14875 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/ar7/patches-2.6.24/150-cpmac_up_and_running.diff')
-rw-r--r--target/linux/ar7/patches-2.6.24/150-cpmac_up_and_running.diff95
1 files changed, 0 insertions, 95 deletions
diff --git a/target/linux/ar7/patches-2.6.24/150-cpmac_up_and_running.diff b/target/linux/ar7/patches-2.6.24/150-cpmac_up_and_running.diff
deleted file mode 100644
index c2fb478c4..000000000
--- a/target/linux/ar7/patches-2.6.24/150-cpmac_up_and_running.diff
+++ /dev/null
@@ -1,95 +0,0 @@
-From 0daaa095cefd9d7091a7ccce2ff89f1ff4feae7a Mon Sep 17 00:00:00 2001
-From: Anton Vorontsov <avorontsov@ru.mvista.com>
-Date: Wed, 5 Mar 2008 14:52:26 +0300
-Subject: [PATCH] AR7/cpmac: convert to new fixed phy infrastructure, now for real
-
-This patch converts platform code to register fixed phys early.
-cpmac driver modified to blindly accept fixed phy id (that is equal
-to platform device id).
-
-Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com>
----
- arch/mips/ar7/platform.c | 17 +++++++++++++++++
- drivers/net/cpmac.c | 19 +++----------------
- 2 files changed, 20 insertions(+), 16 deletions(-)
-
-Index: linux-2.6.24.7/arch/mips/ar7/platform.c
-===================================================================
---- linux-2.6.24.7.orig/arch/mips/ar7/platform.c
-+++ linux-2.6.24.7/arch/mips/ar7/platform.c
-@@ -33,6 +33,8 @@
- #include <linux/vlynq.h>
- #include <linux/leds.h>
- #include <linux/string.h>
-+#include <linux/phy.h>
-+#include <linux/phy_fixed.h>
-
- #include <asm/addrspace.h>
- #include <asm/ar7/ar7.h>
-@@ -205,6 +207,13 @@ static struct physmap_flash_data physmap
- .width = 2,
- };
-
-+/* lets assume this is suitable for both high and low cpmacs links */
-+static struct fixed_phy_status fixed_phy_status __initdata = {
-+ .link = 1,
-+ .speed = 100,
-+ .duplex = 1,
-+};
-+
- static struct plat_cpmac_data cpmac_low_data = {
- .reset_bit = 17,
- .power_bit = 20,
-@@ -506,6 +515,10 @@ static int __init ar7_register_devices(v
- }
-
- if (ar7_has_high_cpmac()) {
-+ res = fixed_phy_add(PHY_POLL, cpmac_high.id, &fixed_phy_status);
-+ if (res && res != -ENODEV)
-+ return res;
-+
- cpmac_get_mac(1, cpmac_high_data.dev_addr);
- res = platform_device_register(&cpmac_high);
- if (res)
-@@ -514,6 +527,10 @@ static int __init ar7_register_devices(v
- cpmac_low_data.phy_mask = 0xffffffff;
- }
-
-+ res = fixed_phy_add(PHY_POLL, cpmac_low.id, &fixed_phy_status);
-+ if (res && res != -ENODEV)
-+ return res;
-+
- cpmac_get_mac(0, cpmac_low_data.dev_addr);
- res = platform_device_register(&cpmac_low);
- if (res)
-Index: linux-2.6.24.7/drivers/net/cpmac.c
-===================================================================
---- linux-2.6.24.7.orig/drivers/net/cpmac.c
-+++ linux-2.6.24.7/drivers/net/cpmac.c
-@@ -1035,23 +1035,10 @@ static int __devinit cpmac_probe(struct
-
- if (phy_id == PHY_MAX_ADDR) {
- if (external_switch || dumb_switch) {
-- struct fixed_phy_status status = {};
--
-- mdio_bus_id = 0;
--
-- /*
-- * FIXME: this should be in the platform code!
-- * Since there is not platform code at all (that is,
-- * no mainline users of that driver), place it here
-- * for now.
-- */
-- phy_id = 0;
-- status.link = 1;
-- status.duplex = 1;
-- status.speed = 100;
-- fixed_phy_add(PHY_POLL, phy_id, &status);
-+ mdio_bus_id = 0; /* fixed phys bus */
-+ phy_id = pdev->id;
- } else {
-- printk(KERN_ERR "cpmac: no PHY present\n");
-+ dev_err(&pdev->dev, "no PHY present\n");
- return -ENODEV;
- }
- }