1
0
mirror of git://projects.qi-hardware.com/openwrt-xburst.git synced 2024-12-26 01:08:38 +02:00

refresh madwifi patches, fix an issue with napi polling (thx SeG)

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@10511 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
nbd 2008-02-20 21:26:21 +00:00
parent fee51108ff
commit bcb54b3924
27 changed files with 415 additions and 547 deletions

View File

@ -1,7 +1,7 @@
Index: madwifi-dfs-r3053/hal/public/mips-be-elf.inc Index: madwifi-trunk-r3314/hal/public/mips-be-elf.inc
=================================================================== ===================================================================
--- madwifi-dfs-r3053.orig/hal/public/mips-be-elf.inc 2007-12-13 05:25:10.890246068 +0100 --- madwifi-trunk-r3314.orig/hal/public/mips-be-elf.inc 2008-02-20 18:10:46.339155111 +0100
+++ madwifi-dfs-r3053/hal/public/mips-be-elf.inc 2007-12-13 05:25:10.986251538 +0100 +++ madwifi-trunk-r3314/hal/public/mips-be-elf.inc 2008-02-20 18:10:46.439160810 +0100
@@ -71,5 +71,5 @@ @@ -71,5 +71,5 @@
LDOPTS= -EB LDOPTS= -EB
@ -9,10 +9,10 @@ Index: madwifi-dfs-r3053/hal/public/mips-be-elf.inc
-COPTS+= -G 0 -EB -mno-abicalls -fno-pic -mips2 -Wa,--trap \ -COPTS+= -G 0 -EB -mno-abicalls -fno-pic -mips2 -Wa,--trap \
+COPTS+= -G 0 -mno-abicalls -fno-pic -mips32 -Wa,--trap \ +COPTS+= -G 0 -mno-abicalls -fno-pic -mips32 -Wa,--trap \
-fno-strict-aliasing -fno-common -fomit-frame-pointer -mlong-calls -fno-strict-aliasing -fno-common -fomit-frame-pointer -mlong-calls
Index: madwifi-dfs-r3053/hal/public/mips-le-elf.inc Index: madwifi-trunk-r3314/hal/public/mips-le-elf.inc
=================================================================== ===================================================================
--- madwifi-dfs-r3053.orig/hal/public/mips-le-elf.inc 2007-12-13 05:25:10.898246523 +0100 --- madwifi-trunk-r3314.orig/hal/public/mips-le-elf.inc 2008-02-20 18:10:46.347155567 +0100
+++ madwifi-dfs-r3053/hal/public/mips-le-elf.inc 2007-12-13 05:25:10.994251993 +0100 +++ madwifi-trunk-r3314/hal/public/mips-le-elf.inc 2008-02-20 18:10:46.443161036 +0100
@@ -68,5 +68,5 @@ @@ -68,5 +68,5 @@
LDOPTS= -EL LDOPTS= -EL
@ -20,10 +20,10 @@ Index: madwifi-dfs-r3053/hal/public/mips-le-elf.inc
-COPTS+= -G 0 -EL -mno-abicalls -fno-pic -mips2 -Wa,--trap \ -COPTS+= -G 0 -EL -mno-abicalls -fno-pic -mips2 -Wa,--trap \
+COPTS+= -G 0 -mno-abicalls -fno-pic -mips32 -Wa,--trap \ +COPTS+= -G 0 -mno-abicalls -fno-pic -mips32 -Wa,--trap \
-fno-strict-aliasing -fno-common -fomit-frame-pointer -mlong-calls -fno-strict-aliasing -fno-common -fomit-frame-pointer -mlong-calls
Index: madwifi-dfs-r3053/hal/public/xscale-be-elf.inc Index: madwifi-trunk-r3314/hal/public/xscale-be-elf.inc
=================================================================== ===================================================================
--- madwifi-dfs-r3053.orig/hal/public/xscale-be-elf.inc 2007-12-13 05:25:10.906246979 +0100 --- madwifi-trunk-r3314.orig/hal/public/xscale-be-elf.inc 2008-02-20 18:10:46.351155793 +0100
+++ madwifi-dfs-r3053/hal/public/xscale-be-elf.inc 2007-12-13 05:25:10.998252222 +0100 +++ madwifi-trunk-r3314/hal/public/xscale-be-elf.inc 2008-02-20 18:10:46.451161492 +0100
@@ -77,5 +77,5 @@ @@ -77,5 +77,5 @@
LDOPTS= -EB LDOPTS= -EB
@ -31,15 +31,13 @@ Index: madwifi-dfs-r3053/hal/public/xscale-be-elf.inc
-COPTS+= -march=armv4 -mbig-endian -fno-strict-aliasing -fno-common -mapcs-32 \ -COPTS+= -march=armv4 -mbig-endian -fno-strict-aliasing -fno-common -mapcs-32 \
+COPTS+= -march=armv5te -mbig-endian -fno-strict-aliasing -fno-common \ +COPTS+= -march=armv5te -mbig-endian -fno-strict-aliasing -fno-common \
-mtune=xscale -mshort-load-bytes -mtune=xscale -mshort-load-bytes
Index: madwifi-dfs-r3053/hal/public/xscale-le-elf.inc Index: madwifi-trunk-r3314/hal/public/xscale-le-elf.inc
=================================================================== ===================================================================
--- madwifi-dfs-r3053.orig/hal/public/xscale-le-elf.inc 2007-12-12 22:20:33.000000000 -0600 --- madwifi-trunk-r3314.orig/hal/public/xscale-le-elf.inc 2008-02-20 18:10:46.363156477 +0100
+++ madwifi-dfs-r3053/hal/public/xscale-le-elf.inc 2008-01-14 17:24:29.000000000 -0600 +++ madwifi-trunk-r3314/hal/public/xscale-le-elf.inc 2008-02-20 18:10:46.455161721 +0100
@@ -78,5 +78,5 @@ @@ -79,4 +79,4 @@
LDOPTS= -EL LDOPTS= -EL
COPTS+= -DAH_BYTE_ORDER=AH_LITTLE_ENDIAN COPTS+= -DAH_BYTE_ORDER=AH_LITTLE_ENDIAN
-COPTS+= -march=armv4 -mlittle-endian -fno-strict-aliasing -fno-common \ COPTS+= -march=armv4 -mlittle-endian -fno-strict-aliasing -fno-common \
- -mapcs-32 -mtune=xscale -mshort-load-bytes - -mapcs-32 -mtune=xscale -mshort-load-bytes
+COPTS+= -march=armv4 -mlittle-endian -fno-strict-aliasing -fno-common \
+ -mtune=xscale -mshort-load-bytes + -mtune=xscale -mshort-load-bytes

View File

@ -1,7 +1,7 @@
Index: madwifi-dfs-r3053/tools/80211debug.c Index: madwifi-trunk-r3314/tools/80211debug.c
=================================================================== ===================================================================
--- madwifi-dfs-r3053.orig/tools/80211debug.c 2007-12-13 05:25:10.786240140 +0100 --- madwifi-trunk-r3314.orig/tools/80211debug.c 2008-02-20 18:10:46.235149183 +0100
+++ madwifi-dfs-r3053/tools/80211debug.c 2007-12-13 05:25:11.226265215 +0100 +++ madwifi-trunk-r3314/tools/80211debug.c 2008-02-20 18:10:46.695175398 +0100
@@ -49,6 +49,10 @@ @@ -49,6 +49,10 @@
#include <getopt.h> #include <getopt.h>
#include <err.h> #include <err.h>
@ -33,10 +33,10 @@ Index: madwifi-dfs-r3053/tools/80211debug.c
const char *ifname = "ath0"; const char *ifname = "ath0";
const char *cp, *tp; const char *cp, *tp;
const char *sep; const char *sep;
Index: madwifi-dfs-r3053/tools/80211stats.c Index: madwifi-trunk-r3314/tools/80211stats.c
=================================================================== ===================================================================
--- madwifi-dfs-r3053.orig/tools/80211stats.c 2007-12-13 05:25:10.794240595 +0100 --- madwifi-trunk-r3314.orig/tools/80211stats.c 2008-02-20 18:10:46.243149638 +0100
+++ madwifi-dfs-r3053/tools/80211stats.c 2007-12-13 05:25:11.226265215 +0100 +++ madwifi-trunk-r3314/tools/80211stats.c 2008-02-20 18:10:46.695175398 +0100
@@ -60,6 +60,10 @@ @@ -60,6 +60,10 @@
#include "net80211/ieee80211_crypto.h" #include "net80211/ieee80211_crypto.h"
#include "net80211/ieee80211_ioctl.h" #include "net80211/ieee80211_ioctl.h"
@ -68,10 +68,10 @@ Index: madwifi-dfs-r3053/tools/80211stats.c
int c, len; int c, len;
struct ieee80211req_sta_info *si; struct ieee80211req_sta_info *si;
u_int8_t buf[24*1024], *cp; u_int8_t buf[24*1024], *cp;
Index: madwifi-dfs-r3053/tools/athchans.c Index: madwifi-trunk-r3314/tools/athchans.c
=================================================================== ===================================================================
--- madwifi-dfs-r3053.orig/tools/athchans.c 2007-12-13 05:25:10.798240825 +0100 --- madwifi-trunk-r3314.orig/tools/athchans.c 2008-02-20 18:10:46.247149868 +0100
+++ madwifi-dfs-r3053/tools/athchans.c 2007-12-13 05:25:11.238265900 +0100 +++ madwifi-trunk-r3314/tools/athchans.c 2008-02-20 18:10:46.703175854 +0100
@@ -59,6 +59,10 @@ @@ -59,6 +59,10 @@
#include "net80211/ieee80211_crypto.h" #include "net80211/ieee80211_crypto.h"
#include "net80211/ieee80211_ioctl.h" #include "net80211/ieee80211_ioctl.h"
@ -83,7 +83,7 @@ Index: madwifi-dfs-r3053/tools/athchans.c
static int s = -1; static int s = -1;
static const char *progname; static const char *progname;
@@ -139,9 +143,20 @@ @@ -140,9 +144,20 @@
} }
#define MAXCHAN ((int)(sizeof(struct ieee80211req_chanlist) * NBBY)) #define MAXCHAN ((int)(sizeof(struct ieee80211req_chanlist) * NBBY))
@ -104,10 +104,10 @@ Index: madwifi-dfs-r3053/tools/athchans.c
const char *ifname = "wifi0"; const char *ifname = "wifi0";
struct ieee80211req_chanlist chanlist; struct ieee80211req_chanlist chanlist;
int c; int c;
Index: madwifi-dfs-r3053/tools/athctrl.c Index: madwifi-trunk-r3314/tools/athctrl.c
=================================================================== ===================================================================
--- madwifi-dfs-r3053.orig/tools/athctrl.c 2007-12-13 05:25:10.806241280 +0100 --- madwifi-trunk-r3314.orig/tools/athctrl.c 2008-02-20 18:10:46.255150323 +0100
+++ madwifi-dfs-r3053/tools/athctrl.c 2007-12-13 05:25:11.242266126 +0100 +++ madwifi-trunk-r3314/tools/athctrl.c 2008-02-20 18:10:46.707176083 +0100
@@ -53,6 +53,10 @@ @@ -53,6 +53,10 @@
#include <net/if.h> #include <net/if.h>
@ -139,10 +139,10 @@ Index: madwifi-dfs-r3053/tools/athctrl.c
char device[IFNAMSIZ + 1]; char device[IFNAMSIZ + 1];
int distance = -1; int distance = -1;
int c; int c;
Index: madwifi-dfs-r3053/tools/athdebug.c Index: madwifi-trunk-r3314/tools/athdebug.c
=================================================================== ===================================================================
--- madwifi-dfs-r3053.orig/tools/athdebug.c 2007-12-13 05:25:10.814241735 +0100 --- madwifi-trunk-r3314.orig/tools/athdebug.c 2008-02-20 18:10:46.263150778 +0100
+++ madwifi-dfs-r3053/tools/athdebug.c 2007-12-13 05:25:11.242266126 +0100 +++ madwifi-trunk-r3314/tools/athdebug.c 2008-02-20 18:10:46.711176309 +0100
@@ -52,6 +52,10 @@ @@ -52,6 +52,10 @@
#include <getopt.h> #include <getopt.h>
#include <err.h> #include <err.h>
@ -175,10 +175,10 @@ Index: madwifi-dfs-r3053/tools/athdebug.c
#ifdef __linux__ #ifdef __linux__
const char *ifname = "wifi0"; const char *ifname = "wifi0";
#else #else
Index: madwifi-dfs-r3053/tools/athkey.c Index: madwifi-trunk-r3314/tools/athkey.c
=================================================================== ===================================================================
--- madwifi-dfs-r3053.orig/tools/athkey.c 2007-12-13 05:25:10.818241964 +0100 --- madwifi-trunk-r3314.orig/tools/athkey.c 2008-02-20 18:10:46.271151234 +0100
+++ madwifi-dfs-r3053/tools/athkey.c 2007-12-13 05:25:11.242266126 +0100 +++ madwifi-trunk-r3314/tools/athkey.c 2008-02-20 18:10:46.711176309 +0100
@@ -59,6 +59,10 @@ @@ -59,6 +59,10 @@
#include "net80211/ieee80211_crypto.h" #include "net80211/ieee80211_crypto.h"
#include "net80211/ieee80211_ioctl.h" #include "net80211/ieee80211_ioctl.h"
@ -190,7 +190,7 @@ Index: madwifi-dfs-r3053/tools/athkey.c
static int s = -1; static int s = -1;
static const char *progname; static const char *progname;
@@ -212,9 +216,19 @@ @@ -213,9 +217,19 @@
exit(-1); exit(-1);
} }
@ -210,10 +210,10 @@ Index: madwifi-dfs-r3053/tools/athkey.c
const char *ifname = "wifi0"; const char *ifname = "wifi0";
struct ieee80211req_key setkey; struct ieee80211req_key setkey;
struct ieee80211req_del_key delkey; struct ieee80211req_del_key delkey;
Index: madwifi-dfs-r3053/tools/athstats.c Index: madwifi-trunk-r3314/tools/athstats.c
=================================================================== ===================================================================
--- madwifi-dfs-r3053.orig/tools/athstats.c 2007-12-13 05:25:10.826242419 +0100 --- madwifi-trunk-r3314.orig/tools/athstats.c 2008-02-20 18:10:46.275151463 +0100
+++ madwifi-dfs-r3053/tools/athstats.c 2007-12-13 05:25:11.242266126 +0100 +++ madwifi-trunk-r3314/tools/athstats.c 2008-02-20 18:10:46.711176309 +0100
@@ -66,6 +66,10 @@ @@ -66,6 +66,10 @@
#undef ARRAY_SIZE #undef ARRAY_SIZE
#define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0])) #define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0]))
@ -246,10 +246,10 @@ Index: madwifi-dfs-r3053/tools/athstats.c
#ifdef __linux__ #ifdef __linux__
const char *ifname = "wifi0"; const char *ifname = "wifi0";
#else #else
Index: madwifi-dfs-r3053/tools/do_multi.c Index: madwifi-trunk-r3314/tools/do_multi.c
=================================================================== ===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000 --- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ madwifi-dfs-r3053/tools/do_multi.c 2007-12-13 05:25:11.242266126 +0100 +++ madwifi-trunk-r3314/tools/do_multi.c 2008-02-20 18:10:46.711176309 +0100
@@ -0,0 +1,32 @@ @@ -0,0 +1,32 @@
+#include <string.h> +#include <string.h>
+#include "do_multi.h" +#include "do_multi.h"
@ -283,10 +283,10 @@ Index: madwifi-dfs-r3053/tools/do_multi.c
+ +
+ return ret; + return ret;
+} +}
Index: madwifi-dfs-r3053/tools/do_multi.h Index: madwifi-trunk-r3314/tools/do_multi.h
=================================================================== ===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000 --- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ madwifi-dfs-r3053/tools/do_multi.h 2007-12-13 05:25:11.246266355 +0100 +++ madwifi-trunk-r3314/tools/do_multi.h 2008-02-20 18:10:46.711176309 +0100
@@ -0,0 +1,10 @@ @@ -0,0 +1,10 @@
+ +
+int a80211debug_init(int argc, char *argv[]); +int a80211debug_init(int argc, char *argv[]);
@ -298,10 +298,10 @@ Index: madwifi-dfs-r3053/tools/do_multi.h
+int athstats_init(int argc, char *argv[]); +int athstats_init(int argc, char *argv[]);
+int wlanconfig_init(int argc, char *argv[]); +int wlanconfig_init(int argc, char *argv[]);
+int athinfo_init(int argc, char *argv[]); +int athinfo_init(int argc, char *argv[]);
Index: madwifi-dfs-r3053/tools/Makefile Index: madwifi-trunk-r3314/tools/Makefile
=================================================================== ===================================================================
--- madwifi-dfs-r3053.orig/tools/Makefile 2007-12-13 05:25:10.842243330 +0100 --- madwifi-trunk-r3314.orig/tools/Makefile 2008-02-20 18:10:46.295152602 +0100
+++ madwifi-dfs-r3053/tools/Makefile 2007-12-13 05:25:11.246266355 +0100 +++ madwifi-trunk-r3314/tools/Makefile 2008-02-20 18:10:46.715176538 +0100
@@ -47,9 +47,12 @@ @@ -47,9 +47,12 @@
endif endif
@ -367,10 +367,10 @@ Index: madwifi-dfs-r3053/tools/Makefile
install: $(ALL) install: $(ALL)
install -d $(DESTDIR)$(BINDIR) install -d $(DESTDIR)$(BINDIR)
Index: madwifi-dfs-r3053/tools/wlanconfig.c Index: madwifi-trunk-r3314/tools/wlanconfig.c
=================================================================== ===================================================================
--- madwifi-dfs-r3053.orig/tools/wlanconfig.c 2007-12-13 05:25:10.850243788 +0100 --- madwifi-trunk-r3314.orig/tools/wlanconfig.c 2008-02-20 18:10:46.299152832 +0100
+++ madwifi-dfs-r3053/tools/wlanconfig.c 2007-12-13 05:25:11.246266355 +0100 +++ madwifi-trunk-r3314/tools/wlanconfig.c 2008-02-20 18:10:46.715176538 +0100
@@ -62,6 +62,10 @@ @@ -62,6 +62,10 @@
#include "net80211/ieee80211_crypto.h" #include "net80211/ieee80211_crypto.h"
#include "net80211/ieee80211_ioctl.h" #include "net80211/ieee80211_ioctl.h"
@ -402,10 +402,10 @@ Index: madwifi-dfs-r3053/tools/wlanconfig.c
const char *ifname, *cmd; const char *ifname, *cmd;
unsigned char bnounit = 0; unsigned char bnounit = 0;
char *if_base = NULL; char *if_base = NULL;
Index: madwifi-dfs-r3053/tools/ath_info.c Index: madwifi-trunk-r3314/tools/ath_info.c
=================================================================== ===================================================================
--- madwifi-dfs-r3053.orig/tools/ath_info.c 2007-12-13 05:25:10.858244244 +0100 --- madwifi-trunk-r3314.orig/tools/ath_info.c 2008-02-20 18:10:46.311153513 +0100
+++ madwifi-dfs-r3053/tools/ath_info.c 2007-12-13 05:25:11.246266355 +0100 +++ madwifi-trunk-r3314/tools/ath_info.c 2008-02-20 18:10:46.715176538 +0100
@@ -738,7 +738,12 @@ @@ -738,7 +738,12 @@
"unlawful radio transmissions!\n\n"); "unlawful radio transmissions!\n\n");
} }

