1
0
mirror of git://projects.qi-hardware.com/openwrt-xburst.git synced 2025-01-11 23:50:14 +02:00

backfire: atheros: register wmac device only if it is enabled in the board config (backport of r21038)

git-svn-id: svn://svn.openwrt.org/openwrt/branches/backfire@21040 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
juhosg 2010-04-20 13:28:41 +00:00
parent e9f57dab66
commit 8f9db15933
2 changed files with 10 additions and 6 deletions

View File

@ -1555,7 +1555,7 @@
+ +
--- /dev/null --- /dev/null
+++ b/arch/mips/ar231x/ar5312.c +++ b/arch/mips/ar231x/ar5312.c
@@ -0,0 +1,547 @@ @@ -0,0 +1,549 @@
+/* +/*
+ * This file is subject to the terms and conditions of the GNU General Public + * This file is subject to the terms and conditions of the GNU General Public
+ * License. See the file "COPYING" in the main directory of this archive + * License. See the file "COPYING" in the main directory of this archive
@ -1938,7 +1938,8 @@
+ if (!ar231x_board.radio) + if (!ar231x_board.radio)
+ return 0; + return 0;
+ +
+ if (*((u32 *) radio) & AR531X_RADIO0_MASK) + if ((*((u32 *) radio) & AR531X_RADIO0_MASK) &&
+ (config->flags & BD_WLAN0))
+ ar231x_add_wmac(0, AR531X_WLAN0, + ar231x_add_wmac(0, AR531X_WLAN0,
+ AR5312_IRQ_WLAN0_INTRS); + AR5312_IRQ_WLAN0_INTRS);
+ +
@ -1962,7 +1963,8 @@
+ break; + break;
+ } + }
+ +
+ if (*((u32 *) radio) & AR531X_RADIO1_MASK) + if ((*((u32 *) radio) & AR531X_RADIO1_MASK) &&
+ (config->flags & BD_WLAN1))
+ ar231x_add_wmac(1, AR531X_WLAN1, + ar231x_add_wmac(1, AR531X_WLAN1,
+ AR5312_IRQ_WLAN1_INTRS); + AR5312_IRQ_WLAN1_INTRS);
+ +

View File

@ -1557,7 +1557,7 @@
+ +
--- /dev/null --- /dev/null
+++ b/arch/mips/ar231x/ar5312.c +++ b/arch/mips/ar231x/ar5312.c
@@ -0,0 +1,547 @@ @@ -0,0 +1,549 @@
+/* +/*
+ * This file is subject to the terms and conditions of the GNU General Public + * This file is subject to the terms and conditions of the GNU General Public
+ * License. See the file "COPYING" in the main directory of this archive + * License. See the file "COPYING" in the main directory of this archive
@ -1940,7 +1940,8 @@
+ if (!ar231x_board.radio) + if (!ar231x_board.radio)
+ return 0; + return 0;
+ +
+ if (*((u32 *) radio) & AR531X_RADIO0_MASK) + if ((*((u32 *) radio) & AR531X_RADIO0_MASK) &&
+ (config->flags & BD_WLAN0))
+ ar231x_add_wmac(0, AR531X_WLAN0, + ar231x_add_wmac(0, AR531X_WLAN0,
+ AR5312_IRQ_WLAN0_INTRS); + AR5312_IRQ_WLAN0_INTRS);
+ +
@ -1964,7 +1965,8 @@
+ break; + break;
+ } + }
+ +
+ if (*((u32 *) radio) & AR531X_RADIO1_MASK) + if ((*((u32 *) radio) & AR531X_RADIO1_MASK) &&
+ (config->flags & BD_WLAN1))
+ ar231x_add_wmac(1, AR531X_WLAN1, + ar231x_add_wmac(1, AR531X_WLAN1,
+ AR5312_IRQ_WLAN1_INTRS); + AR5312_IRQ_WLAN1_INTRS);
+ +