diff options
author | Florian Fainelli <florian@openwrt.org> | 2009-11-09 19:13:30 -0500 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2010-02-27 06:53:01 -0500 |
commit | 66f75ccb856304c190fde9c26e651c2b754e3e72 (patch) | |
tree | f63f8fe9362fc9805b73f9146a20457d1ceddff0 /arch/mips/alchemy/devboards | |
parent | cf6e47e03239059bcf2942b1b3242e835231ab75 (diff) |
MIPS: Alchemy: Add au1000-eth platform device
This patch makes the board code register the au1000-eth platform device. The
au1000-eth platform data can be overriden with the au1xxx_override_eth_cfg
function like it has to be done for the Bosporus board which uses a
different MAC/PHY setup.
Signed-off-by: Florian Fainelli <florian@openwrt.org>
Cc: David Miller <davem@davemloft.net>
Cc: linux-mips@linux-mips.org
Cc: netdev@vger.kernel.org
Patchwork: http://patchwork.linux-mips.org/patch/618/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch/mips/alchemy/devboards')
-rw-r--r-- | arch/mips/alchemy/devboards/db1x00/board_setup.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/arch/mips/alchemy/devboards/db1x00/board_setup.c b/arch/mips/alchemy/devboards/db1x00/board_setup.c index 7aee14d78eea..b490efff4dca 100644 --- a/arch/mips/alchemy/devboards/db1x00/board_setup.c +++ b/arch/mips/alchemy/devboards/db1x00/board_setup.c | |||
@@ -32,6 +32,7 @@ | |||
32 | #include <linux/interrupt.h> | 32 | #include <linux/interrupt.h> |
33 | 33 | ||
34 | #include <asm/mach-au1x00/au1000.h> | 34 | #include <asm/mach-au1x00/au1000.h> |
35 | #include <asm/mach-au1x00/au1xxx_eth.h> | ||
35 | #include <asm/mach-db1x00/db1x00.h> | 36 | #include <asm/mach-db1x00/db1x00.h> |
36 | #include <asm/mach-db1x00/bcsr.h> | 37 | #include <asm/mach-db1x00/bcsr.h> |
37 | 38 | ||
@@ -44,12 +45,26 @@ char irq_tab_alchemy[][5] __initdata = { | |||
44 | }; | 45 | }; |
45 | #endif | 46 | #endif |
46 | 47 | ||
48 | /* | ||
49 | * Micrel/Kendin 5 port switch attached to MAC0, | ||
50 | * MAC0 is associated with PHY address 5 (== WAN port) | ||
51 | * MAC1 is not associated with any PHY, since it's connected directly | ||
52 | * to the switch. | ||
53 | * no interrupts are used | ||
54 | */ | ||
55 | static struct au1000_eth_platform_data eth0_pdata = { | ||
56 | .phy_static_config = 1, | ||
57 | .phy_addr = 5, | ||
58 | }; | ||
59 | |||
47 | #ifdef CONFIG_MIPS_BOSPORUS | 60 | #ifdef CONFIG_MIPS_BOSPORUS |
48 | char irq_tab_alchemy[][5] __initdata = { | 61 | char irq_tab_alchemy[][5] __initdata = { |
49 | [11] = { -1, AU1500_PCI_INTA, AU1500_PCI_INTB, 0xff, 0xff }, /* IDSEL 11 - miniPCI */ | 62 | [11] = { -1, AU1500_PCI_INTA, AU1500_PCI_INTB, 0xff, 0xff }, /* IDSEL 11 - miniPCI */ |
50 | [12] = { -1, AU1500_PCI_INTA, 0xff, 0xff, 0xff }, /* IDSEL 12 - SN1741 */ | 63 | [12] = { -1, AU1500_PCI_INTA, 0xff, 0xff, 0xff }, /* IDSEL 12 - SN1741 */ |
51 | [13] = { -1, AU1500_PCI_INTA, AU1500_PCI_INTB, AU1500_PCI_INTC, AU1500_PCI_INTD }, /* IDSEL 13 - PCI slot */ | 64 | [13] = { -1, AU1500_PCI_INTA, AU1500_PCI_INTB, AU1500_PCI_INTC, AU1500_PCI_INTD }, /* IDSEL 13 - PCI slot */ |
52 | }; | 65 | }; |
66 | |||
67 | |||
53 | #endif | 68 | #endif |
54 | 69 | ||
55 | #ifdef CONFIG_MIPS_MIRAGE | 70 | #ifdef CONFIG_MIPS_MIRAGE |
@@ -103,6 +118,8 @@ void __init board_setup(void) | |||
103 | printk(KERN_INFO "AMD Alchemy Au1100/Db1100 Board\n"); | 118 | printk(KERN_INFO "AMD Alchemy Au1100/Db1100 Board\n"); |
104 | #endif | 119 | #endif |
105 | #ifdef CONFIG_MIPS_BOSPORUS | 120 | #ifdef CONFIG_MIPS_BOSPORUS |
121 | au1xxx_override_eth_cfg(0, ð0_pdata); | ||
122 | |||
106 | printk(KERN_INFO "AMD Alchemy Bosporus Board\n"); | 123 | printk(KERN_INFO "AMD Alchemy Bosporus Board\n"); |
107 | #endif | 124 | #endif |
108 | #ifdef CONFIG_MIPS_MIRAGE | 125 | #ifdef CONFIG_MIPS_MIRAGE |