View File

@ -1,8 +1,8 @@
Index: madwifi-dfs-r3053/ath/if_ath.c Index: madwifi-trunk-r3314/ath/if_ath.c
=================================================================== ===================================================================
--- madwifi-dfs-r3053.orig/ath/if_ath.c 2007-12-13 05:25:10.754238316 +0100 --- madwifi-trunk-r3314.orig/ath/if_ath.c 2008-02-20 18:10:46.203147359 +0100
+++ madwifi-dfs-r3053/ath/if_ath.c 2007-12-13 05:25:11.582285503 +0100 +++ madwifi-trunk-r3314/ath/if_ath.c 2008-02-20 18:10:47.047195460 +0100
@@ -512,7 +512,7 @@ @@ -516,7 +516,7 @@
HAL_STATUS status; HAL_STATUS status;
int error = 0; int error = 0;
unsigned int i; unsigned int i;

View File

@ -1,7 +1,7 @@
Index: madwifi-dfs-r3053/net80211/ieee80211_rate.c Index: madwifi-trunk-r3314/net80211/ieee80211_rate.c
=================================================================== ===================================================================
--- madwifi-dfs-r3053.orig/net80211/ieee80211_rate.c 2007-12-13 05:25:10.722236492 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_rate.c 2008-02-20 18:10:46.171145535 +0100
+++ madwifi-dfs-r3053/net80211/ieee80211_rate.c 2007-12-13 05:25:11.798297814 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_rate.c 2008-02-20 18:10:47.259207542 +0100
@@ -100,8 +100,18 @@ @@ -100,8 +100,18 @@
ieee80211_load_module(buf); ieee80211_load_module(buf);

View File

@ -1,7 +1,7 @@
Index: madwifi-dfs-r3053/ath_rate/minstrel/minstrel.c Index: madwifi-trunk-r3314/ath_rate/minstrel/minstrel.c
=================================================================== ===================================================================
--- madwifi-dfs-r3053.orig/ath_rate/minstrel/minstrel.c 2007-12-13 05:25:10.690234670 +0100 --- madwifi-trunk-r3314.orig/ath_rate/minstrel/minstrel.c 2008-02-20 18:10:46.143143939 +0100
+++ madwifi-dfs-r3053/ath_rate/minstrel/minstrel.c 2007-12-13 05:25:12.006309667 +0100 +++ madwifi-trunk-r3314/ath_rate/minstrel/minstrel.c 2008-02-20 18:10:47.471219622 +0100
@@ -393,6 +393,9 @@ @@ -393,6 +393,9 @@
struct minstrel_node *sn = ATH_NODE_MINSTREL(an); struct minstrel_node *sn = ATH_NODE_MINSTREL(an);
int rc1, rc2, rc3; /* Index into the rate table, so for example, it is 0..11 */ int rc1, rc2, rc3; /* Index into the rate table, so for example, it is 0..11 */

View File

@ -1,7 +1,7 @@
Index: madwifi-dfs-r3053/net80211/ieee80211_scan.c Index: madwifi-trunk-r3314/net80211/ieee80211_scan.c
=================================================================== ===================================================================
--- madwifi-dfs-r3053.orig/net80211/ieee80211_scan.c 2007-12-13 05:25:10.658232846 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_scan.c 2008-02-20 18:10:46.107141889 +0100
+++ madwifi-dfs-r3053/net80211/ieee80211_scan.c 2007-12-13 05:25:12.214321521 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_scan.c 2008-02-20 18:10:47.679231478 +0100
@@ -291,7 +291,8 @@ @@ -291,7 +291,8 @@
struct ieee80211com *ic = vap->iv_ic; struct ieee80211com *ic = vap->iv_ic;
int delay; int delay;

View File

@ -1,14 +1,14 @@
Index: madwifi-dfs-r3053/net80211/ieee80211_linux.c Index: madwifi-trunk-r3314/net80211/ieee80211_linux.c
=================================================================== ===================================================================
--- madwifi-dfs-r3053.orig/net80211/ieee80211_linux.c 2007-12-13 05:25:10.626231021 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_linux.c 2008-02-20 18:10:46.075140065 +0100
+++ madwifi-dfs-r3053/net80211/ieee80211_linux.c 2007-12-13 05:25:12.422333377 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_linux.c 2008-02-20 18:10:47.887243331 +0100
@@ -331,6 +331,9 @@ @@ -331,6 +331,9 @@
k->wk_cipher->ic_name, k->wk_keyix, k->wk_cipher->ic_name, k->wk_keyix,
(unsigned long long)rsc ); (unsigned long long)rsc);
+ /* disabled for now due to bogus events for unknown reasons */ + /* disabled for now due to bogus events for unknown reasons */
+ return; + return;
+ +
/* TODO: needed parameters: count, keyid, key type, src address, TSC */ /* TODO: needed parameters: count, keyid, key type, src address, TSC */
snprintf(buf, sizeof(buf), "%s(keyid=%d %scast addr=%s)", tag, snprintf(buf, sizeof(buf), "%s(keyid=%d %scast addr=" MAC_FMT ")", tag,
k->wk_keyix, k->wk_keyix,

View File

@ -1,7 +1,7 @@
Index: madwifi-dfs-r3053/net80211/ieee80211_crypto_ccmp.c Index: madwifi-trunk-r3314/net80211/ieee80211_crypto_ccmp.c
=================================================================== ===================================================================
--- madwifi-dfs-r3053.orig/net80211/ieee80211_crypto_ccmp.c 2007-12-13 05:25:10.594229197 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_crypto_ccmp.c 2008-02-20 18:10:46.043138240 +0100
+++ madwifi-dfs-r3053/net80211/ieee80211_crypto_ccmp.c 2007-12-13 05:25:12.634345457 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_crypto_ccmp.c 2008-02-20 18:10:48.095255184 +0100
@@ -475,6 +475,9 @@ @@ -475,6 +475,9 @@
uint8_t *mic, *pos; uint8_t *mic, *pos;
u_int space; u_int space;

View File

@ -1,7 +1,7 @@
Index: madwifi-trunk-r3314/ath/if_athvar.h Index: madwifi-trunk-r3314/ath/if_athvar.h
=================================================================== ===================================================================
--- madwifi-trunk-r3314.orig/ath/if_athvar.h 2008-01-31 03:29:54.077194330 +0100 --- madwifi-trunk-r3314.orig/ath/if_athvar.h 2008-02-20 18:10:45.991135277 +0100
+++ madwifi-trunk-r3314/ath/if_athvar.h 2008-01-31 03:31:07.693389480 +0100 +++ madwifi-trunk-r3314/ath/if_athvar.h 2008-02-20 18:10:48.307267266 +0100
@@ -126,6 +126,11 @@ @@ -126,6 +126,11 @@
#define ATH_GET_NETDEV_DEV(ndev) ((ndev)->class_dev.dev) #define ATH_GET_NETDEV_DEV(ndev) ((ndev)->class_dev.dev)
#endif #endif
@ -16,8 +16,8 @@ Index: madwifi-trunk-r3314/ath/if_athvar.h
void (*setup)(struct net_device *)) void (*setup)(struct net_device *))
Index: madwifi-trunk-r3314/ath/if_ath_radar.c Index: madwifi-trunk-r3314/ath/if_ath_radar.c
=================================================================== ===================================================================
--- madwifi-trunk-r3314.orig/ath/if_ath_radar.c 2008-01-31 03:29:54.081194559 +0100 --- madwifi-trunk-r3314.orig/ath/if_ath_radar.c 2008-02-20 18:10:45.999135735 +0100
+++ madwifi-trunk-r3314/ath/if_ath_radar.c 2008-01-31 03:31:07.697389706 +0100 +++ madwifi-trunk-r3314/ath/if_ath_radar.c 2008-02-20 18:10:48.307267266 +0100
@@ -92,6 +92,13 @@ @@ -92,6 +92,13 @@
#define nofloat_pct(_value, _pct) \ #define nofloat_pct(_value, _pct) \
( (_value * (1000 + _pct)) / 1000 ) ( (_value * (1000 + _pct)) / 1000 )
@ -34,8 +34,8 @@ Index: madwifi-trunk-r3314/ath/if_ath_radar.c
const char *name; const char *name;
Index: madwifi-trunk-r3314/ath/if_ath.c Index: madwifi-trunk-r3314/ath/if_ath.c
=================================================================== ===================================================================
--- madwifi-trunk-r3314.orig/ath/if_ath.c 2008-01-31 03:30:19.778658973 +0100 --- madwifi-trunk-r3314.orig/ath/if_ath.c 2008-02-20 18:10:47.047195460 +0100
+++ madwifi-trunk-r3314/ath/if_ath.c 2008-01-31 03:31:07.709390390 +0100 +++ madwifi-trunk-r3314/ath/if_ath.c 2008-02-20 18:10:48.315267722 +0100
@@ -4705,6 +4705,46 @@ @@ -4705,6 +4705,46 @@
#undef USE_SHPREAMBLE #undef USE_SHPREAMBLE
} }
@ -86,7 +86,7 @@ Index: madwifi-trunk-r3314/ath/if_ath.c
Index: madwifi-trunk-r3314/net80211/sort.c Index: madwifi-trunk-r3314/net80211/sort.c
=================================================================== ===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000 --- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ madwifi-trunk-r3314/net80211/sort.c 2008-01-31 03:31:07.717390845 +0100 +++ madwifi-trunk-r3314/net80211/sort.c 2008-02-20 18:10:48.319267951 +0100
@@ -0,0 +1,120 @@ @@ -0,0 +1,120 @@
+/* +/*
+ * A fast, small, non-recursive O(nlog n) sort for the Linux kernel + * A fast, small, non-recursive O(nlog n) sort for the Linux kernel

View File

@ -1,8 +1,8 @@
Index: madwifi-dfs-r3053/ath/if_ath.c Index: madwifi-trunk-r3314/ath/if_ath.c
=================================================================== ===================================================================
--- madwifi-dfs-r3053.orig/ath/if_ath.c 2007-12-13 05:25:12.854357994 +0100 --- madwifi-trunk-r3314.orig/ath/if_ath.c 2008-02-20 18:10:48.315267722 +0100
+++ madwifi-dfs-r3053/ath/if_ath.c 2007-12-13 05:25:13.122373270 +0100 +++ madwifi-trunk-r3314/ath/if_ath.c 2008-02-20 18:10:48.567282084 +0100
@@ -6410,8 +6410,9 @@ @@ -6474,8 +6474,9 @@
/* /*
* Reject error frames if we have no vaps that * Reject error frames if we have no vaps that
* are operating in monitor mode. * are operating in monitor mode.

View File

@ -1,7 +1,7 @@
Index: madwifi-trunk-r3314/ath/if_ath.c Index: madwifi-trunk-r3314/ath/if_ath.c
=================================================================== ===================================================================
--- madwifi-trunk-r3314.orig/ath/if_ath.c 2008-02-20 17:49:12.301561550 +0100 --- madwifi-trunk-r3314.orig/ath/if_ath.c 2008-02-20 18:10:48.567282084 +0100
+++ madwifi-trunk-r3314/ath/if_ath.c 2008-02-20 17:49:12.321562687 +0100 +++ madwifi-trunk-r3314/ath/if_ath.c 2008-02-20 18:10:48.783294393 +0100
@@ -42,7 +42,6 @@ @@ -42,7 +42,6 @@
* This software is derived from work of Atsushi Onoe; his contribution * This software is derived from work of Atsushi Onoe; his contribution
* is greatly appreciated. * is greatly appreciated.
@ -63,8 +63,8 @@ Index: madwifi-trunk-r3314/ath/if_ath.c
} }
Index: madwifi-trunk-r3314/ath_rate/amrr/amrr.c Index: madwifi-trunk-r3314/ath_rate/amrr/amrr.c
=================================================================== ===================================================================
--- madwifi-trunk-r3314.orig/ath_rate/amrr/amrr.c 2008-02-20 17:49:02.913026521 +0100 --- madwifi-trunk-r3314.orig/ath_rate/amrr/amrr.c 2008-02-20 18:10:45.875128667 +0100
+++ madwifi-trunk-r3314/ath_rate/amrr/amrr.c 2008-02-20 17:49:12.321562687 +0100 +++ madwifi-trunk-r3314/ath_rate/amrr/amrr.c 2008-02-20 18:10:48.787294621 +0100
@@ -70,7 +70,9 @@ @@ -70,7 +70,9 @@
#include "amrr.h" #include "amrr.h"
@ -77,8 +77,8 @@ Index: madwifi-trunk-r3314/ath_rate/amrr/amrr.c
if (sc->sc_debug & 0x10) \ if (sc->sc_debug & 0x10) \
Index: madwifi-trunk-r3314/ath_rate/minstrel/minstrel.c Index: madwifi-trunk-r3314/ath_rate/minstrel/minstrel.c
=================================================================== ===================================================================
--- madwifi-trunk-r3314.orig/ath_rate/minstrel/minstrel.c 2008-02-20 17:49:12.229557442 +0100 --- madwifi-trunk-r3314.orig/ath_rate/minstrel/minstrel.c 2008-02-20 18:10:47.471219622 +0100
+++ madwifi-trunk-r3314/ath_rate/minstrel/minstrel.c 2008-02-20 17:49:12.329563147 +0100 +++ madwifi-trunk-r3314/ath_rate/minstrel/minstrel.c 2008-02-20 18:10:48.795295077 +0100
@@ -117,7 +117,9 @@ @@ -117,7 +117,9 @@
#include "minstrel.h" #include "minstrel.h"
@ -91,8 +91,8 @@ Index: madwifi-trunk-r3314/ath_rate/minstrel/minstrel.c
ATH_DEBUG_RATE = 0x00000010 /* rate control */ ATH_DEBUG_RATE = 0x00000010 /* rate control */
Index: madwifi-trunk-r3314/ath_rate/onoe/onoe.c Index: madwifi-trunk-r3314/ath_rate/onoe/onoe.c
=================================================================== ===================================================================
--- madwifi-trunk-r3314.orig/ath_rate/onoe/onoe.c 2008-02-20 17:49:02.929027436 +0100 --- madwifi-trunk-r3314.orig/ath_rate/onoe/onoe.c 2008-02-20 18:10:45.891129578 +0100
+++ madwifi-trunk-r3314/ath_rate/onoe/onoe.c 2008-02-20 17:49:12.333563371 +0100 +++ madwifi-trunk-r3314/ath_rate/onoe/onoe.c 2008-02-20 18:10:48.799295306 +0100
@@ -66,7 +66,9 @@ @@ -66,7 +66,9 @@
#include "onoe.h" #include "onoe.h"
@ -105,8 +105,8 @@ Index: madwifi-trunk-r3314/ath_rate/onoe/onoe.c
ATH_DEBUG_RATE = 0x00000010, /* rate control */ ATH_DEBUG_RATE = 0x00000010, /* rate control */
Index: madwifi-trunk-r3314/ath_rate/sample/sample.c Index: madwifi-trunk-r3314/ath_rate/sample/sample.c
=================================================================== ===================================================================
--- madwifi-trunk-r3314.orig/ath_rate/sample/sample.c 2008-02-20 17:49:02.937027889 +0100 --- madwifi-trunk-r3314.orig/ath_rate/sample/sample.c 2008-02-20 18:10:45.899130036 +0100
+++ madwifi-trunk-r3314/ath_rate/sample/sample.c 2008-02-20 17:49:12.333563371 +0100 +++ madwifi-trunk-r3314/ath_rate/sample/sample.c 2008-02-20 18:10:48.803295532 +0100
@@ -68,7 +68,9 @@ @@ -68,7 +68,9 @@
#include "sample.h" #include "sample.h"
@ -120,8 +120,8 @@ Index: madwifi-trunk-r3314/ath_rate/sample/sample.c
ATH_DEBUG_RATE = 0x00000010, /* rate control */ ATH_DEBUG_RATE = 0x00000010, /* rate control */
Index: madwifi-trunk-r3314/tools/do_multi.c Index: madwifi-trunk-r3314/tools/do_multi.c
=================================================================== ===================================================================
--- madwifi-trunk-r3314.orig/tools/do_multi.c 2008-02-20 17:49:12.181554711 +0100 --- madwifi-trunk-r3314.orig/tools/do_multi.c 2008-02-20 18:10:46.711176309 +0100
+++ madwifi-trunk-r3314/tools/do_multi.c 2008-02-20 17:49:12.333563371 +0100 +++ madwifi-trunk-r3314/tools/do_multi.c 2008-02-20 18:10:48.807295761 +0100
@@ -9,16 +9,20 @@ @@ -9,16 +9,20 @@
progname = basename(argv[0]); progname = basename(argv[0]);
@ -145,8 +145,8 @@ Index: madwifi-trunk-r3314/tools/do_multi.c
if(strcmp(progname, "athstats") == 0) if(strcmp(progname, "athstats") == 0)
Index: madwifi-trunk-r3314/tools/Makefile Index: madwifi-trunk-r3314/tools/Makefile
=================================================================== ===================================================================
--- madwifi-trunk-r3314.orig/tools/Makefile 2008-02-20 17:49:12.181554711 +0100 --- madwifi-trunk-r3314.orig/tools/Makefile 2008-02-20 18:10:46.715176538 +0100
+++ madwifi-trunk-r3314/tools/Makefile 2008-02-20 17:49:12.333563371 +0100 +++ madwifi-trunk-r3314/tools/Makefile 2008-02-20 18:10:48.807295761 +0100
@@ -46,9 +46,10 @@ @@ -46,9 +46,10 @@
HAL= $(TOP)/hal HAL= $(TOP)/hal
endif endif
@ -179,8 +179,8 @@ Index: madwifi-trunk-r3314/tools/Makefile
Index: madwifi-trunk-r3314/net80211/ieee80211_linux.h Index: madwifi-trunk-r3314/net80211/ieee80211_linux.h
=================================================================== ===================================================================
--- madwifi-trunk-r3314.orig/net80211/ieee80211_linux.h 2008-02-20 17:49:02.961029258 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_linux.h 2008-02-20 18:10:45.919131175 +0100
+++ madwifi-trunk-r3314/net80211/ieee80211_linux.h 2008-02-20 17:49:12.337563594 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_linux.h 2008-02-20 18:10:48.807295761 +0100
@@ -29,8 +29,6 @@ @@ -29,8 +29,6 @@
#ifndef _NET80211_IEEE80211_LINUX_H_ #ifndef _NET80211_IEEE80211_LINUX_H_
#define _NET80211_IEEE80211_LINUX_H_ #define _NET80211_IEEE80211_LINUX_H_
@ -192,8 +192,8 @@ Index: madwifi-trunk-r3314/net80211/ieee80211_linux.h
#include <linux/wireless.h> #include <linux/wireless.h>
Index: madwifi-trunk-r3314/Makefile.inc Index: madwifi-trunk-r3314/Makefile.inc
=================================================================== ===================================================================
--- madwifi-trunk-r3314.orig/Makefile.inc 2008-02-20 17:49:02.969029715 +0100 --- madwifi-trunk-r3314.orig/Makefile.inc 2008-02-20 18:10:45.927131631 +0100
+++ madwifi-trunk-r3314/Makefile.inc 2008-02-20 17:49:12.337563594 +0100 +++ madwifi-trunk-r3314/Makefile.inc 2008-02-20 18:10:48.807295761 +0100
@@ -148,7 +148,8 @@ @@ -148,7 +148,8 @@
TOOLS= $(TOP)/tools TOOLS= $(TOP)/tools
@ -206,8 +206,8 @@ Index: madwifi-trunk-r3314/Makefile.inc
# TARGET defines the target platform architecture. It must match one of # TARGET defines the target platform architecture. It must match one of
Index: madwifi-trunk-r3314/ath/if_ath_radar.c Index: madwifi-trunk-r3314/ath/if_ath_radar.c
=================================================================== ===================================================================
--- madwifi-trunk-r3314.orig/ath/if_ath_radar.c 2008-02-20 17:49:22.238127798 +0100 --- madwifi-trunk-r3314.orig/ath/if_ath_radar.c 2008-02-20 18:10:48.307267266 +0100
+++ madwifi-trunk-r3314/ath/if_ath_radar.c 2008-02-20 17:49:27.142407277 +0100 +++ madwifi-trunk-r3314/ath/if_ath_radar.c 2008-02-20 18:10:48.811295991 +0100
@@ -19,8 +19,6 @@ @@ -19,8 +19,6 @@
* $Id: if_ath_radar.c 2464 2007-06-15 22:51:56Z mtaylor $ * $Id: if_ath_radar.c 2464 2007-06-15 22:51:56Z mtaylor $
*/ */

