diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2008-07-24 15:17:19 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-07-24 15:17:19 -0400 |
commit | 3fde80e94c2bbffbb13f5faa3340cf438440ebea (patch) | |
tree | 43eeac74dc34596772b9d9883e9208da8ae84184 /drivers/net | |
parent | ac9f80ad16e6e934b6c1f12f82d27889c0f9abcc (diff) | |
parent | 9b0e74102494971ca37a425c63031fea68bb5b79 (diff) |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/gerg/m68knommu
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/gerg/m68knommu:
m68knommu: put ColdFire head code into .text.head section
m68knommu: remove last use of CONFIG_FADS and CONFIG_RPXCLASSIC
m68knommu: remove RPXCLASSIC from the m68k tree
m68knommu: fec: remove FADS
m68knommu: MCF5307 PIT GENERIC_CLOCKEVENTS support
m68knommu: add read_barrier_depends() and irqs_disabled_flags()
m68knommu: add byteswap assembly opcode for ISA A+
m68knommu: add ffs and __ffs plattform which support ISA A+ or ISA C
m68knommu: add sched_clock() for the DMA timer
m68knommu: complete generic time
m68knommu: move code within time.c
m68knommu: m68knommu: add old stack trace method
m68knommu: Add Coldfire DMA Timer support
m68knommu: defconfig for M5407C3 board
m68knommu: defconfig for M5307C3 board
m68knommu: defconfig for M5275EVB board
m68knommu: defconfig for M5249EVB board
m68knommu: change to a configs directory for board configurations
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/fec.c | 54 |
1 files changed, 1 insertions, 53 deletions
diff --git a/drivers/net/fec.c b/drivers/net/fec.c index 32a4f17d35fc..ecd5c71a7a8a 100644 --- a/drivers/net/fec.c +++ b/drivers/net/fec.c | |||
@@ -2,12 +2,6 @@ | |||
2 | * Fast Ethernet Controller (FEC) driver for Motorola MPC8xx. | 2 | * Fast Ethernet Controller (FEC) driver for Motorola MPC8xx. |
3 | * Copyright (c) 1997 Dan Malek (dmalek@jlc.net) | 3 | * Copyright (c) 1997 Dan Malek (dmalek@jlc.net) |
4 | * | 4 | * |
5 | * This version of the driver is specific to the FADS implementation, | ||
6 | * since the board contains control registers external to the processor | ||
7 | * for the control of the LevelOne LXT970 transceiver. The MPC860T manual | ||
8 | * describes connections using the internal parallel port I/O, which | ||
9 | * is basically all of Port D. | ||
10 | * | ||
11 | * Right now, I am very wasteful with the buffers. I allocate memory | 5 | * Right now, I am very wasteful with the buffers. I allocate memory |
12 | * pages and then divide them into 2K frame buffers. This way I know I | 6 | * pages and then divide them into 2K frame buffers. This way I know I |
13 | * have buffers large enough to hold one frame within one buffer descriptor. | 7 | * have buffers large enough to hold one frame within one buffer descriptor. |
@@ -49,17 +43,9 @@ | |||
49 | #include <asm/pgtable.h> | 43 | #include <asm/pgtable.h> |
50 | #include <asm/cacheflush.h> | 44 | #include <asm/cacheflush.h> |
51 | 45 | ||
52 | #if defined(CONFIG_M523x) || defined(CONFIG_M527x) || \ | ||
53 | defined(CONFIG_M5272) || defined(CONFIG_M528x) || \ | ||
54 | defined(CONFIG_M520x) || defined(CONFIG_M532x) | ||
55 | #include <asm/coldfire.h> | 46 | #include <asm/coldfire.h> |
56 | #include <asm/mcfsim.h> | 47 | #include <asm/mcfsim.h> |
57 | #include "fec.h" | 48 | #include "fec.h" |
58 | #else | ||
59 | #include <asm/8xx_immap.h> | ||
60 | #include <asm/mpc8xx.h> | ||
61 | #include "commproc.h" | ||
62 | #endif | ||
63 | 49 | ||
64 | #if defined(CONFIG_FEC2) | 50 | #if defined(CONFIG_FEC2) |
65 | #define FEC_MAX_PORTS 2 | 51 | #define FEC_MAX_PORTS 2 |
@@ -67,7 +53,7 @@ | |||
67 | #define FEC_MAX_PORTS 1 | 53 | #define FEC_MAX_PORTS 1 |
68 | #endif | 54 | #endif |
69 | 55 | ||
70 | #if defined(CONFIG_FADS) || defined(CONFIG_RPXCLASSIC) || defined(CONFIG_M5272) | 56 | #if defined(CONFIG_M5272) |
71 | #define HAVE_mii_link_interrupt | 57 | #define HAVE_mii_link_interrupt |
72 | #endif | 58 | #endif |
73 | 59 | ||
@@ -1235,14 +1221,9 @@ static phy_info_t const * const phy_info[] = { | |||
1235 | 1221 | ||
1236 | /* ------------------------------------------------------------------------- */ | 1222 | /* ------------------------------------------------------------------------- */ |
1237 | #ifdef HAVE_mii_link_interrupt | 1223 | #ifdef HAVE_mii_link_interrupt |
1238 | #ifdef CONFIG_RPXCLASSIC | ||
1239 | static void | ||
1240 | mii_link_interrupt(void *dev_id); | ||
1241 | #else | ||
1242 | static irqreturn_t | 1224 | static irqreturn_t |
1243 | mii_link_interrupt(int irq, void * dev_id); | 1225 | mii_link_interrupt(int irq, void * dev_id); |
1244 | #endif | 1226 | #endif |
1245 | #endif | ||
1246 | 1227 | ||
1247 | #if defined(CONFIG_M5272) | 1228 | #if defined(CONFIG_M5272) |
1248 | /* | 1229 | /* |
@@ -1795,24 +1776,6 @@ static void __inline__ fec_request_intrs(struct net_device *dev) | |||
1795 | 1776 | ||
1796 | if (request_8xxirq(FEC_INTERRUPT, fec_enet_interrupt, 0, "fec", dev) != 0) | 1777 | if (request_8xxirq(FEC_INTERRUPT, fec_enet_interrupt, 0, "fec", dev) != 0) |
1797 | panic("Could not allocate FEC IRQ!"); | 1778 | panic("Could not allocate FEC IRQ!"); |
1798 | |||
1799 | #ifdef CONFIG_RPXCLASSIC | ||
1800 | /* Make Port C, bit 15 an input that causes interrupts. | ||
1801 | */ | ||
1802 | immap->im_ioport.iop_pcpar &= ~0x0001; | ||
1803 | immap->im_ioport.iop_pcdir &= ~0x0001; | ||
1804 | immap->im_ioport.iop_pcso &= ~0x0001; | ||
1805 | immap->im_ioport.iop_pcint |= 0x0001; | ||
1806 | cpm_install_handler(CPMVEC_PIO_PC15, mii_link_interrupt, dev); | ||
1807 | |||
1808 | /* Make LEDS reflect Link status. | ||
1809 | */ | ||
1810 | *((uint *) RPX_CSR_ADDR) &= ~BCSR2_FETHLEDMODE; | ||
1811 | #endif | ||
1812 | #ifdef CONFIG_FADS | ||
1813 | if (request_8xxirq(SIU_IRQ2, mii_link_interrupt, 0, "mii", dev) != 0) | ||
1814 | panic("Could not allocate MII IRQ!"); | ||
1815 | #endif | ||
1816 | } | 1779 | } |
1817 | 1780 | ||
1818 | static void __inline__ fec_get_mac(struct net_device *dev) | 1781 | static void __inline__ fec_get_mac(struct net_device *dev) |
@@ -1821,16 +1784,6 @@ static void __inline__ fec_get_mac(struct net_device *dev) | |||
1821 | 1784 | ||
1822 | bd = (bd_t *)__res; | 1785 | bd = (bd_t *)__res; |
1823 | memcpy(dev->dev_addr, bd->bi_enetaddr, ETH_ALEN); | 1786 | memcpy(dev->dev_addr, bd->bi_enetaddr, ETH_ALEN); |
1824 | |||
1825 | #ifdef CONFIG_RPXCLASSIC | ||
1826 | /* The Embedded Planet boards have only one MAC address in | ||
1827 | * the EEPROM, but can have two Ethernet ports. For the | ||
1828 | * FEC port, we create another address by setting one of | ||
1829 | * the address bits above something that would have (up to | ||
1830 | * now) been allocated. | ||
1831 | */ | ||
1832 | dev->dev_adrd[3] |= 0x80; | ||
1833 | #endif | ||
1834 | } | 1787 | } |
1835 | 1788 | ||
1836 | static void __inline__ fec_set_mii(struct net_device *dev, struct fec_enet_private *fep) | 1789 | static void __inline__ fec_set_mii(struct net_device *dev, struct fec_enet_private *fep) |
@@ -2109,13 +2062,8 @@ mii_discover_phy(uint mii_reg, struct net_device *dev) | |||
2109 | /* This interrupt occurs when the PHY detects a link change. | 2062 | /* This interrupt occurs when the PHY detects a link change. |
2110 | */ | 2063 | */ |
2111 | #ifdef HAVE_mii_link_interrupt | 2064 | #ifdef HAVE_mii_link_interrupt |
2112 | #ifdef CONFIG_RPXCLASSIC | ||
2113 | static void | ||
2114 | mii_link_interrupt(void *dev_id) | ||
2115 | #else | ||
2116 | static irqreturn_t | 2065 | static irqreturn_t |
2117 | mii_link_interrupt(int irq, void * dev_id) | 2066 | mii_link_interrupt(int irq, void * dev_id) |
2118 | #endif | ||
2119 | { | 2067 | { |
2120 | struct net_device *dev = dev_id; | 2068 | struct net_device *dev = dev_id; |
2121 | struct fec_enet_private *fep = netdev_priv(dev); | 2069 | struct fec_enet_private *fep = netdev_priv(dev); |