From owner-freebsd-wireless@FreeBSD.ORG Mon Dec 10 10:50:26 2012 Return-Path: Delivered-To: freebsd-wireless@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 8E0B38F9 for ; Mon, 10 Dec 2012 10:50:26 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: from mail-we0-f182.google.com (mail-we0-f182.google.com [74.125.82.182]) by mx1.freebsd.org (Postfix) with ESMTP id 16B288FC15 for ; Mon, 10 Dec 2012 10:50:25 +0000 (UTC) Received: by mail-we0-f182.google.com with SMTP id u54so1421170wey.13 for ; Mon, 10 Dec 2012 02:50:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=K3/95B6mmBpFeldM8eQ5rg9rGU2ZLCvgwnAHaxF+0jY=; b=kbdACxRgm/FndqOOcBto4wyB7X8QQ+UFdqvcJb8BpuNEWCYZwwYKHeKAuSmW4jDe8e jRn1e4aa3O3pYFuHdcQTRInBHtH0BisRHizSYuNxQZbK+ExY8AiwsS4DDg1/90XWSsNs hpPq4kjZKlIRmcr50xyUoo+DWdSaEu+C0LKziUMykY/1NpjtHjdj0z8cXo1sQ8hbSIUl ZeL7XEGBe8iszPCRgn1ufijqtgZEBAz9MGw/6DubH0+GgIqXwG8xEVSd8SmQOvj+kRrk FIl4VM6OrXmVE+Un1ydx4AHhUATHjJuY5uP2nDuaeTBhY0/zyt5wYv0sGXQu2ZXN+8Lz uA8Q== MIME-Version: 1.0 Received: by 10.180.103.106 with SMTP id fv10mr9885011wib.19.1355136625043; Mon, 10 Dec 2012 02:50:25 -0800 (PST) Sender: adrian.chadd@gmail.com Received: by 10.217.57.9 with HTTP; Mon, 10 Dec 2012 02:50:24 -0800 (PST) In-Reply-To: References: <201210180934.48741.jhugo@meraka.csir.co.za> Date: Mon, 10 Dec 2012 02:50:24 -0800 X-Google-Sender-Auth: 92F36AWOgoWUFmvKreqs6Ubh9Bs Message-ID: Subject: Re: 11n in adhoc mode From: Adrian Chadd To: Johann Hugo Content-Type: text/plain; charset=ISO-8859-1 Cc: freebsd-wireless@freebsd.org X-BeenThere: freebsd-wireless@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Discussions of 802.11 stack, tools device driver development." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 10 Dec 2012 10:50:26 -0000 Ok, wow. I think I finally understand the level of "huh?" going on here. When a new BSS is created, everything now works out great. It creates a BSS, the channel is promoted to 11n correctly, it gets the 11n IE's populated, etc. When you're joining a BSS however, it doesn't do any of this. adhoc_pick_bss() calls ieee80211_sta_join() to the BSS, which populates a vap node to that peer with a very, very bare minimum config. There's no HT info there at all. But since it's done the basic node setup, the normal discovery path (ie, BSS RX, BSS beacon RX) doesn't see this particular node as a 'new' node. Now, I hacked up the HT rate and node setup into adhoc_pick_bss() to setup the BSS node like this and it works; enough to have both sides setup the MCS rate tables and negotiate 11n right. They don't successfully negotiate ADDBA, but that's some funny race crap I'll deal with later (I'm doing it all on a single laptop with two ath NICs, using vimage. Yes, evil.) Anyway. I think I'm getting slightly closer to making 11n adhoc mode work. I may need some help (Bernhard?) on figuring out a cleaner way to "join" an existing BSS, instead of how it's currently done. Also, Bernhard - why don't we do all the IE setup in ieee80211_sta_join() ? Thanks, Adrian