View File

@ -1,34 +1,52 @@
Index: madwifi-trunk-r3280/ath/if_ath.c Index: madwifi-trunk-r3314/ath/if_ath.c
=================================================================== ===================================================================
--- madwifi-trunk-r3280.orig/ath/if_ath.c 2008-01-28 17:29:22.989895792 +0100 --- madwifi-trunk-r3314.orig/ath/if_ath.c 2008-02-20 21:56:33.725243076 +0100
+++ madwifi-trunk-r3280/ath/if_ath.c 2008-01-28 20:00:09.319637124 +0100 +++ madwifi-trunk-r3314/ath/if_ath.c 2008-02-20 21:57:34.912729951 +0100
@@ -184,7 +184,7 @@ @@ -184,7 +184,11 @@
struct sk_buff *, int, int, u_int64_t); struct sk_buff *, int, int, u_int64_t);
static void ath_setdefantenna(struct ath_softc *, u_int); static void ath_setdefantenna(struct ath_softc *, u_int);
static struct ath_txq *ath_txq_setup(struct ath_softc *, int, int); static struct ath_txq *ath_txq_setup(struct ath_softc *, int, int);
-static void ath_rx_tasklet(TQUEUE_ARG); -static void ath_rx_tasklet(TQUEUE_ARG);
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+static int ath_rx_poll(struct napi_struct *napi, int budget);
+#else
+static int ath_rx_poll(struct net_device *dev, int *budget); +static int ath_rx_poll(struct net_device *dev, int *budget);
+#endif
static int ath_hardstart(struct sk_buff *, struct net_device *); static int ath_hardstart(struct sk_buff *, struct net_device *);
static int ath_mgtstart(struct ieee80211com *, struct sk_buff *); static int ath_mgtstart(struct ieee80211com *, struct sk_buff *);
#ifdef ATH_SUPERG_COMP #ifdef ATH_SUPERG_COMP
@@ -542,7 +542,6 @@ @@ -374,6 +378,9 @@
ATH_TXBUF_LOCK_INIT(sc); u_int32_t new_clamped_maxtxpower);
ATH_RXBUF_LOCK_INIT(sc); static u_int32_t ath_get_real_maxtxpower(struct ath_softc *sc);
+static void ath_poll_disable(struct net_device *dev);
+static void ath_poll_enable(struct net_device *dev);
+
/* calibrate every 30 secs in steady state but check every second at first. */
static int ath_calinterval = ATH_SHORT_CALINTERVAL;
static int ath_countrycode = CTRY_DEFAULT; /* country code */
@@ -545,7 +552,6 @@
atomic_set(&sc->sc_txbuf_counter, 0);
- ATH_INIT_TQUEUE(&sc->sc_rxtq, ath_rx_tasklet, dev); - ATH_INIT_TQUEUE(&sc->sc_rxtq, ath_rx_tasklet, dev);
ATH_INIT_TQUEUE(&sc->sc_txtq, ath_tx_tasklet, dev); ATH_INIT_TQUEUE(&sc->sc_txtq, ath_tx_tasklet, dev);
ATH_INIT_TQUEUE(&sc->sc_bmisstq, ath_bmiss_tasklet, dev); ATH_INIT_TQUEUE(&sc->sc_bmisstq, ath_bmiss_tasklet, dev);
ATH_INIT_TQUEUE(&sc->sc_bstucktq, ath_bstuck_tasklet, dev); ATH_INIT_TQUEUE(&sc->sc_bstucktq, ath_bstuck_tasklet, dev);
@@ -816,6 +815,8 @@ @@ -819,6 +825,12 @@
dev->set_mac_address = ath_set_mac_address; dev->set_mac_address = ath_set_mac_address;
dev->change_mtu = ath_change_mtu; dev->change_mtu = ath_change_mtu;
dev->tx_queue_len = ATH_TXBUF - ATH_TXBUF_MGT_RESERVED; dev->tx_queue_len = ATH_TXBUF - ATH_TXBUF_MGT_RESERVED;
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+ netif_napi_add(dev, &sc->sc_napi, ath_rx_poll, 64);
+#else
+ dev->poll = ath_rx_poll; + dev->poll = ath_rx_poll;
+ dev->weight = 64; + dev->weight = 64;
+#endif
#ifdef USE_HEADERLEN_RESV #ifdef USE_HEADERLEN_RESV
dev->hard_header_len += sizeof(struct ieee80211_qosframe) + dev->hard_header_len += sizeof(struct ieee80211_qosframe) +
sizeof(struct llc) + sizeof(struct llc) +
@@ -2206,6 +2207,7 @@ @@ -2213,6 +2225,7 @@
(status & HAL_INT_GLOBAL) ? " HAL_INT_GLOBAL" : "" (status & HAL_INT_GLOBAL) ? " HAL_INT_GLOBAL" : ""
); );
@ -36,23 +54,32 @@ Index: madwifi-trunk-r3280/ath/if_ath.c
status &= sc->sc_imask; /* discard unasked for bits */ status &= sc->sc_imask; /* discard unasked for bits */
/* As soon as we know we have a real interrupt we intend to service, /* As soon as we know we have a real interrupt we intend to service,
* we will check to see if we need an initial hardware TSF reading. * we will check to see if we need an initial hardware TSF reading.
@@ -2263,7 +2265,14 @@ @@ -2270,7 +2283,23 @@
} }
if (status & (HAL_INT_RX | HAL_INT_RXPHY)) { if (status & (HAL_INT_RX | HAL_INT_RXPHY)) {
ath_uapsd_processtriggers(sc, hw_tsf); ath_uapsd_processtriggers(sc, hw_tsf);
- ATH_SCHEDULE_TQUEUE(&sc->sc_rxtq, &needmark); - ATH_SCHEDULE_TQUEUE(&sc->sc_rxtq, &needmark);
+ sc->sc_isr &= ~HAL_INT_RX; + sc->sc_isr &= ~HAL_INT_RX;
+ if (netif_rx_schedule_prep(dev)) { +#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+ if (netif_rx_schedule_prep(dev, &sc->sc_napi))
+#else
+ if (netif_rx_schedule_prep(dev))
+#endif
+ {
+#ifndef ATH_PRECISE_TSF +#ifndef ATH_PRECISE_TSF
+ sc->sc_imask &= ~HAL_INT_RX; + sc->sc_imask &= ~HAL_INT_RX;
+ ath_hal_intrset(ah, sc->sc_imask); + ath_hal_intrset(ah, sc->sc_imask);
+#endif +#endif
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+ __netif_rx_schedule(dev, &sc->sc_napi);
+#else
+ __netif_rx_schedule(dev); + __netif_rx_schedule(dev);
+#endif
+ } + }
} }
if (status & HAL_INT_TX) { if (status & HAL_INT_TX) {
#ifdef ATH_SUPERG_DYNTURBO #ifdef ATH_SUPERG_DYNTURBO
@@ -2289,6 +2298,11 @@ @@ -2296,6 +2325,11 @@
} }
} }
#endif #endif
@ -64,62 +91,137 @@ Index: madwifi-trunk-r3280/ath/if_ath.c
ATH_SCHEDULE_TQUEUE(&sc->sc_txtq, &needmark); ATH_SCHEDULE_TQUEUE(&sc->sc_txtq, &needmark);
} }
if (status & HAL_INT_BMISS) { if (status & HAL_INT_BMISS) {
@@ -4011,10 +4025,10 @@ @@ -2508,6 +2542,7 @@
* if (sc->sc_tx99 != NULL)
* XXX Using in_softirq is not right since we might sc->sc_tx99->start(sc->sc_tx99);
* be called from other soft irq contexts than #endif
- * ath_rx_tasklet. + ath_poll_enable(dev);
done:
ATH_UNLOCK(sc);
@@ -2548,6 +2583,9 @@
if (sc->sc_tx99 != NULL)
sc->sc_tx99->stop(sc->sc_tx99);
#endif
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+ ath_poll_disable(dev);
+#endif
netif_stop_queue(dev); /* XXX re-enabled by ath_newstate */
dev->flags &= ~IFF_RUNNING; /* NB: avoid recursion */
ieee80211_stop_running(ic); /* stop all VAPs */
@@ -4006,6 +4044,39 @@
return ath_keyset(sc, k, mac, vap->iv_bss);
}
+static void ath_poll_disable(struct net_device *dev)
+{
+ struct ath_softc *sc = dev->priv;
+
+ /*
+ * XXX Using in_softirq is not right since we might
+ * be called from other soft irq contexts than
+ * ath_rx_poll + * ath_rx_poll
*/ + */
if (!in_softirq()) + if (!in_softirq()) {
- tasklet_disable(&sc->sc_rxtq); +#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+ napi_disable(&sc->sc_napi);
+#else
+ netif_poll_disable(dev); + netif_poll_disable(dev);
+#endif
+ }
+}
+
+static void ath_poll_enable(struct net_device *dev)
+{
+ struct ath_softc *sc = dev->priv;
+
+ /* NB: see above */
+ if (!in_softirq()) {
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+ napi_enable(&sc->sc_napi);
+#else
+ netif_poll_enable(dev);
+#endif
+ }
+}
+
+
/*
* Block/unblock tx+rx processing while a key change is done.
* We assume the caller serializes key management operations
@@ -4023,13 +4094,7 @@
* When called from the rx tasklet we cannot use
* tasklet_disable because it will block waiting
* for us to complete execution.
- *
- * XXX Using in_softirq is not right since we might
- * be called from other soft irq contexts than
- * ath_rx_tasklet.
*/
- if (!in_softirq())
- tasklet_disable(&sc->sc_rxtq);
netif_stop_queue(dev); netif_stop_queue(dev);
} }
@@ -4027,7 +4041,7 @@ @@ -4040,9 +4105,9 @@
struct ath_softc *sc = dev->priv;
DPRINTF(sc, ATH_DEBUG_KEYCACHE, "End\n"); DPRINTF(sc, ATH_DEBUG_KEYCACHE, "End\n");
netif_wake_queue(dev); - netif_wake_queue(dev);
if (!in_softirq()) /* NB: see above */ - if (!in_softirq()) /* NB: see above */
- tasklet_enable(&sc->sc_rxtq); - tasklet_enable(&sc->sc_rxtq);
+ netif_poll_enable(dev); +
+ if (dev->flags&IFF_RUNNING)
+ netif_wake_queue(dev);
} }
/* /*
@@ -6329,13 +6343,12 @@ @@ -6347,13 +6412,23 @@
sc->sc_rxotherant = 0; sc->sc_rxotherant = 0;
} }
-static void -static void
-ath_rx_tasklet(TQUEUE_ARG data) -ath_rx_tasklet(TQUEUE_ARG data)
+static int +static int
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+ath_rx_poll(struct napi_struct *napi, int budget)
+#else
+ath_rx_poll(struct net_device *dev, int *budget) +ath_rx_poll(struct net_device *dev, int *budget)
+#endif
{ {
#define PA2DESC(_sc, _pa) \ #define PA2DESC(_sc, _pa) \
((struct ath_desc *)((caddr_t)(_sc)->sc_rxdma.dd_desc + \ ((struct ath_desc *)((caddr_t)(_sc)->sc_rxdma.dd_desc + \
((_pa) - (_sc)->sc_rxdma.dd_desc_paddr))) ((_pa) - (_sc)->sc_rxdma.dd_desc_paddr)))
- struct net_device *dev = (struct net_device *)data; - struct net_device *dev = (struct net_device *)data;
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+ struct ath_softc *sc = container_of(napi, struct ath_softc, sc_napi);
+ struct net_device *dev = sc->sc_dev;
+ u_int rx_limit = budget;
+#else
+ u_int rx_limit = dev->quota;
+#endif
struct ath_buf *bf; struct ath_buf *bf;
struct ath_softc *sc = dev->priv; struct ath_softc *sc = dev->priv;
struct ieee80211com *ic = &sc->sc_ic; struct ieee80211com *ic = &sc->sc_ic;
@@ -6347,8 +6360,11 @@ @@ -6365,8 +6440,10 @@
unsigned int len; unsigned int len;
int type; int type;
u_int phyerr; u_int phyerr;
+ u_int processed = 0, early_stop = 0; + u_int processed = 0, early_stop = 0;
+ u_int rx_limit = dev->quota;
DPRINTF(sc, ATH_DEBUG_RX_PROC, "invoked\n"); DPRINTF(sc, ATH_DEBUG_RX_PROC, "invoked\n");
+process_rx_again: +process_rx_again:
do { do {
bf = STAILQ_FIRST(&sc->sc_rxbuf); bf = STAILQ_FIRST(&sc->sc_rxbuf);
if (bf == NULL) { /* XXX ??? can this happen */ if (bf == NULL) { /* XXX ??? can this happen */
@@ -6372,6 +6388,13 @@ @@ -6390,6 +6467,15 @@
/* NB: never process the self-linked entry at the end */ /* NB: never process the self-linked entry at the end */
break; break;
} }
+ +
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+ processed++; + processed++;
+#endif
+ if (rx_limit-- < 0) { + if (rx_limit-- < 0) {
+ early_stop = 1; + early_stop = 1;
+ break; + break;
@ -128,7 +230,7 @@ Index: madwifi-trunk-r3280/ath/if_ath.c
skb = bf->bf_skb; skb = bf->bf_skb;
if (skb == NULL) { if (skb == NULL) {
EPRINTF(sc, "Dropping; buffer contains NULL skbuff.\n"); EPRINTF(sc, "Dropping; buffer contains NULL skbuff.\n");
@@ -6419,6 +6442,7 @@ @@ -6437,6 +6523,7 @@
sc->sc_stats.ast_rx_phyerr++; sc->sc_stats.ast_rx_phyerr++;
phyerr = rs->rs_phyerr & 0x1f; phyerr = rs->rs_phyerr & 0x1f;
sc->sc_stats.ast_rx_phy[phyerr]++; sc->sc_stats.ast_rx_phy[phyerr]++;
@ -136,7 +238,7 @@ Index: madwifi-trunk-r3280/ath/if_ath.c
} }
if (rs->rs_status & HAL_RXERR_DECRYPT) { if (rs->rs_status & HAL_RXERR_DECRYPT) {
/* /*
@@ -6614,9 +6638,35 @@ @@ -6632,9 +6719,38 @@
STAILQ_INSERT_TAIL(&sc->sc_rxbuf, bf, bf_list); STAILQ_INSERT_TAIL(&sc->sc_rxbuf, bf, bf_list);
ATH_RXBUF_UNLOCK_IRQ(sc); ATH_RXBUF_UNLOCK_IRQ(sc);
} while (ath_rxbuf_init(sc, bf) == 0); } while (ath_rxbuf_init(sc, bf) == 0);
@ -155,8 +257,6 @@ Index: madwifi-trunk-r3280/ath/if_ath.c
+ goto process_rx_again; + goto process_rx_again;
+ } + }
+#endif +#endif
+ netif_rx_complete(dev);
+
+#ifndef ATH_PRECISE_TSF +#ifndef ATH_PRECISE_TSF
+ sc->sc_imask |= HAL_INT_RX; + sc->sc_imask |= HAL_INT_RX;
+ ath_hal_intrset(ah, sc->sc_imask); + ath_hal_intrset(ah, sc->sc_imask);
@ -164,7 +264,12 @@ Index: madwifi-trunk-r3280/ath/if_ath.c
+#endif +#endif
+ } + }
+ +
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+ netif_rx_complete(dev, napi);
+#else
+ netif_rx_complete(dev);
+ *budget -= processed; + *budget -= processed;
+#endif
/* rx signal state monitoring */ /* rx signal state monitoring */
ath_hal_rxmonitor(ah, &sc->sc_halstats, &sc->sc_curchan); ath_hal_rxmonitor(ah, &sc->sc_halstats, &sc->sc_curchan);
@ -172,7 +277,7 @@ Index: madwifi-trunk-r3280/ath/if_ath.c
#undef PA2DESC #undef PA2DESC
} }
@@ -8267,12 +8317,24 @@ @@ -8285,12 +8401,24 @@
{ {
struct net_device *dev = (struct net_device *)data; struct net_device *dev = (struct net_device *)data;
struct ath_softc *sc = dev->priv; struct ath_softc *sc = dev->priv;
@ -197,7 +302,7 @@ Index: madwifi-trunk-r3280/ath/if_ath.c
netif_wake_queue(dev); netif_wake_queue(dev);
if (sc->sc_softled) if (sc->sc_softled)
@@ -8288,7 +8350,9 @@ @@ -8306,7 +8434,9 @@
{ {
struct net_device *dev = (struct net_device *)data; struct net_device *dev = (struct net_device *)data;
struct ath_softc *sc = dev->priv; struct ath_softc *sc = dev->priv;
@ -207,7 +312,7 @@ Index: madwifi-trunk-r3280/ath/if_ath.c
/* /*
* Process each active queue. * Process each active queue.
*/ */
@@ -8309,6 +8373,16 @@ @@ -8327,6 +8457,16 @@
if (sc->sc_uapsdq && txqactive(sc->sc_ah, sc->sc_uapsdq->axq_qnum)) if (sc->sc_uapsdq && txqactive(sc->sc_ah, sc->sc_uapsdq->axq_qnum))
ath_tx_processq(sc, sc->sc_uapsdq); ath_tx_processq(sc, sc->sc_uapsdq);
@ -224,7 +329,7 @@ Index: madwifi-trunk-r3280/ath/if_ath.c
netif_wake_queue(dev); netif_wake_queue(dev);
if (sc->sc_softled) if (sc->sc_softled)
@@ -8324,13 +8398,25 @@ @@ -8342,13 +8482,25 @@
struct net_device *dev = (struct net_device *)data; struct net_device *dev = (struct net_device *)data;
struct ath_softc *sc = dev->priv; struct ath_softc *sc = dev->priv;
unsigned int i; unsigned int i;
@ -250,7 +355,7 @@ Index: madwifi-trunk-r3280/ath/if_ath.c
netif_wake_queue(dev); netif_wake_queue(dev);
if (sc->sc_softled) if (sc->sc_softled)
@@ -8405,6 +8491,7 @@ @@ -8423,6 +8575,7 @@
ath_draintxq(struct ath_softc *sc) ath_draintxq(struct ath_softc *sc)
{ {
struct ath_hal *ah = sc->sc_ah; struct ath_hal *ah = sc->sc_ah;
@ -258,25 +363,25 @@ Index: madwifi-trunk-r3280/ath/if_ath.c
unsigned int i; unsigned int i;
/* XXX return value */ /* XXX return value */
@@ -10261,9 +10348,9 @@ @@ -10281,9 +10434,9 @@
dev->mtu = mtu; dev->mtu = mtu;
if ((dev->flags & IFF_RUNNING) && !sc->sc_invalid) { if ((dev->flags & IFF_RUNNING) && !sc->sc_invalid) {
/* NB: the rx buffers may need to be reallocated */ /* NB: the rx buffers may need to be reallocated */
- tasklet_disable(&sc->sc_rxtq); - tasklet_disable(&sc->sc_rxtq);
+ netif_poll_disable(dev); + ath_poll_disable(dev);
error = ath_reset(dev); error = ath_reset(dev);
- tasklet_enable(&sc->sc_rxtq); - tasklet_enable(&sc->sc_rxtq);
+ netif_poll_enable(dev); + ath_poll_enable(dev);
} }
ATH_UNLOCK(sc); ATH_UNLOCK(sc);
Index: madwifi-trunk-r3280/ath/if_athvar.h Index: madwifi-trunk-r3314/ath/if_athvar.h
=================================================================== ===================================================================
--- madwifi-trunk-r3280.orig/ath/if_athvar.h 2008-01-28 17:29:22.997896245 +0100 --- madwifi-trunk-r3314.orig/ath/if_athvar.h 2008-02-20 21:56:33.733243528 +0100
+++ madwifi-trunk-r3280/ath/if_athvar.h 2008-01-28 17:45:06.903383316 +0100 +++ madwifi-trunk-r3314/ath/if_athvar.h 2008-02-20 21:57:34.892728811 +0100
@@ -50,6 +50,10 @@ @@ -53,6 +53,10 @@
#include <asm/io.h> # include <asm/bitops.h>
#include <linux/list.h> #endif
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,0) +#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,0)
+#define irqs_disabled() 0 +#define irqs_disabled() 0
@ -285,7 +390,17 @@ Index: madwifi-trunk-r3280/ath/if_athvar.h
/* /*
* Deduce if tasklets are available. If not then * Deduce if tasklets are available. If not then
* fall back to using the immediate work queue. * fall back to using the immediate work queue.
@@ -728,7 +732,6 @@ @@ -616,6 +620,9 @@
struct ath_softc {
struct ieee80211com sc_ic; /* NB: must be first */
struct net_device *sc_dev;
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+ struct napi_struct sc_napi;
+#endif
void __iomem *sc_iobase; /* address of the device */
struct semaphore sc_lock; /* dev-level lock */
struct net_device_stats sc_devstats; /* device statistics */
@@ -730,7 +737,6 @@
struct ath_buf *sc_rxbufcur; /* current rx buffer */ struct ath_buf *sc_rxbufcur; /* current rx buffer */
u_int32_t *sc_rxlink; /* link ptr in last RX desc */ u_int32_t *sc_rxlink; /* link ptr in last RX desc */
spinlock_t sc_rxbuflock; spinlock_t sc_rxbuflock;
@ -293,7 +408,7 @@ Index: madwifi-trunk-r3280/ath/if_athvar.h
struct ATH_TQ_STRUCT sc_rxorntq; /* rxorn intr tasklet */ struct ATH_TQ_STRUCT sc_rxorntq; /* rxorn intr tasklet */
u_int8_t sc_defant; /* current default antenna */ u_int8_t sc_defant; /* current default antenna */
u_int8_t sc_rxotherant; /* RXs on non-default antenna */ u_int8_t sc_rxotherant; /* RXs on non-default antenna */
@@ -741,6 +744,7 @@ @@ -745,6 +751,7 @@
u_int sc_txintrperiod; /* tx interrupt batching */ u_int sc_txintrperiod; /* tx interrupt batching */
struct ath_txq sc_txq[HAL_NUM_TX_QUEUES]; struct ath_txq sc_txq[HAL_NUM_TX_QUEUES];
struct ath_txq *sc_ac2q[WME_NUM_AC]; /* WME AC -> h/w qnum */ struct ath_txq *sc_ac2q[WME_NUM_AC]; /* WME AC -> h/w qnum */
@ -301,7 +416,7 @@ Index: madwifi-trunk-r3280/ath/if_athvar.h
struct ATH_TQ_STRUCT sc_txtq; /* tx intr tasklet */ struct ATH_TQ_STRUCT sc_txtq; /* tx intr tasklet */
u_int8_t sc_grppoll_str[GRPPOLL_RATE_STR_LEN]; u_int8_t sc_grppoll_str[GRPPOLL_RATE_STR_LEN];
struct ath_descdma sc_bdma; /* beacon descriptors */ struct ath_descdma sc_bdma; /* beacon descriptors */
@@ -854,6 +858,8 @@ @@ -858,6 +865,8 @@
#define ATH_TXBUF_LOCK_CHECK(_sc) #define ATH_TXBUF_LOCK_CHECK(_sc)
#endif #endif
@ -310,11 +425,11 @@ Index: madwifi-trunk-r3280/ath/if_athvar.h
#define ATH_RXBUF_LOCK_INIT(_sc) spin_lock_init(&(_sc)->sc_rxbuflock) #define ATH_RXBUF_LOCK_INIT(_sc) spin_lock_init(&(_sc)->sc_rxbuflock)
#define ATH_RXBUF_LOCK_DESTROY(_sc) #define ATH_RXBUF_LOCK_DESTROY(_sc)
Index: madwifi-trunk-r3280/net80211/ieee80211_input.c Index: madwifi-trunk-r3314/net80211/ieee80211_input.c
=================================================================== ===================================================================
--- madwifi-trunk-r3280.orig/net80211/ieee80211_input.c 2008-01-28 17:29:23.005896702 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_input.c 2008-02-20 21:56:33.741243986 +0100
+++ madwifi-trunk-r3280/net80211/ieee80211_input.c 2008-01-28 19:52:50.586635164 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_input.c 2008-02-20 21:57:34.896729040 +0100
@@ -1197,7 +1197,7 @@ @@ -1198,7 +1198,7 @@
/* attach vlan tag */ /* attach vlan tag */
struct ieee80211_node *ni_tmp = SKB_CB(skb)->ni; struct ieee80211_node *ni_tmp = SKB_CB(skb)->ni;
if (vlan_hwaccel_receive_skb(skb, vap->iv_vlgrp, ni->ni_vlan) == NET_RX_DROP) { if (vlan_hwaccel_receive_skb(skb, vap->iv_vlgrp, ni->ni_vlan) == NET_RX_DROP) {
@ -323,7 +438,7 @@ Index: madwifi-trunk-r3280/net80211/ieee80211_input.c
* device was too busy */ * device was too busy */
if (ni_tmp != NULL) { if (ni_tmp != NULL) {
/* node reference was leaked */ /* node reference was leaked */
@@ -1208,8 +1208,8 @@ @@ -1209,8 +1209,8 @@
skb = NULL; /* SKB is no longer ours */ skb = NULL; /* SKB is no longer ours */
} else { } else {
struct ieee80211_node *ni_tmp = SKB_CB(skb)->ni; struct ieee80211_node *ni_tmp = SKB_CB(skb)->ni;
@ -334,7 +449,7 @@ Index: madwifi-trunk-r3280/net80211/ieee80211_input.c
* device was too busy */ * device was too busy */
if (ni_tmp != NULL) { if (ni_tmp != NULL) {
/* node reference was leaked */ /* node reference was leaked */
@@ -2314,8 +2314,8 @@ @@ -2322,8 +2322,8 @@
skb1->protocol = __constant_htons(0x0019); /* ETH_P_80211_RAW */ skb1->protocol = __constant_htons(0x0019); /* ETH_P_80211_RAW */
ni_tmp = SKB_CB(skb1)->ni; ni_tmp = SKB_CB(skb1)->ni;
@ -345,10 +460,10 @@ Index: madwifi-trunk-r3280/net80211/ieee80211_input.c
* device was too busy */ * device was too busy */
if (ni_tmp != NULL) { if (ni_tmp != NULL) {
/* node reference was leaked */ /* node reference was leaked */
Index: madwifi-trunk-r3280/net80211/ieee80211_monitor.c Index: madwifi-trunk-r3314/net80211/ieee80211_monitor.c
=================================================================== ===================================================================
--- madwifi-trunk-r3280.orig/net80211/ieee80211_monitor.c 2008-01-28 17:29:23.013897159 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_monitor.c 2008-02-20 21:56:33.749244442 +0100
+++ madwifi-trunk-r3280/net80211/ieee80211_monitor.c 2008-01-28 17:29:26.430091834 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_monitor.c 2008-02-20 21:57:34.900729266 +0100
@@ -584,8 +584,8 @@ @@ -584,8 +584,8 @@
skb1->protocol = skb1->protocol =
__constant_htons(0x0019); /* ETH_P_80211_RAW */ __constant_htons(0x0019); /* ETH_P_80211_RAW */
@ -360,10 +475,10 @@ Index: madwifi-trunk-r3280/net80211/ieee80211_monitor.c
* device was too busy, reclaim the ref. in * device was too busy, reclaim the ref. in
* the skb. */ * the skb. */
if (SKB_CB(skb1)->ni != NULL) if (SKB_CB(skb1)->ni != NULL)
Index: madwifi-trunk-r3280/net80211/ieee80211_skb.c Index: madwifi-trunk-r3314/net80211/ieee80211_skb.c
=================================================================== ===================================================================
--- madwifi-trunk-r3280.orig/net80211/ieee80211_skb.c 2008-01-28 17:29:23.017897384 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_skb.c 2008-02-20 21:56:33.757244897 +0100
+++ madwifi-trunk-r3280/net80211/ieee80211_skb.c 2008-01-28 17:29:26.446092748 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_skb.c 2008-02-20 21:57:34.904729495 +0100
@@ -73,7 +73,7 @@ @@ -73,7 +73,7 @@
#undef dev_queue_xmit #undef dev_queue_xmit
#undef kfree_skb #undef kfree_skb
@ -393,10 +508,10 @@ Index: madwifi-trunk-r3280/net80211/ieee80211_skb.c
EXPORT_SYMBOL(alloc_skb_debug); EXPORT_SYMBOL(alloc_skb_debug);
EXPORT_SYMBOL(dev_alloc_skb_debug); EXPORT_SYMBOL(dev_alloc_skb_debug);
EXPORT_SYMBOL(skb_clone_debug); EXPORT_SYMBOL(skb_clone_debug);
Index: madwifi-trunk-r3280/net80211/ieee80211_skb.h Index: madwifi-trunk-r3314/net80211/ieee80211_skb.h
=================================================================== ===================================================================
--- madwifi-trunk-r3280.orig/net80211/ieee80211_skb.h 2008-01-28 17:29:23.029898072 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_skb.h 2008-02-20 21:56:33.765245356 +0100
+++ madwifi-trunk-r3280/net80211/ieee80211_skb.h 2008-01-28 17:29:26.458093432 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_skb.h 2008-02-20 21:57:34.908729722 +0100
@@ -116,7 +116,7 @@ @@ -116,7 +116,7 @@
int vlan_hwaccel_receive_skb_debug(struct sk_buff *skb, int vlan_hwaccel_receive_skb_debug(struct sk_buff *skb,
struct vlan_group *grp, unsigned short vlan_tag, struct vlan_group *grp, unsigned short vlan_tag,

View File

@ -1,8 +1,8 @@
Index: madwifi-trunk-r3280/ath/if_ath.c Index: madwifi-trunk-r3314/ath/if_ath.c
=================================================================== ===================================================================
--- madwifi-trunk-r3280.orig/ath/if_ath.c 2008-01-28 17:29:41.614957171 +0100 --- madwifi-trunk-r3314.orig/ath/if_ath.c 2008-02-20 21:57:41.025078273 +0100
+++ madwifi-trunk-r3280/ath/if_ath.c 2008-01-28 17:29:54.895713998 +0100 +++ madwifi-trunk-r3314/ath/if_ath.c 2008-02-20 21:57:44.393270217 +0100
@@ -4080,7 +4080,9 @@ @@ -4146,7 +4146,9 @@
rfilt |= HAL_RX_FILTER_PROM; rfilt |= HAL_RX_FILTER_PROM;
if (ic->ic_opmode == IEEE80211_M_STA || if (ic->ic_opmode == IEEE80211_M_STA ||
sc->sc_opmode == HAL_M_IBSS || /* NB: AHDEMO too */ sc->sc_opmode == HAL_M_IBSS || /* NB: AHDEMO too */
@ -13,10 +13,10 @@ Index: madwifi-trunk-r3280/ath/if_ath.c
rfilt |= HAL_RX_FILTER_BEACON; rfilt |= HAL_RX_FILTER_BEACON;
if (sc->sc_nmonvaps > 0) if (sc->sc_nmonvaps > 0)
rfilt |= (HAL_RX_FILTER_CONTROL | HAL_RX_FILTER_BEACON | rfilt |= (HAL_RX_FILTER_CONTROL | HAL_RX_FILTER_BEACON |
Index: madwifi-trunk-r3280/net80211/ieee80211_input.c Index: madwifi-trunk-r3314/net80211/ieee80211_input.c
=================================================================== ===================================================================
--- madwifi-trunk-r3280.orig/net80211/ieee80211_input.c 2008-01-28 17:29:26.378088873 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_input.c 2008-02-20 21:57:41.037078957 +0100
+++ madwifi-trunk-r3280/net80211/ieee80211_input.c 2008-01-28 17:29:54.999719926 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_input.c 2008-02-20 21:57:44.401270672 +0100
@@ -346,11 +346,12 @@ @@ -346,11 +346,12 @@
bssid = wh->i_addr3; bssid = wh->i_addr3;
} }
@ -53,7 +53,7 @@ Index: madwifi-trunk-r3280/net80211/ieee80211_input.c
break; break;
case IEEE80211_M_WDS: case IEEE80211_M_WDS:
if (skb->len < sizeof(struct ieee80211_frame_addr4)) { if (skb->len < sizeof(struct ieee80211_frame_addr4)) {
@@ -3058,7 +3055,7 @@ @@ -3066,7 +3063,7 @@
u_int8_t *frm, *efrm; u_int8_t *frm, *efrm;
u_int8_t *ssid, *rates, *xrates, *suppchan, *wpa, *rsn, *wme, *ath; u_int8_t *ssid, *rates, *xrates, *suppchan, *wpa, *rsn, *wme, *ath;
u_int8_t rate; u_int8_t rate;
@ -62,7 +62,7 @@ Index: madwifi-trunk-r3280/net80211/ieee80211_input.c
u_int8_t qosinfo; u_int8_t qosinfo;
if (ni_or_null == NULL) if (ni_or_null == NULL)
@@ -3088,11 +3085,15 @@ @@ -3096,11 +3093,15 @@
* o station mode when associated (to collect state * o station mode when associated (to collect state
* updates such as 802.11g slot time), or * updates such as 802.11g slot time), or
* o adhoc mode (to discover neighbors) * o adhoc mode (to discover neighbors)
@ -79,7 +79,7 @@ Index: madwifi-trunk-r3280/net80211/ieee80211_input.c
vap->iv_stats.is_rx_mgtdiscard++; vap->iv_stats.is_rx_mgtdiscard++;
return; return;
} }
@@ -3176,6 +3177,7 @@ @@ -3184,6 +3185,7 @@
break; break;
} }
scan.erp = frm[2]; scan.erp = frm[2];
@ -87,7 +87,7 @@ Index: madwifi-trunk-r3280/net80211/ieee80211_input.c
break; break;
case IEEE80211_ELEMID_RSN: case IEEE80211_ELEMID_RSN:
scan.rsn = frm; scan.rsn = frm;
@@ -3413,6 +3415,20 @@ @@ -3421,6 +3423,20 @@
ieee80211_bg_scan(vap); ieee80211_bg_scan(vap);
return; return;
} }
@ -108,10 +108,10 @@ Index: madwifi-trunk-r3280/net80211/ieee80211_input.c
/* /*
* If scanning, just pass information to the scan module. * If scanning, just pass information to the scan module.
*/ */
Index: madwifi-trunk-r3280/net80211/ieee80211_node.c Index: madwifi-trunk-r3314/net80211/ieee80211_node.c
=================================================================== ===================================================================
--- madwifi-trunk-r3280.orig/net80211/ieee80211_node.c 2008-01-28 17:27:08.000000000 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_node.c 2008-02-20 21:56:33.629237604 +0100
+++ madwifi-trunk-r3280/net80211/ieee80211_node.c 2008-01-28 17:29:55.199731324 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_node.c 2008-02-20 21:57:44.409271127 +0100
@@ -383,10 +383,16 @@ @@ -383,10 +383,16 @@
/* Update country ie information */ /* Update country ie information */
ieee80211_build_countryie(ic); ieee80211_build_countryie(ic);
@ -131,10 +131,10 @@ Index: madwifi-trunk-r3280/net80211/ieee80211_node.c
(void) ieee80211_sta_join1(PASS_NODE(ni)); (void) ieee80211_sta_join1(PASS_NODE(ni));
} }
Index: madwifi-trunk-r3280/net80211/ieee80211_proto.c Index: madwifi-trunk-r3314/net80211/ieee80211_proto.c
=================================================================== ===================================================================
--- madwifi-trunk-r3280.orig/net80211/ieee80211_proto.c 2008-01-28 17:27:08.000000000 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_proto.c 2008-02-20 21:56:33.633237829 +0100
+++ madwifi-trunk-r3280/net80211/ieee80211_proto.c 2008-01-28 17:29:55.299737023 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_proto.c 2008-02-20 21:57:44.413271357 +0100
@@ -595,6 +595,28 @@ @@ -595,6 +595,28 @@
{ 4, { 2, 4, 11, 22 } }, /* IEEE80211_MODE_TURBO_G (mixed b/g) */ { 4, { 2, 4, 11, 22 } }, /* IEEE80211_MODE_TURBO_G (mixed b/g) */
}; };
@ -164,11 +164,11 @@ Index: madwifi-trunk-r3280/net80211/ieee80211_proto.c
/* /*
* Mark the basic rates for the 11g rate table based on the * Mark the basic rates for the 11g rate table based on the
* specified mode. For 11b compatibility we mark only 11b * specified mode. For 11b compatibility we mark only 11b
Index: madwifi-trunk-r3280/net80211/ieee80211_var.h Index: madwifi-trunk-r3314/net80211/ieee80211_var.h
=================================================================== ===================================================================
--- madwifi-trunk-r3280.orig/net80211/ieee80211_var.h 2008-01-28 17:27:08.000000000 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_var.h 2008-02-20 21:56:33.645238517 +0100
+++ madwifi-trunk-r3280/net80211/ieee80211_var.h 2008-01-28 17:30:20.585177966 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_var.h 2008-02-20 21:57:44.417271583 +0100
@@ -694,6 +694,7 @@ @@ -707,6 +707,7 @@
void ieee80211_build_sc_ie(struct ieee80211com *); void ieee80211_build_sc_ie(struct ieee80211com *);
void ieee80211_dfs_action(struct ieee80211com *); void ieee80211_dfs_action(struct ieee80211com *);
void ieee80211_expire_channel_excl_restrictions(struct ieee80211com *); void ieee80211_expire_channel_excl_restrictions(struct ieee80211com *);

View File

@ -1,16 +1,16 @@
Index: madwifi-dfs-r3280/ath/if_ath.c Index: madwifi-trunk-r3314/ath/if_ath.c
=================================================================== ===================================================================
--- madwifi-dfs-r3280.orig/ath/if_ath.c 2008-01-28 17:14:55.182157045 +0100 --- madwifi-trunk-r3314.orig/ath/if_ath.c 2008-02-20 21:55:41.314256342 +0100
+++ madwifi-dfs-r3280/ath/if_ath.c 2008-01-28 17:15:04.876271620 +0100 +++ madwifi-trunk-r3314/ath/if_ath.c 2008-02-20 21:56:10.819937775 +0100
@@ -6379,6 +6379,7 @@ @@ -6443,6 +6443,7 @@
int type;
u_int phyerr; u_int phyerr;
u_int processed = 0, early_stop = 0; u_int processed = 0, early_stop = 0;
u_int rx_limit = dev->quota;
+ u_int mic_fail = 0; + u_int mic_fail = 0;
DPRINTF(sc, ATH_DEBUG_RX_PROC, "invoked\n"); DPRINTF(sc, ATH_DEBUG_RX_PROC, "invoked\n");
process_rx_again: process_rx_again:
@@ -6478,24 +6479,8 @@ @@ -6544,24 +6545,8 @@
} }
if (rs->rs_status & HAL_RXERR_MIC) { if (rs->rs_status & HAL_RXERR_MIC) {
sc->sc_stats.ast_rx_badmic++; sc->sc_stats.ast_rx_badmic++;
@ -37,7 +37,7 @@ Index: madwifi-dfs-r3280/ath/if_ath.c
} }
/* /*
* Reject error frames if we have no vaps that * Reject error frames if we have no vaps that
@@ -6534,8 +6519,9 @@ @@ -6600,8 +6585,9 @@
/* /*
* Finished monitor mode handling, now reject * Finished monitor mode handling, now reject
* error frames before passing to other vaps * error frames before passing to other vaps
@ -48,7 +48,7 @@ Index: madwifi-dfs-r3280/ath/if_ath.c
ieee80211_dev_kfree_skb(&skb); ieee80211_dev_kfree_skb(&skb);
goto rx_next; goto rx_next;
} }
@@ -6543,6 +6529,26 @@ @@ -6609,6 +6595,26 @@
/* remove the CRC */ /* remove the CRC */
skb_trim(skb, skb->len - IEEE80211_CRC_LEN); skb_trim(skb, skb->len - IEEE80211_CRC_LEN);
@ -75,7 +75,7 @@ Index: madwifi-dfs-r3280/ath/if_ath.c
/* /*
* From this point on we assume the frame is at least * From this point on we assume the frame is at least
* as large as ieee80211_frame_min; verify that. * as large as ieee80211_frame_min; verify that.
@@ -6555,6 +6561,7 @@ @@ -6621,6 +6627,7 @@
goto rx_next; goto rx_next;
} }
@ -83,10 +83,10 @@ Index: madwifi-dfs-r3280/ath/if_ath.c
/* /*
* Normal receive. * Normal receive.
*/ */
Index: madwifi-dfs-r3280/net80211/ieee80211_crypto_ccmp.c Index: madwifi-trunk-r3314/net80211/ieee80211_crypto_ccmp.c
=================================================================== ===================================================================
--- madwifi-dfs-r3280.orig/net80211/ieee80211_crypto_ccmp.c 2008-01-28 17:14:16.203935804 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_crypto_ccmp.c 2008-02-20 21:52:06.822033125 +0100
+++ madwifi-dfs-r3280/net80211/ieee80211_crypto_ccmp.c 2008-01-28 17:15:04.916253895 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_crypto_ccmp.c 2008-02-20 21:55:45.302483625 +0100
@@ -73,7 +73,7 @@ @@ -73,7 +73,7 @@
static int ccmp_encap(struct ieee80211_key *, struct sk_buff *, u_int8_t); static int ccmp_encap(struct ieee80211_key *, struct sk_buff *, u_int8_t);
static int ccmp_decap(struct ieee80211_key *, struct sk_buff *, int); static int ccmp_decap(struct ieee80211_key *, struct sk_buff *, int);
@ -105,10 +105,10 @@ Index: madwifi-dfs-r3280/net80211/ieee80211_crypto_ccmp.c
{ {
return 1; return 1;
} }
Index: madwifi-dfs-r3280/net80211/ieee80211_crypto.h Index: madwifi-trunk-r3314/net80211/ieee80211_crypto.h
=================================================================== ===================================================================
--- madwifi-dfs-r3280.orig/net80211/ieee80211_crypto.h 2008-01-28 17:13:49.000000000 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_crypto.h 2008-02-20 21:50:40.149093918 +0100
+++ madwifi-dfs-r3280/net80211/ieee80211_crypto.h 2008-01-28 17:15:05.116165297 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_crypto.h 2008-02-20 21:55:45.310484070 +0100
@@ -145,7 +145,7 @@ @@ -145,7 +145,7 @@
int (*ic_encap)(struct ieee80211_key *, struct sk_buff *, u_int8_t); int (*ic_encap)(struct ieee80211_key *, struct sk_buff *, u_int8_t);
int (*ic_decap)(struct ieee80211_key *, struct sk_buff *, int); int (*ic_decap)(struct ieee80211_key *, struct sk_buff *, int);
@ -131,10 +131,10 @@ Index: madwifi-dfs-r3280/net80211/ieee80211_crypto.h
} }
/* /*
Index: madwifi-dfs-r3280/net80211/ieee80211_crypto_none.c Index: madwifi-trunk-r3314/net80211/ieee80211_crypto_none.c
=================================================================== ===================================================================
--- madwifi-dfs-r3280.orig/net80211/ieee80211_crypto_none.c 2008-01-28 17:13:49.000000000 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_crypto_none.c 2008-02-20 21:50:40.153094148 +0100
+++ madwifi-dfs-r3280/net80211/ieee80211_crypto_none.c 2008-01-28 17:15:05.316076693 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_crypto_none.c 2008-02-20 21:55:45.314484297 +0100
@@ -52,7 +52,7 @@ @@ -52,7 +52,7 @@
static int none_encap(struct ieee80211_key *, struct sk_buff *, u_int8_t); static int none_encap(struct ieee80211_key *, struct sk_buff *, u_int8_t);
static int none_decap(struct ieee80211_key *, struct sk_buff *, int); static int none_decap(struct ieee80211_key *, struct sk_buff *, int);
@ -153,10 +153,10 @@ Index: madwifi-dfs-r3280/net80211/ieee80211_crypto_none.c
{ {
struct ieee80211vap *vap = k->wk_private; struct ieee80211vap *vap = k->wk_private;
Index: madwifi-dfs-r3280/net80211/ieee80211_crypto_tkip.c Index: madwifi-trunk-r3314/net80211/ieee80211_crypto_tkip.c
=================================================================== ===================================================================
--- madwifi-dfs-r3280.orig/net80211/ieee80211_crypto_tkip.c 2008-01-28 17:13:49.000000000 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_crypto_tkip.c 2008-02-20 21:50:40.161094600 +0100
+++ madwifi-dfs-r3280/net80211/ieee80211_crypto_tkip.c 2008-01-28 17:15:05.519986320 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_crypto_tkip.c 2008-02-20 21:55:45.314484297 +0100
@@ -57,7 +57,7 @@ @@ -57,7 +57,7 @@
static int tkip_encap(struct ieee80211_key *, struct sk_buff *, u_int8_t); static int tkip_encap(struct ieee80211_key *, struct sk_buff *, u_int8_t);
static int tkip_enmic(struct ieee80211_key *, struct sk_buff *, int); static int tkip_enmic(struct ieee80211_key *, struct sk_buff *, int);
@ -184,10 +184,10 @@ Index: madwifi-dfs-r3280/net80211/ieee80211_crypto_tkip.c
struct ieee80211vap *vap = ctx->tc_vap; struct ieee80211vap *vap = ctx->tc_vap;
u8 mic[IEEE80211_WEP_MICLEN]; u8 mic[IEEE80211_WEP_MICLEN];
u8 mic0[IEEE80211_WEP_MICLEN]; u8 mic0[IEEE80211_WEP_MICLEN];
Index: madwifi-dfs-r3280/net80211/ieee80211_crypto_wep.c Index: madwifi-trunk-r3314/net80211/ieee80211_crypto_wep.c
=================================================================== ===================================================================
--- madwifi-dfs-r3280.orig/net80211/ieee80211_crypto_wep.c 2008-01-28 17:13:49.000000000 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_crypto_wep.c 2008-02-20 21:50:40.169095058 +0100
+++ madwifi-dfs-r3280/net80211/ieee80211_crypto_wep.c 2008-01-28 17:15:05.731892402 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_crypto_wep.c 2008-02-20 21:55:45.314484297 +0100
@@ -54,7 +54,7 @@ @@ -54,7 +54,7 @@
static int wep_encap(struct ieee80211_key *, struct sk_buff *, u_int8_t); static int wep_encap(struct ieee80211_key *, struct sk_buff *, u_int8_t);
static int wep_decap(struct ieee80211_key *, struct sk_buff *, int); static int wep_decap(struct ieee80211_key *, struct sk_buff *, int);
@ -206,10 +206,10 @@ Index: madwifi-dfs-r3280/net80211/ieee80211_crypto_wep.c
{ {
return 1; return 1;
} }
Index: madwifi-dfs-r3280/net80211/ieee80211_input.c Index: madwifi-trunk-r3314/net80211/ieee80211_input.c
=================================================================== ===================================================================
--- madwifi-dfs-r3280.orig/net80211/ieee80211_input.c 2008-01-28 17:14:55.186157275 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_input.c 2008-02-20 21:55:41.318256570 +0100
+++ madwifi-dfs-r3280/net80211/ieee80211_input.c 2008-01-28 17:15:05.831848102 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_input.c 2008-02-20 21:55:45.318484528 +0100
@@ -669,7 +669,7 @@ @@ -669,7 +669,7 @@
* Next strip any MSDU crypto bits. * Next strip any MSDU crypto bits.
*/ */
@ -219,7 +219,7 @@ Index: madwifi-dfs-r3280/net80211/ieee80211_input.c
IEEE80211_DISCARD_MAC(vap, IEEE80211_MSG_INPUT, IEEE80211_DISCARD_MAC(vap, IEEE80211_MSG_INPUT,
ni->ni_macaddr, "data", "%s", "demic error"); ni->ni_macaddr, "data", "%s", "demic error");
IEEE80211_NODE_STAT(ni, rx_demicfail); IEEE80211_NODE_STAT(ni, rx_demicfail);
@@ -4222,6 +4222,47 @@ @@ -4293,6 +4293,47 @@
} }
#endif #endif
@ -267,10 +267,10 @@ Index: madwifi-dfs-r3280/net80211/ieee80211_input.c
#ifdef IEEE80211_DEBUG #ifdef IEEE80211_DEBUG
/* /*
* Debugging support. * Debugging support.
Index: madwifi-dfs-r3280/net80211/ieee80211_proto.h Index: madwifi-trunk-r3314/net80211/ieee80211_proto.h
=================================================================== ===================================================================
--- madwifi-dfs-r3280.orig/net80211/ieee80211_proto.h 2008-01-28 17:13:49.000000000 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_proto.h 2008-02-20 21:50:40.185095969 +0100
+++ madwifi-dfs-r3280/net80211/ieee80211_proto.h 2008-01-28 17:15:05.935802033 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_proto.h 2008-02-20 21:55:45.318484528 +0100
@@ -90,6 +90,7 @@ @@ -90,6 +90,7 @@
void ieee80211_set11gbasicrates(struct ieee80211_rateset *, enum ieee80211_phymode); void ieee80211_set11gbasicrates(struct ieee80211_rateset *, enum ieee80211_phymode);
enum ieee80211_phymode ieee80211_get11gbasicrates(struct ieee80211_rateset *); enum ieee80211_phymode ieee80211_get11gbasicrates(struct ieee80211_rateset *);
@ -279,10 +279,10 @@ Index: madwifi-dfs-r3280/net80211/ieee80211_proto.h
/* /*
* Return the size of the 802.11 header for a management or data frame. * Return the size of the 802.11 header for a management or data frame.
Index: madwifi-dfs-r3280/net80211/ieee80211_linux.c Index: madwifi-trunk-r3314/net80211/ieee80211_linux.c
=================================================================== ===================================================================
--- madwifi-dfs-r3280.orig/net80211/ieee80211_linux.c 2008-01-28 17:14:16.091929418 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_linux.c 2008-02-20 21:52:06.810032443 +0100
+++ madwifi-dfs-r3280/net80211/ieee80211_linux.c 2008-01-28 17:18:40.397276522 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_linux.c 2008-02-20 21:55:45.318484528 +0100
@@ -337,8 +337,8 @@ @@ -337,8 +337,8 @@
/* TODO: needed parameters: count, keyid, key type, src address, TSC */ /* TODO: needed parameters: count, keyid, key type, src address, TSC */
snprintf(buf, sizeof(buf), "%s(keyid=%d %scast addr=" MAC_FMT ")", tag, snprintf(buf, sizeof(buf), "%s(keyid=%d %scast addr=" MAC_FMT ")", tag,
@ -294,11 +294,11 @@ Index: madwifi-dfs-r3280/net80211/ieee80211_linux.c
memset(&wrqu, 0, sizeof(wrqu)); memset(&wrqu, 0, sizeof(wrqu));
wrqu.data.length = strlen(buf); wrqu.data.length = strlen(buf);
wireless_send_event(dev, IWEVCUSTOM, &wrqu, buf); wireless_send_event(dev, IWEVCUSTOM, &wrqu, buf);
Index: madwifi-dfs-r3280/net80211/ieee80211_output.c Index: madwifi-trunk-r3314/net80211/ieee80211_output.c
=================================================================== ===================================================================
--- madwifi-dfs-r3280.orig/net80211/ieee80211_output.c 2008-01-28 17:13:49.000000000 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_output.c 2008-02-20 21:50:40.197096654 +0100
+++ madwifi-dfs-r3280/net80211/ieee80211_output.c 2008-01-28 17:15:06.247663812 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_output.c 2008-02-20 21:55:45.326484992 +0100
@@ -1083,13 +1083,16 @@ @@ -1074,13 +1074,16 @@
cip = (struct ieee80211_cipher *) key->wk_cipher; cip = (struct ieee80211_cipher *) key->wk_cipher;
ciphdrsize = cip->ic_header; ciphdrsize = cip->ic_header;
tailsize += (cip->ic_trailer + cip->ic_miclen); tailsize += (cip->ic_trailer + cip->ic_miclen);
@ -318,11 +318,11 @@ Index: madwifi-dfs-r3280/net80211/ieee80211_output.c
/* /*
* Allocate sk_buff for each subsequent fragment; First fragment * Allocate sk_buff for each subsequent fragment; First fragment
Index: madwifi-dfs-r3280/net80211/ieee80211_node.c Index: madwifi-trunk-r3314/net80211/ieee80211_node.c
=================================================================== ===================================================================
--- madwifi-dfs-r3280.orig/net80211/ieee80211_node.c 2008-01-28 17:14:55.410170040 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_node.c 2008-02-20 21:55:41.318256570 +0100
+++ madwifi-dfs-r3280/net80211/ieee80211_node.c 2008-01-28 17:15:06.351617734 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_node.c 2008-02-20 21:55:45.326484992 +0100
@@ -2259,11 +2259,13 @@ @@ -2261,11 +2261,13 @@
/* From this point onwards we can no longer find the node, /* From this point onwards we can no longer find the node,
* so no more references are generated * so no more references are generated
*/ */

View File

@ -1,8 +1,8 @@
Index: madwifi-trunk-r3280/ath/if_ath.c Index: madwifi-trunk-r3314/ath/if_ath.c
=================================================================== ===================================================================
--- madwifi-trunk-r3280.orig/ath/if_ath.c 2008-01-28 17:30:33.325904012 +0100 --- madwifi-trunk-r3314.orig/ath/if_ath.c 2008-02-20 21:58:41.864545316 +0100
+++ madwifi-trunk-r3280/ath/if_ath.c 2008-01-28 17:31:21.850243393 +0100 +++ madwifi-trunk-r3314/ath/if_ath.c 2008-02-20 21:58:45.732765757 +0100
@@ -1674,8 +1674,6 @@ @@ -1692,8 +1692,6 @@
* get to reality. This value is used in monitor mode and by tools like * get to reality. This value is used in monitor mode and by tools like
* Wireshark and Kismet. * Wireshark and Kismet.
*/ */
@ -11,7 +11,7 @@ Index: madwifi-trunk-r3280/ath/if_ath.c
ATH_RXBUF_LOCK_IRQ(sc); ATH_RXBUF_LOCK_IRQ(sc);
if (sc->sc_rxbufcur == NULL) if (sc->sc_rxbufcur == NULL)
sc->sc_rxbufcur = STAILQ_FIRST(&sc->sc_rxbuf); sc->sc_rxbufcur = STAILQ_FIRST(&sc->sc_rxbuf);
@@ -8868,6 +8866,7 @@ @@ -8959,6 +8957,7 @@
sc->sc_curchan.channel); sc->sc_curchan.channel);
sc->sc_stats.ast_per_calfail++; sc->sc_stats.ast_per_calfail++;
} }
@ -19,7 +19,7 @@ Index: madwifi-trunk-r3280/ath/if_ath.c
ath_hal_process_noisefloor(ah); ath_hal_process_noisefloor(ah);
if (isIQdone == AH_TRUE) { if (isIQdone == AH_TRUE) {
@@ -8936,6 +8935,7 @@ @@ -9027,6 +9026,7 @@
struct ath_softc *sc = dev->priv; struct ath_softc *sc = dev->priv;
(void) ath_chan_set(sc, ic->ic_curchan); (void) ath_chan_set(sc, ic->ic_curchan);
@ -27,7 +27,7 @@ Index: madwifi-trunk-r3280/ath/if_ath.c
/* /*
* If we are returning to our bss channel then mark state * If we are returning to our bss channel then mark state
* so the next recv'd beacon's TSF will be used to sync the * so the next recv'd beacon's TSF will be used to sync the
@@ -9204,6 +9204,7 @@ @@ -9295,6 +9295,7 @@
} }
ath_hal_process_noisefloor(ah); ath_hal_process_noisefloor(ah);

View File

@ -1,8 +1,8 @@
Index: madwifi-dfs-r3246/ath/if_ath.c Index: madwifi-trunk-r3314/ath/if_ath.c
=================================================================== ===================================================================
--- madwifi-dfs-r3246.orig/ath/if_ath.c 2008-01-25 16:37:38.479506279 +0100 --- madwifi-trunk-r3314.orig/ath/if_ath.c 2008-02-20 21:57:55.057877957 +0100
+++ madwifi-dfs-r3246/ath/if_ath.c 2008-01-25 16:38:04.684999652 +0100 +++ madwifi-trunk-r3314/ath/if_ath.c 2008-02-20 21:57:58.494073773 +0100
@@ -1345,7 +1345,7 @@ @@ -1351,7 +1351,7 @@
TAILQ_FOREACH(v, &ic->ic_vaps, iv_next) TAILQ_FOREACH(v, &ic->ic_vaps, iv_next)
id_mask |= (1 << ATH_GET_VAP_ID(v->iv_myaddr)); id_mask |= (1 << ATH_GET_VAP_ID(v->iv_myaddr));

View File

@ -1,7 +1,7 @@
Index: madwifi-trunk-r3280/net80211/ieee80211_beacon.c Index: madwifi-trunk-r3314/net80211/ieee80211_beacon.c
=================================================================== ===================================================================
--- madwifi-trunk-r3280.orig/net80211/ieee80211_beacon.c 2008-01-28 17:27:08.000000000 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_beacon.c 2008-02-20 18:10:45.515108151 +0100
+++ madwifi-trunk-r3280/net80211/ieee80211_beacon.c 2008-01-28 17:32:30.587778482 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_beacon.c 2008-02-20 18:10:50.491391734 +0100
@@ -542,10 +542,10 @@ @@ -542,10 +542,10 @@
vap->iv_flags &= ~IEEE80211_F_XRUPDATE; vap->iv_flags &= ~IEEE80211_F_XRUPDATE;
} }
@ -15,11 +15,11 @@ Index: madwifi-trunk-r3280/net80211/ieee80211_beacon.c
} }
} }
/* if it is a mode change beacon for dynamic turbo case */ /* if it is a mode change beacon for dynamic turbo case */
Index: madwifi-trunk-r3280/net80211/ieee80211_input.c Index: madwifi-trunk-r3314/net80211/ieee80211_input.c
=================================================================== ===================================================================
--- madwifi-trunk-r3280.orig/net80211/ieee80211_input.c 2008-01-28 17:30:33.905937066 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_input.c 2008-02-20 18:10:49.723347963 +0100
+++ madwifi-trunk-r3280/net80211/ieee80211_input.c 2008-01-28 17:31:42.836941957 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_input.c 2008-02-20 18:10:50.495391960 +0100
@@ -3423,9 +3423,12 @@ @@ -3431,9 +3431,12 @@
/* Assume no ERP IE == 11b AP */ /* Assume no ERP IE == 11b AP */
if ((!has_erp || (has_erp && (scan.erp & IEEE80211_ERP_NON_ERP_PRESENT))) && if ((!has_erp || (has_erp && (scan.erp & IEEE80211_ERP_NON_ERP_PRESENT))) &&
!(ic->ic_flags & IEEE80211_F_USEPROT)) { !(ic->ic_flags & IEEE80211_F_USEPROT)) {
@ -33,11 +33,11 @@ Index: madwifi-trunk-r3280/net80211/ieee80211_input.c
} }
} }
Index: madwifi-trunk-r3280/net80211/ieee80211_node.c Index: madwifi-trunk-r3314/net80211/ieee80211_node.c
=================================================================== ===================================================================
--- madwifi-trunk-r3280.orig/net80211/ieee80211_node.c 2008-01-28 17:30:34.525972400 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_node.c 2008-02-20 18:10:49.727348192 +0100
+++ madwifi-trunk-r3280/net80211/ieee80211_node.c 2008-01-28 17:31:42.844938410 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_node.c 2008-02-20 18:10:50.507392644 +0100
@@ -2021,8 +2021,12 @@ @@ -2022,8 +2022,12 @@
} }
/* Update ERP element if this is first non ERP station */ /* Update ERP element if this is first non ERP station */
@ -52,7 +52,7 @@ Index: madwifi-trunk-r3280/net80211/ieee80211_node.c
} else } else
ni->ni_flags |= IEEE80211_NODE_ERP; ni->ni_flags |= IEEE80211_NODE_ERP;
} }
@@ -2225,6 +2229,8 @@ @@ -2226,6 +2230,8 @@
IEEE80211_NOTE(vap, IEEE80211_MSG_ASSOC, ni, IEEE80211_NOTE(vap, IEEE80211_MSG_ASSOC, ni,
"non-ERP station leaves, count now %d", ic->ic_nonerpsta); "non-ERP station leaves, count now %d", ic->ic_nonerpsta);
if (ic->ic_nonerpsta == 0) { if (ic->ic_nonerpsta == 0) {
@ -61,7 +61,7 @@ Index: madwifi-trunk-r3280/net80211/ieee80211_node.c
IEEE80211_DPRINTF(vap, IEEE80211_MSG_ASSOC, IEEE80211_DPRINTF(vap, IEEE80211_MSG_ASSOC,
"%s: disable use of protection\n", __func__); "%s: disable use of protection\n", __func__);
ic->ic_flags &= ~IEEE80211_F_USEPROT; ic->ic_flags &= ~IEEE80211_F_USEPROT;
@@ -2236,7 +2242,9 @@ @@ -2237,7 +2243,9 @@
ic->ic_flags |= IEEE80211_F_SHPREAMBLE; ic->ic_flags |= IEEE80211_F_SHPREAMBLE;
ic->ic_flags &= ~IEEE80211_F_USEBARKER; ic->ic_flags &= ~IEEE80211_F_USEBARKER;
} }

