diff options
author | Imre Kaloz <kaloz@openwrt.org> | 2008-07-12 02:02:58 +0000 |
---|---|---|
committer | Imre Kaloz <kaloz@openwrt.org> | 2008-07-12 02:02:58 +0000 |
commit | 75aa30ada882353a8477ac83a609d4012726c540 (patch) | |
tree | a9007f11ef59f23ec761997f6092a6f517aaa501 /target/linux/ixp4xx/patches-2.6.23/300-avila_fetch_mac.patch | |
parent | fc80a0718439b330f4405d9875e936e2c783f43c (diff) | |
download | mtk-20170518-75aa30ada882353a8477ac83a609d4012726c540.zip mtk-20170518-75aa30ada882353a8477ac83a609d4012726c540.tar.gz mtk-20170518-75aa30ada882353a8477ac83a609d4012726c540.tar.bz2 |
nuke most of the old ixp4xx patchsets
SVN-Revision: 11778
Diffstat (limited to 'target/linux/ixp4xx/patches-2.6.23/300-avila_fetch_mac.patch')
-rw-r--r-- | target/linux/ixp4xx/patches-2.6.23/300-avila_fetch_mac.patch | 72 |
1 files changed, 0 insertions, 72 deletions
diff --git a/target/linux/ixp4xx/patches-2.6.23/300-avila_fetch_mac.patch b/target/linux/ixp4xx/patches-2.6.23/300-avila_fetch_mac.patch deleted file mode 100644 index 7303399..0000000 --- a/target/linux/ixp4xx/patches-2.6.23/300-avila_fetch_mac.patch +++ /dev/null @@ -1,72 +0,0 @@ -Index: linux-2.6.23.17/arch/arm/mach-ixp4xx/avila-setup.c -=================================================================== ---- linux-2.6.23.17.orig/arch/arm/mach-ixp4xx/avila-setup.c -+++ linux-2.6.23.17/arch/arm/mach-ixp4xx/avila-setup.c -@@ -14,10 +14,18 @@ - #include <linux/kernel.h> - #include <linux/init.h> - #include <linux/device.h> -+#include <linux/if_ether.h> -+#include <linux/socket.h> -+#include <linux/netdevice.h> - #include <linux/serial.h> - #include <linux/tty.h> - #include <linux/serial_8250.h> - #include <linux/slab.h> -+#ifdef CONFIG_SENSORS_EEPROM -+# include <linux/i2c.h> -+# include <linux/eeprom.h> -+#endif -+ - #include <linux/i2c-gpio.h> - - #include <asm/types.h> -@@ -194,9 +202,48 @@ static void __init avila_fixup(struct ma - t->hdr.size = 0; - } - -+#ifdef CONFIG_SENSORS_EEPROM -+static int loft_eeprom_do(struct notifier_block *self, unsigned long event, void *t) -+{ -+ struct eeprom_data *data = t; -+ struct sockaddr address; -+ struct net_device * netdev ; -+ -+ char macs[12]; -+ -+ /* The MACs are the first 12 bytes in the eeprom at address 0x51 */ -+ if (event == EEPROM_REGISTER && data->client.addr == 0x51) { -+ data->attr->read(&data->client.dev.kobj, data->attr, macs, 0, 12); -+ /*eth0*/ -+ /* using dev_get_by_name here is really ugly and can cause -+ * confusion if other ethernet devices are present. FIXME */ -+ -+ memcpy(address.sa_data, macs, ETH_ALEN); -+ memcpy(&avila_plat_eth[0].hwaddr, macs, ETH_ALEN); -+ if ( (netdev = dev_get_by_name("eth0")) ) -+ netdev->set_mac_address(netdev, &address); -+ -+ /*same for eth1*/ -+ memcpy(address.sa_data, macs + ETH_ALEN, ETH_ALEN); -+ memcpy(&avila_plat_eth[1].hwaddr, macs + ETH_ALEN, ETH_ALEN); -+ if ( (netdev = dev_get_by_name("eth1")) ) -+ netdev->set_mac_address(netdev, &address); -+ } -+ -+ return NOTIFY_DONE; -+} -+ -+static struct notifier_block loft_eeprom_notifier = { -+ .notifier_call = loft_eeprom_do -+}; -+#endif -+ - static void __init avila_init(void) - { - ixp4xx_sys_init(); -+#ifdef CONFIG_SENSORS_EEPROM -+ register_eeprom_notifier(&loft_eeprom_notifier); -+#endif - - avila_flash_resource.start = IXP4XX_EXP_BUS_BASE(0); - avila_flash_resource.end = |