From owner-freebsd-bugs@FreeBSD.ORG Thu Dec 30 14:20:11 2010 Return-Path: Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 68106106566B for ; Thu, 30 Dec 2010 14:20:11 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 2B4E98FC19 for ; Thu, 30 Dec 2010 14:20:11 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id oBUEKBdo063142 for ; Thu, 30 Dec 2010 14:20:11 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id oBUEKBq9063141; Thu, 30 Dec 2010 14:20:11 GMT (envelope-from gnats) Resent-Date: Thu, 30 Dec 2010 14:20:11 GMT Resent-Message-Id: <201012301420.oBUEKBq9063141@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Erik Fonnesbeck Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7962A106566B for ; Thu, 30 Dec 2010 14:12:08 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from red.freebsd.org (unknown [IPv6:2001:4f8:fff6::22]) by mx1.freebsd.org (Postfix) with ESMTP id 68F1D8FC08 for ; Thu, 30 Dec 2010 14:12:08 +0000 (UTC) Received: from red.freebsd.org (localhost [127.0.0.1]) by red.freebsd.org (8.14.4/8.14.4) with ESMTP id oBUEC8v7094496 for ; Thu, 30 Dec 2010 14:12:08 GMT (envelope-from nobody@red.freebsd.org) Received: (from nobody@localhost) by red.freebsd.org (8.14.4/8.14.4/Submit) id oBUEC8AI094495; Thu, 30 Dec 2010 14:12:08 GMT (envelope-from nobody) Message-Id: <201012301412.oBUEC8AI094495@red.freebsd.org> Date: Thu, 30 Dec 2010 14:12:08 GMT From: Erik Fonnesbeck To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Cc: Subject: kern/153549: [patch] [mwl] Fix for incorrect limit on number of virtual access points X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 30 Dec 2010 14:20:11 -0000 >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: