diff options
Diffstat (limited to 'target/linux/ar71xx/files/arch/mips/ar71xx/platform.c')
-rw-r--r-- | target/linux/ar71xx/files/arch/mips/ar71xx/platform.c | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/target/linux/ar71xx/files/arch/mips/ar71xx/platform.c b/target/linux/ar71xx/files/arch/mips/ar71xx/platform.c index 705f24315a..e4e9538986 100644 --- a/target/linux/ar71xx/files/arch/mips/ar71xx/platform.c +++ b/target/linux/ar71xx/files/arch/mips/ar71xx/platform.c @@ -592,3 +592,27 @@ void __init ar71xx_parse_mac_addr(char *mac_str) printk(KERN_DEBUG "ar71xx: failed to parse mac address " "\"%s\"\n", mac_str); } + +static struct resource ar91xx_wmac_resources[] = { + { + .start = AR91XX_WMAC_BASE, + .end = AR91XX_WMAC_BASE + AR91XX_WMAC_SIZE - 1, + .flags = IORESOURCE_MEM, + }, { + .start = AR71XX_CPU_IRQ_WMAC, + .end = AR71XX_CPU_IRQ_WMAC, + .flags = IORESOURCE_IRQ, + }, +}; + +static struct platform_device ar91xx_wmac_device = { + .name = "ath9k", + .id = -1, + .resource = ar91xx_wmac_resources, + .num_resources = ARRAY_SIZE(ar91xx_wmac_resources), +}; + +void __init ar91xx_add_device_wmac(void) +{ + platform_device_register(&ar91xx_wmac_device); +} |