Date: Thu, 30 Dec 2010 14:12:08 GMT From: Erik Fonnesbeck <efonnes@gmail.com> To: freebsd-gnats-submit@FreeBSD.org Subject: kern/153549: [patch] [mwl] Fix for incorrect limit on number of virtual access points Message-ID: <201012301412.oBUEC8AI094495@red.freebsd.org> Resent-Message-ID: <201012301420.oBUEKBq9063141@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 153549
>Category: kern
>Synopsis: [patch] [mwl] Fix for incorrect limit on number of virtual access points
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: sw-bug
>Submitter-Id: current-users
>Arrival-Date: Thu Dec 30 14:20:10 UTC 2010
>Closed-Date:
>Last-Modified:
>Originator: Erik Fonnesbeck
>Release: all versions are affected
>Organization:
>Environment:
not applicable
>Description:
mwl's source code says it should only allow 8 virtual access points, but a bug in the initialization code makes it allow 16.
>How-To-Repeat:
Attempt to create more than 8 virtual access points and it allows it.
>Fix:
During initialization there is an incorrect condition on a for loop that does initialization for stations, leaving 8 of them uninitialized and causing the driver to think those 8 entries are for access points. Patch enclosed.
Patch attached with submission follows:
--- /usr/src/sys/dev/mwl/mwlhal.c.old 2010-06-23 14:50:59.000000000 -0600
+++ /usr/src/sys/dev/mwl/mwlhal.c 2010-12-30 03:53:57.000000000 -0700
@@ -279,7 +279,7 @@
hvap->vap_type = MWL_HAL_STA;
hvap->bss_type = htole16(WL_MAC_TYPE_PRIMARY_CLIENT);
hvap->macid = i;
- for (i++; i < MWL_MBSS_STA_MAX; i++) {
+ for (i++; i < MWL_MBSS_AP_MAX+MWL_MBSS_STA_MAX; i++) {
hvap = &mh->mh_vaps[i];
hvap->vap_type = MWL_HAL_STA;
hvap->bss_type = htole16(WL_MAC_TYPE_SECONDARY_CLIENT);
>Release-Note:
>Audit-Trail:
>Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201012301412.oBUEC8AI094495>