View File

@ -1,8 +1,8 @@
Index: madwifi-dfs-r3252/ath/if_ath.c Index: madwifi-trunk-r3314/ath/if_ath.c
=================================================================== ===================================================================
--- madwifi-dfs-r3252.orig/ath/if_ath.c 2008-01-26 05:46:05.078738026 +0100 --- madwifi-trunk-r3314.orig/ath/if_ath.c 2008-02-20 21:57:58.494073773 +0100
+++ madwifi-dfs-r3252/ath/if_ath.c 2008-01-26 05:46:09.658999042 +0100 +++ madwifi-trunk-r3314/ath/if_ath.c 2008-02-20 21:58:14.318975583 +0100
@@ -8626,6 +8626,10 @@ @@ -8673,6 +8673,10 @@
sc->sc_rxbufcur = NULL; sc->sc_rxbufcur = NULL;

View File

@ -1,7 +1,7 @@
Index: madwifi-dfs-r3252/ath_rate/minstrel/minstrel.c Index: madwifi-trunk-r3314/ath_rate/minstrel/minstrel.c
=================================================================== ===================================================================
--- madwifi-dfs-r3252.orig/ath_rate/minstrel/minstrel.c 2008-01-26 03:42:00.155571408 +0100 --- madwifi-trunk-r3314.orig/ath_rate/minstrel/minstrel.c 2008-02-20 18:10:48.795295077 +0100
+++ madwifi-dfs-r3252/ath_rate/minstrel/minstrel.c 2008-01-26 05:55:24.107535577 +0100 +++ madwifi-trunk-r3314/ath_rate/minstrel/minstrel.c 2008-02-20 18:10:50.951417946 +0100
@@ -328,7 +328,7 @@ @@ -328,7 +328,7 @@
return; return;
} }

View File

@ -1,8 +1,8 @@
Index: madwifi-trunk-r3280/ath/if_ath.c Index: madwifi-trunk-r3314/ath/if_ath.c
=================================================================== ===================================================================
--- madwifi-trunk-r3280.orig/ath/if_ath.c 2008-01-28 18:17:03.786862678 +0100 --- madwifi-trunk-r3314.orig/ath/if_ath.c 2008-02-20 21:58:51.885116355 +0100
+++ madwifi-trunk-r3280/ath/if_ath.c 2008-01-28 18:21:43.162783406 +0100 +++ madwifi-trunk-r3314/ath/if_ath.c 2008-02-20 21:58:53.697219623 +0100
@@ -1754,17 +1754,14 @@ @@ -1771,17 +1771,14 @@
* may have occurred in the intervening timeframe. */ * may have occurred in the intervening timeframe. */
bf->bf_channoise = ic->ic_channoise; bf->bf_channoise = ic->ic_channoise;
@ -27,11 +27,11 @@ Index: madwifi-trunk-r3280/ath/if_ath.c
/* Prepare wireless header for examination */ /* Prepare wireless header for examination */
bus_dma_sync_single(sc->sc_bdev, bf->bf_skbaddr, bus_dma_sync_single(sc->sc_bdev, bf->bf_skbaddr,
Index: madwifi-trunk-r3280/ath/if_ath_radar.c Index: madwifi-trunk-r3314/ath/if_ath_radar.c
=================================================================== ===================================================================
--- madwifi-trunk-r3280.orig/ath/if_ath_radar.c 2008-01-28 18:20:47.859631857 +0100 --- madwifi-trunk-r3314.orig/ath/if_ath_radar.c 2008-02-20 21:58:35.060157557 +0100
+++ madwifi-trunk-r3280/ath/if_ath_radar.c 2008-01-28 18:20:50.915806019 +0100 +++ madwifi-trunk-r3314/ath/if_ath_radar.c 2008-02-20 21:58:53.701219858 +0100
@@ -265,7 +265,7 @@ @@ -263,7 +263,7 @@
unsigned int new_rxfilt = old_rxfilt; unsigned int new_rxfilt = old_rxfilt;
ath_hal_intrset(ah, old_ier & ~HAL_INT_GLOBAL); ath_hal_intrset(ah, old_ier & ~HAL_INT_GLOBAL);

View File

@ -1,7 +1,7 @@
Index: madwifi-trunk-r3314/net80211/ieee80211_input.c Index: madwifi-trunk-r3314/net80211/ieee80211_input.c
=================================================================== ===================================================================
--- madwifi-trunk-r3314.orig/net80211/ieee80211_input.c 2008-01-31 03:33:26.665309039 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_input.c 2008-02-20 18:10:50.495391960 +0100
+++ madwifi-trunk-r3314/net80211/ieee80211_input.c 2008-01-31 03:38:55.116026377 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_input.c 2008-02-20 18:10:51.395443250 +0100
@@ -1275,14 +1275,8 @@ @@ -1275,14 +1275,8 @@
eh->ether_type = ether_type; eh->ether_type = ether_type;

View File

@ -1,8 +1,8 @@
Index: madwifi-trunk-r3280/ath/if_ath.c Index: madwifi-trunk-r3314/ath/if_ath.c
=================================================================== ===================================================================
--- madwifi-trunk-r3280.orig/ath/if_ath.c 2008-01-28 19:00:13.666420256 +0100 --- madwifi-trunk-r3314.orig/ath/if_ath.c 2008-02-20 21:58:53.697219623 +0100
+++ madwifi-trunk-r3280/ath/if_ath.c 2008-01-28 19:01:05.093350913 +0100 +++ madwifi-trunk-r3314/ath/if_ath.c 2008-02-20 21:58:58.545495909 +0100
@@ -9701,7 +9701,9 @@ @@ -9776,7 +9776,9 @@
/* /*
* Convert HAL channels to ieee80211 ones. * Convert HAL channels to ieee80211 ones.
*/ */
@ -12,7 +12,7 @@ Index: madwifi-trunk-r3280/ath/if_ath.c
for (i = 0; i < nchan; i++) { for (i = 0; i < nchan; i++) {
HAL_CHANNEL *c = &chans[i]; HAL_CHANNEL *c = &chans[i];
struct ieee80211_channel *ichan = &ic->ic_channels[i]; struct ieee80211_channel *ichan = &ic->ic_channels[i];
@@ -9728,6 +9730,7 @@ @@ -9803,6 +9805,7 @@
ic->ic_chan_non_occupy[i].tv_sec = 0; ic->ic_chan_non_occupy[i].tv_sec = 0;
ic->ic_chan_non_occupy[i].tv_usec = 0; ic->ic_chan_non_occupy[i].tv_usec = 0;
@ -20,7 +20,7 @@ Index: madwifi-trunk-r3280/ath/if_ath.c
IPRINTF(sc, "Channel %3d (%4d MHz) Max Tx Power %d dBm%s " IPRINTF(sc, "Channel %3d (%4d MHz) Max Tx Power %d dBm%s "
"[%d hw %d reg] Flags%s%s%s%s%s%s%s%s%s%s%s%s%" "[%d hw %d reg] Flags%s%s%s%s%s%s%s%s%s%s%s%s%"
"s%s%s%s%s%s%s%s%s%s%s%s\n", "s%s%s%s%s%s%s%s%s%s%s%s\n",
@@ -9816,6 +9819,7 @@ @@ -9891,6 +9894,7 @@
(c->privFlags & 0x0080 ? (c->privFlags & 0x0080 ?
" PF & (1 << 7)" : "") " PF & (1 << 7)" : "")
); );

View File

@ -1,8 +1,8 @@
Index: madwifi-trunk-r3314/ath/if_ath.c Index: madwifi-trunk-r3314/ath/if_ath.c
=================================================================== ===================================================================
--- madwifi-trunk-r3314.orig/ath/if_ath.c 2008-01-31 03:39:02.140426675 +0100 --- madwifi-trunk-r3314.orig/ath/if_ath.c 2008-02-20 21:58:58.545495909 +0100
+++ madwifi-trunk-r3314/ath/if_ath.c 2008-01-31 03:39:41.360481823 +0100 +++ madwifi-trunk-r3314/ath/if_ath.c 2008-02-20 21:59:01.609670527 +0100
@@ -8357,8 +8357,6 @@ @@ -8423,8 +8423,6 @@
ath_hal_intrset(sc->sc_ah, sc->sc_imask); ath_hal_intrset(sc->sc_ah, sc->sc_imask);
local_irq_restore(flags); local_irq_restore(flags);
@ -11,7 +11,7 @@ Index: madwifi-trunk-r3314/ath/if_ath.c
if (sc->sc_softled) if (sc->sc_softled)
ath_led_event(sc, ATH_LED_TX); ath_led_event(sc, ATH_LED_TX);
} }
@@ -8405,8 +8403,6 @@ @@ -8471,8 +8469,6 @@
ath_hal_intrset(sc->sc_ah, sc->sc_imask); ath_hal_intrset(sc->sc_ah, sc->sc_imask);
local_irq_restore(flags); local_irq_restore(flags);
@ -20,7 +20,7 @@ Index: madwifi-trunk-r3314/ath/if_ath.c
if (sc->sc_softled) if (sc->sc_softled)
ath_led_event(sc, ATH_LED_TX); ath_led_event(sc, ATH_LED_TX);
} }
@@ -8439,8 +8435,6 @@ @@ -8505,8 +8501,6 @@
ath_hal_intrset(sc->sc_ah, sc->sc_imask); ath_hal_intrset(sc->sc_ah, sc->sc_imask);
local_irq_restore(flags); local_irq_restore(flags);
@ -31,8 +31,8 @@ Index: madwifi-trunk-r3314/ath/if_ath.c
} }
Index: madwifi-trunk-r3314/net80211/ieee80211_input.c Index: madwifi-trunk-r3314/net80211/ieee80211_input.c
=================================================================== ===================================================================
--- madwifi-trunk-r3314.orig/net80211/ieee80211_input.c 2008-01-31 03:38:55.116026377 +0100 --- madwifi-trunk-r3314.orig/net80211/ieee80211_input.c 2008-02-20 21:58:57.425432087 +0100
+++ madwifi-trunk-r3314/net80211/ieee80211_input.c 2008-01-31 03:39:41.364480053 +0100 +++ madwifi-trunk-r3314/net80211/ieee80211_input.c 2008-02-20 21:59:01.613670756 +0100
@@ -1132,7 +1132,7 @@ @@ -1132,7 +1132,7 @@
(vap->iv_flags & IEEE80211_F_NOBRIDGE) == 0) { (vap->iv_flags & IEEE80211_F_NOBRIDGE) == 0) {
struct sk_buff *skb1 = NULL; struct sk_buff *skb1 = NULL;

View File

@ -1,10 +1,10 @@
Index: madwifi-trunk-r3314/ath/if_ath.c Index: madwifi-trunk-r3314/ath/if_ath.c
=================================================================== ===================================================================
--- madwifi-trunk-r3314.orig/ath/if_ath.c 2008-01-31 03:59:25.474330368 +0100 --- madwifi-trunk-r3314.orig/ath/if_ath.c 2008-02-20 21:59:01.609670527 +0100
+++ madwifi-trunk-r3314/ath/if_ath.c 2008-01-31 04:00:30.254021949 +0100 +++ madwifi-trunk-r3314/ath/if_ath.c 2008-02-20 21:59:04.037808900 +0100
@@ -6686,8 +6686,9 @@ @@ -6752,8 +6752,9 @@
*budget -= processed; *budget -= processed;
#endif
- /* rx signal state monitoring */ - /* rx signal state monitoring */
- ath_hal_rxmonitor(ah, &sc->sc_halstats, &sc->sc_curchan); - ath_hal_rxmonitor(ah, &sc->sc_halstats, &sc->sc_curchan);

View File

@ -1,245 +0,0 @@
Index: madwifi-trunk-r3314/ath/if_ath.c
===================================================================
--- madwifi-trunk-r3314.orig/ath/if_ath.c 2008-02-11 19:10:30.010051203 +0100
+++ madwifi-trunk-r3314/ath/if_ath.c 2008-02-11 19:18:00.615729758 +0100
@@ -184,7 +184,11 @@
struct sk_buff *, int, int, u_int64_t);
static void ath_setdefantenna(struct ath_softc *, u_int);
static struct ath_txq *ath_txq_setup(struct ath_softc *, int, int);
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+static int ath_rx_poll(struct napi_struct *napi, int budget);
+#else
static int ath_rx_poll(struct net_device *dev, int *budget);
+#endif
static int ath_hardstart(struct sk_buff *, struct net_device *);
static int ath_mgtstart(struct ieee80211com *, struct sk_buff *);
#ifdef ATH_SUPERG_COMP
@@ -374,6 +378,9 @@
u_int32_t new_clamped_maxtxpower);
static u_int32_t ath_get_real_maxtxpower(struct ath_softc *sc);
+static void ath_poll_disable(struct net_device *dev);
+static void ath_poll_enable(struct net_device *dev);
+
/* calibrate every 30 secs in steady state but check every second at first. */
static int ath_calinterval = ATH_SHORT_CALINTERVAL;
static int ath_countrycode = CTRY_DEFAULT; /* country code */
@@ -818,8 +825,12 @@
dev->set_mac_address = ath_set_mac_address;
dev->change_mtu = ath_change_mtu;
dev->tx_queue_len = ATH_TXBUF - ATH_TXBUF_MGT_RESERVED;
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+ netif_napi_add(dev, &sc->sc_napi, ath_rx_poll, 64);
+#else
dev->poll = ath_rx_poll;
dev->weight = 64;
+#endif
#ifdef USE_HEADERLEN_RESV
dev->hard_header_len += sizeof(struct ieee80211_qosframe) +
sizeof(struct llc) +
@@ -2268,12 +2279,21 @@
if (status & (HAL_INT_RX | HAL_INT_RXPHY)) {
ath_uapsd_processtriggers(sc, hw_tsf);
sc->sc_isr &= ~HAL_INT_RX;
- if (netif_rx_schedule_prep(dev)) {
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+ if (netif_rx_schedule_prep(dev, &sc->sc_napi))
+#else
+ if (netif_rx_schedule_prep(dev))
+#endif
+ {
#ifndef ATH_PRECISE_TSF
sc->sc_imask &= ~HAL_INT_RX;
ath_hal_intrset(ah, sc->sc_imask);
#endif
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+ __netif_rx_schedule(dev, &sc->sc_napi);
+#else
__netif_rx_schedule(dev);
+#endif
}
}
if (status & HAL_INT_TX) {
@@ -2517,6 +2537,7 @@
if (sc->sc_tx99 != NULL)
sc->sc_tx99->start(sc->sc_tx99);
#endif
+ ath_poll_enable(dev);
done:
ATH_UNLOCK(sc);
@@ -2557,6 +2578,9 @@
if (sc->sc_tx99 != NULL)
sc->sc_tx99->stop(sc->sc_tx99);
#endif
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+ ath_poll_disable(dev);
+#endif
netif_stop_queue(dev); /* XXX re-enabled by ath_newstate */
dev->flags &= ~IFF_RUNNING; /* NB: avoid recursion */
ieee80211_stop_running(ic); /* stop all VAPs */
@@ -4015,6 +4039,39 @@
return ath_keyset(sc, k, mac, vap->iv_bss);
}
+static void ath_poll_disable(struct net_device *dev)
+{
+ struct ath_softc *sc = dev->priv;
+
+ /*
+ * XXX Using in_softirq is not right since we might
+ * be called from other soft irq contexts than
+ * ath_rx_poll
+ */
+ if (!in_softirq()) {
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+ napi_disable(&sc->sc_napi);
+#else
+ netif_poll_disable(dev);
+#endif
+ }
+}
+
+static void ath_poll_enable(struct net_device *dev)
+{
+ struct ath_softc *sc = dev->priv;
+
+ /* NB: see above */
+ if (!in_softirq()) {
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+ napi_enable(&sc->sc_napi);
+#else
+ netif_poll_enable(dev);
+#endif
+ }
+}
+
+
/*
* Block/unblock tx+rx processing while a key change is done.
* We assume the caller serializes key management operations
@@ -4032,13 +4089,8 @@
* When called from the rx tasklet we cannot use
* tasklet_disable because it will block waiting
* for us to complete execution.
- *
- * XXX Using in_softirq is not right since we might
- * be called from other soft irq contexts than
- * ath_rx_poll
*/
- if (!in_softirq())
- netif_poll_disable(dev);
+ ath_poll_disable(dev);
netif_stop_queue(dev);
}
@@ -4050,8 +4102,7 @@
DPRINTF(sc, ATH_DEBUG_KEYCACHE, "End\n");
netif_wake_queue(dev);
- if (!in_softirq()) /* NB: see above */
- netif_poll_enable(dev);
+ ath_poll_enable(dev);
}
/*
@@ -6359,24 +6410,34 @@
}
static int
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+ath_rx_poll(struct napi_struct *napi, int budget)
+#else
ath_rx_poll(struct net_device *dev, int *budget)
+#endif
{
#define PA2DESC(_sc, _pa) \
((struct ath_desc *)((caddr_t)(_sc)->sc_rxdma.dd_desc + \
((_pa) - (_sc)->sc_rxdma.dd_desc_paddr)))
- struct ath_buf *bf;
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+ struct ath_softc *sc = container_of(napi, struct ath_softc, sc_napi);
+ struct net_device *dev = sc->sc_dev;
+ u_int rx_limit = budget;
+#else
struct ath_softc *sc = dev->priv;
+ u_int rx_limit = dev->quota;
+#endif
struct ieee80211com *ic = &sc->sc_ic;
struct ath_hal *ah = sc ? sc->sc_ah : NULL;
struct ath_desc *ds;
struct ath_rx_status *rs;
struct sk_buff *skb = NULL;
struct ieee80211_node *ni;
+ struct ath_buf *bf;
unsigned int len;
int type;
u_int phyerr;
u_int processed = 0, early_stop = 0;
- u_int rx_limit = dev->quota;
u_int mic_fail = 0;
DPRINTF(sc, ATH_DEBUG_RX_PROC, "invoked\n");
@@ -6405,7 +6466,9 @@
break;
}
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
processed++;
+#endif
if (rx_limit-- < 0) {
early_stop = 1;
break;
@@ -6675,8 +6738,6 @@
goto process_rx_again;
}
#endif
- netif_rx_complete(dev);
-
#ifndef ATH_PRECISE_TSF
sc->sc_imask |= HAL_INT_RX;
ath_hal_intrset(ah, sc->sc_imask);
@@ -6684,11 +6745,17 @@
#endif
}
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+ netif_rx_complete(dev, napi);
+#else
+ netif_rx_complete(dev);
*budget -= processed;
+#endif
/* rx signal state monitoring, only necessary/applicable for sta mode */
if (sc->sc_opmode == HAL_M_STA)
ath_hal_rxmonitor(ah, &sc->sc_halstats, &sc->sc_curchan);
+
return early_stop;
#undef PA2DESC
}
@@ -10378,9 +10445,9 @@
dev->mtu = mtu;
if ((dev->flags & IFF_RUNNING) && !sc->sc_invalid) {
/* NB: the rx buffers may need to be reallocated */
- netif_poll_disable(dev);
+ ath_poll_disable(dev);
error = ath_reset(dev);
- netif_poll_enable(dev);
+ ath_poll_enable(dev);
}
ATH_UNLOCK(sc);
Index: madwifi-trunk-r3314/ath/if_athvar.h
===================================================================
--- madwifi-trunk-r3314.orig/ath/if_athvar.h 2008-02-11 19:10:29.758036841 +0100
+++ madwifi-trunk-r3314/ath/if_athvar.h 2008-02-11 19:17:35.042272406 +0100
@@ -620,6 +620,9 @@
struct ath_softc {
struct ieee80211com sc_ic; /* NB: must be first */
struct net_device *sc_dev;
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24)
+ struct napi_struct sc_napi;
+#endif
void __iomem *sc_iobase; /* address of the device */
struct semaphore sc_lock; /* dev-level lock */
struct net_device_stats sc_devstats; /* device statistics */

