diff options
author | juhosg <juhosg@3c298f89-4303-0410-b956-a3cf2f4a3e73> | 2009-10-30 12:26:22 +0000 |
---|---|---|
committer | juhosg <juhosg@3c298f89-4303-0410-b956-a3cf2f4a3e73> | 2009-10-30 12:26:22 +0000 |
commit | 0724c81c225516ac88aeb5cd6b837b1fddca7bb1 (patch) | |
tree | 47098902642e409cdda14f08dfd6485238f6288b /target/linux/ar71xx/files/arch/mips | |
parent | 5be08769f35ba9a5c170eb7a1139f7778a2549a1 (diff) |
ar71xx: use soc specific divider for mdio clock
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@18225 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/ar71xx/files/arch/mips')
-rw-r--r-- | target/linux/ar71xx/files/arch/mips/ar71xx/devices.c | 8 | ||||
-rw-r--r-- | target/linux/ar71xx/files/arch/mips/include/asm/mach-ar71xx/platform.h | 1 |
2 files changed, 6 insertions, 3 deletions
diff --git a/target/linux/ar71xx/files/arch/mips/ar71xx/devices.c b/target/linux/ar71xx/files/arch/mips/ar71xx/devices.c index 7c08bc997f..d55022f88a 100644 --- a/target/linux/ar71xx/files/arch/mips/ar71xx/devices.c +++ b/target/linux/ar71xx/files/arch/mips/ar71xx/devices.c @@ -186,9 +186,7 @@ static struct resource ar71xx_mdio_resources[] = { } }; -static struct ag71xx_mdio_platform_data ar71xx_mdio_data = { - .phy_mask = 0xffffffff, -}; +static struct ag71xx_mdio_platform_data ar71xx_mdio_data; static struct platform_device ar71xx_mdio_device = { .name = "ag71xx-mdio", @@ -202,7 +200,11 @@ static struct platform_device ar71xx_mdio_device = { void __init ar71xx_add_device_mdio(u32 phy_mask) { + if (ar71xx_soc == AR71XX_SOC_AR7240) + ar71xx_mdio_data.is_ar7240 = 1; + ar71xx_mdio_data.phy_mask = phy_mask; + platform_device_register(&ar71xx_mdio_device); } diff --git a/target/linux/ar71xx/files/arch/mips/include/asm/mach-ar71xx/platform.h b/target/linux/ar71xx/files/arch/mips/include/asm/mach-ar71xx/platform.h index c305a821d0..52f41f47ad 100644 --- a/target/linux/ar71xx/files/arch/mips/include/asm/mach-ar71xx/platform.h +++ b/target/linux/ar71xx/files/arch/mips/include/asm/mach-ar71xx/platform.h @@ -37,6 +37,7 @@ struct ag71xx_platform_data { struct ag71xx_mdio_platform_data { u32 phy_mask; + int is_ar7240; }; struct ar71xx_ehci_platform_data { |