From patchwork Mon Jun 20 08:15:35 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Mohammed Shafi X-Patchwork-Id: 896302 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.4) with ESMTP id p5K8Fuut030920 for ; Mon, 20 Jun 2011 08:15:57 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751839Ab1FTIPi (ORCPT ); Mon, 20 Jun 2011 04:15:38 -0400 Received: from mail-ww0-f44.google.com ([74.125.82.44]:52570 "EHLO mail-ww0-f44.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750851Ab1FTIPh convert rfc822-to-8bit (ORCPT ); Mon, 20 Jun 2011 04:15:37 -0400 Received: by wwe5 with SMTP id 5so2283407wwe.1 for ; Mon, 20 Jun 2011 01:15:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=3D0f21XPM98bfc7nPFb5RnxNWLOtP+IJJO/0Baaomfk=; b=i4ey22acK6x1ZQrHxtvsOTMMRo9dFKBJ6+oMv3lSgQ+aMC+12RBxHoHNDOcoJaH9JU 8iHMFUeJuDkNohRVv34ZTxCVhSAEEr8TEk4AWnjKgzyuEG7sxGYPm9OdlGpYwtA08VUo A8/iMIV9+q/pk3yEBPMlwf7MVwF4aAaYITiaI= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=H3gTmoR78fM3h1bSyKe7ShpQ8t4wvg7MaHZGp5Mvpo9n8HEgLyApou4qRDCAUrXNBP YdG+lP9e4Mb+3R+5O/0BpTNiIqrvT+BFo1opTlt5vImliusgzDt9KTlPkYeZ1TuX3vEp hXvFEM0hh3UaeCNUWauOOGMVvslEuWYGzWt/w= MIME-Version: 1.0 Received: by 10.227.128.138 with SMTP id k10mr4596356wbs.82.1308557735687; Mon, 20 Jun 2011 01:15:35 -0700 (PDT) Received: by 10.227.28.89 with HTTP; Mon, 20 Jun 2011 01:15:35 -0700 (PDT) In-Reply-To: References: Date: Mon, 20 Jun 2011 13:45:35 +0530 Message-ID: Subject: Re: [ath9k-devel] Patching ath9k/mac80211 to change MAC layer features From: Mohammed Shafi To: Fred Matthews Cc: linux-kernel@vger.kernel.org, linux-wireless@vger.kernel.org, ath9k-devel@venema.h4ckr.net, ath9k-devel@lists.ath9k Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Mon, 20 Jun 2011 08:15:58 +0000 (UTC) On Fri, Jun 17, 2011 at 2:09 AM, Fred Matthews wrote: > Hello all, > > > I have a query regarding patching ath9k/mac80211 to change MAC layer > features and I would be most grateful if someone can assist. > > > I need to patch ath9k so that I can be able to modify/fix the A-MPDU > aggregation frame length and other parameters such that they can be > configured at runtime via debugfs. I made a newbie attempt at trying to > change the aggregate length (attached), but I am unsure of the > correctness/efficiency  - when applied throughput varies with different > frame lengths entered but I can't be sure if its actually changing the > aggregation length (passes the framelen/aggr_limit). Hence I would be very > grateful if someone can assist in the correct way of doing this (possibly > directly via mac80211). > > > > Also if the ampdu aggregate length is changed I believe the number/length of > the subframes of the aggregate stays constant (at the default which is > 32). I try to change this in my patch as well as the maximum software > retries by just changing the default definition in ath9k.h, thus is there a > (more) correct/better way of changing these. Finally, how can I patch the > driver to be able to disable Block-Acks/aggregation via debugfs or > otherwise. to disable aggregation in the driver, please try this > > > > I highly appreciate, help in any of the above, as well as other advice, > Many thanks > > _______________________________________________ > ath9k-devel mailing list > ath9k-devel@lists.ath9k.org > https://lists.ath9k.org/mailman/listinfo/ath9k-devel > > diff --git a/drivers/net/wireless/ath/ath9k/init.c b/drivers/net/wireless/ath/ath9k/init.c index d4b166c..e0175d0 100644 --- a/drivers/net/wireless/ath/ath9k/init.c +++ b/drivers/net/wireless/ath/ath9k/init.c @@ -524,8 +524,6 @@ static void ath9k_init_misc(struct ath_softc *sc) sc->config.txpowlimit = ATH_TXPOWER_MAX; if (sc->sc_ah->caps.hw_caps & ATH9K_HW_CAP_HT) { - sc->sc_flags |= SC_OP_TXAGGR; - sc->sc_flags |= SC_OP_RXAGGR; } common->tx_chainmask = sc->sc_ah->caps.tx_chainmask; if you want only tx-aggregation to be disabled , please comment out only that. also you can completely disable HT by diff --git a/drivers/net/wireless/ath/ath9k/hw.c b/drivers/net/wireless/ath/ath9k/hw.c index 6de2655..696b4cc 100644 --- a/drivers/net/wireless/ath/ath9k/hw.c +++ b/drivers/net/wireless/ath/ath9k/hw.c @@ -1915,10 +1915,7 @@ int ath9k_hw_fill_cap_info(struct ath_hw *ah) common->crypt_caps |= ATH_CRYPT_CAP_CIPHER_AESCCM; - if (ah->hw_version.devid != AR2427_DEVID_PCIE) - pCap->hw_caps |= ATH9K_HW_CAP_HT; - else - pCap->hw_caps &= ~ATH9K_HW_CAP_HT; + pCap->hw_caps &= ~ATH9K_HW_CAP_HT; if (AR_SREV_9271(ah)) pCap->num_gpio_pins = AR9271_NUM_GPIO;