View File

@ -1,7 +1,7 @@
Index: madwifi-trunk-r3314/ath/if_ath.c Index: madwifi-trunk-r3314/ath/if_ath.c
=================================================================== ===================================================================
--- madwifi-trunk-r3314.orig/ath/if_ath.c 2008-02-17 18:37:14.134402305 +0100 --- madwifi-trunk-r3314.orig/ath/if_ath.c 2008-02-20 21:59:04.037808900 +0100
+++ madwifi-trunk-r3314/ath/if_ath.c 2008-02-17 22:09:52.078681699 +0100 +++ madwifi-trunk-r3314/ath/if_ath.c 2008-02-20 21:59:07.426001981 +0100
@@ -395,6 +395,7 @@ @@ -395,6 +395,7 @@
static int maxvaps = -1; static int maxvaps = -1;
static int outdoor = -1; static int outdoor = -1;
@ -100,7 +100,7 @@ Index: madwifi-trunk-r3314/ath/if_ath.c
#ifdef ATH_SUPERG_DYNTURBO #ifdef ATH_SUPERG_DYNTURBO
ath_beacon_dturbo_config(vap, intval & ath_beacon_dturbo_config(vap, intval &
~(HAL_BEACON_RESET_TSF | HAL_BEACON_ENA)); ~(HAL_BEACON_RESET_TSF | HAL_BEACON_ENA));
@@ -8865,6 +8895,9 @@ @@ -8864,6 +8894,9 @@
/* Enter DFS wait period */ /* Enter DFS wait period */
mod_timer(&sc->sc_dfs_cac_timer, mod_timer(&sc->sc_dfs_cac_timer,
jiffies + (sc->sc_dfs_cac_period * HZ)); jiffies + (sc->sc_dfs_cac_period * HZ));
@ -110,7 +110,7 @@ Index: madwifi-trunk-r3314/ath/if_ath.c
} }
/* /*
* re configure beacons when it is a turbo mode switch. * re configure beacons when it is a turbo mode switch.
@@ -8974,8 +9007,11 @@ @@ -8973,8 +9006,11 @@
sc->sc_curchan.channel, sc->sc_curchan.channelFlags, sc->sc_curchan.channel, sc->sc_curchan.channelFlags,
isIQdone ? "done" : "not done"); isIQdone ? "done" : "not done");
@ -124,7 +124,7 @@ Index: madwifi-trunk-r3314/ath/if_ath.c
} }
static void static void
@@ -9082,7 +9118,8 @@ @@ -9081,7 +9117,8 @@
ieee80211_state_name[vap->iv_state], ieee80211_state_name[vap->iv_state],
ieee80211_state_name[nstate]); ieee80211_state_name[nstate]);
@ -134,7 +134,7 @@ Index: madwifi-trunk-r3314/ath/if_ath.c
ath_hal_setledstate(ah, leds[nstate]); /* set LED */ ath_hal_setledstate(ah, leds[nstate]); /* set LED */
netif_stop_queue(dev); /* before we do anything else */ netif_stop_queue(dev); /* before we do anything else */
@@ -9307,7 +9344,8 @@ @@ -9306,7 +9343,8 @@
"VAP -> DFSWAIT_PENDING \n"); "VAP -> DFSWAIT_PENDING \n");
/* start calibration timer with a really small value /* start calibration timer with a really small value
* 1/10 sec */ * 1/10 sec */
@ -144,7 +144,7 @@ Index: madwifi-trunk-r3314/ath/if_ath.c
/* wake the receiver */ /* wake the receiver */
netif_wake_queue(dev); netif_wake_queue(dev);
/* don't do the other usual stuff... */ /* don't do the other usual stuff... */
@@ -9350,7 +9388,7 @@ @@ -9349,7 +9387,7 @@
error = avp->av_newstate(vap, nstate, arg); error = avp->av_newstate(vap, nstate, arg);
/* Finally, start any timers. */ /* Finally, start any timers. */
@ -155,8 +155,8 @@ Index: madwifi-trunk-r3314/ath/if_ath.c
} }
Index: madwifi-trunk-r3314/ath/if_athvar.h Index: madwifi-trunk-r3314/ath/if_athvar.h
=================================================================== ===================================================================
--- madwifi-trunk-r3314.orig/ath/if_athvar.h 2008-02-17 18:37:14.134402305 +0100 --- madwifi-trunk-r3314.orig/ath/if_athvar.h 2008-02-20 21:58:38.148333545 +0100
+++ madwifi-trunk-r3314/ath/if_athvar.h 2008-02-17 22:08:35.966344301 +0100 +++ madwifi-trunk-r3314/ath/if_athvar.h 2008-02-20 21:59:07.426001981 +0100
@@ -778,6 +778,8 @@ @@ -778,6 +778,8 @@
struct ieee80211vap **sc_bslot; /* beacon xmit slots */ struct ieee80211vap **sc_bslot; /* beacon xmit slots */
int sc_bnext; /* next slot for beacon xmit */ int sc_bnext; /* next slot for beacon xmit */

View File

@ -1,8 +1,8 @@
Index: madwifi-trunk-r3314/ath/if_ath.c Index: madwifi-trunk-r3314/ath/if_ath.c
=================================================================== ===================================================================
--- madwifi-trunk-r3314.orig/ath/if_ath.c 2008-02-08 04:11:11.775823441 +0100 --- madwifi-trunk-r3314.orig/ath/if_ath.c 2008-02-20 18:10:52.499506168 +0100
+++ madwifi-trunk-r3314/ath/if_ath.c 2008-02-08 05:46:16.761139918 +0100 +++ madwifi-trunk-r3314/ath/if_ath.c 2008-02-20 18:10:52.731519391 +0100
@@ -3308,17 +3308,18 @@ @@ -3315,17 +3315,18 @@
* without affecting any other bridge ports. */ * without affecting any other bridge ports. */
if (skb_cloned(skb)) { if (skb_cloned(skb)) {
/* Remember the original SKB so we can free up our references */ /* Remember the original SKB so we can free up our references */
@ -27,7 +27,7 @@ Index: madwifi-trunk-r3314/ath/if_ath.c
eh = (struct ether_header *)skb->data; eh = (struct ether_header *)skb->data;
#ifdef ATH_SUPERG_FF #ifdef ATH_SUPERG_FF
@@ -3584,11 +3585,13 @@ @@ -3591,11 +3592,13 @@
*/ */
error = ath_tx_start(dev, SKB_CB(skb)->ni, bf, skb, 0); error = ath_tx_start(dev, SKB_CB(skb)->ni, bf, skb, 0);
if (error) if (error)