From patchwork Thu Dec 31 13:37:55 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kalle Valo X-Patchwork-Id: 70388 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.2) with ESMTP id nBVDcG2H002586 for ; Thu, 31 Dec 2009 13:38:16 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752349AbZLaNiP (ORCPT ); Thu, 31 Dec 2009 08:38:15 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752339AbZLaNiP (ORCPT ); Thu, 31 Dec 2009 08:38:15 -0500 Received: from smtp.nokia.com ([192.100.105.134]:26140 "EHLO mgw-mx09.nokia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752328AbZLaNiO (ORCPT ); Thu, 31 Dec 2009 08:38:14 -0500 Received: from esebh106.NOE.Nokia.com (esebh106.ntc.nokia.com [172.21.138.213]) by mgw-mx09.nokia.com (Switch-3.3.3/Switch-3.3.3) with ESMTP id nBVDboTl023526; Thu, 31 Dec 2009 07:38:00 -0600 Received: from vaebh104.NOE.Nokia.com ([10.160.244.30]) by esebh106.NOE.Nokia.com with Microsoft SMTPSVC(6.0.3790.3959); Thu, 31 Dec 2009 15:37:57 +0200 Received: from mgw-sa02.ext.nokia.com ([147.243.1.48]) by vaebh104.NOE.Nokia.com over TLS secured channel with Microsoft SMTPSVC(6.0.3790.3959); Thu, 31 Dec 2009 15:37:57 +0200 Received: from [127.0.1.1] (essapo-nirac253202.europe.nokia.com [10.162.253.202]) by mgw-sa02.ext.nokia.com (Switch-3.3.3/Switch-3.3.3) with ESMTP id nBVDbuEc027606; Thu, 31 Dec 2009 15:37:56 +0200 Subject: [RFC PATCH v5 7/7] wl1251: add U-APSD support To: linux-wireless@vger.kernel.org From: Kalle Valo Cc: johannes@sipsolutions.net, a.young.jason@gmail.com Date: Thu, 31 Dec 2009 15:37:55 +0200 Message-ID: <20091231133755.29899.84955.stgit@tikku> In-Reply-To: <20091231133626.29899.95683.stgit@tikku> References: <20091231133626.29899.95683.stgit@tikku> User-Agent: StGit/0.15 MIME-Version: 1.0 X-OriginalArrivalTime: 31 Dec 2009 13:37:57.0698 (UTC) FILETIME=[769AAA20:01CA8A1E] X-Nokia-AV: Clean Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org diff --git a/drivers/net/wireless/wl12xx/wl1251_main.c b/drivers/net/wireless/wl12xx/wl1251_main.c index 4cf3545..6be50aa 100644 --- a/drivers/net/wireless/wl12xx/wl1251_main.c +++ b/drivers/net/wireless/wl12xx/wl1251_main.c @@ -1307,6 +1307,7 @@ static struct ieee80211_channel wl1251_channels[] = { static int wl1251_op_conf_tx(struct ieee80211_hw *hw, u16 queue, const struct ieee80211_tx_queue_params *params) { + enum wl1251_acx_ps_scheme ps_scheme; struct wl1251 *wl = hw->priv; int ret; @@ -1324,10 +1325,14 @@ static int wl1251_op_conf_tx(struct ieee80211_hw *hw, u16 queue, if (ret < 0) goto out_sleep; + if (params->uapsd) + ps_scheme = WL1251_ACX_PS_SCHEME_UPSD_TRIGGER; + else + ps_scheme = WL1251_ACX_PS_SCHEME_LEGACY; + ret = wl1251_acx_tid_cfg(wl, wl1251_tx_get_queue(queue), CHANNEL_TYPE_EDCF, - wl1251_tx_get_queue(queue), - WL1251_ACX_PS_SCHEME_LEGACY, + wl1251_tx_get_queue(queue), ps_scheme, WL1251_ACX_ACK_POLICY_LEGACY); if (ret < 0) goto out_sleep; @@ -1401,7 +1406,8 @@ int wl1251_init_ieee80211(struct wl1251 *wl) wl->hw->flags = IEEE80211_HW_SIGNAL_DBM | IEEE80211_HW_NOISE_DBM | IEEE80211_HW_SUPPORTS_PS | - IEEE80211_HW_BEACON_FILTER; + IEEE80211_HW_BEACON_FILTER | + IEEE80211_HW_SUPPORTS_UAPSD; wl->hw->wiphy->interface_modes = BIT(NL80211_IFTYPE_STATION); wl->hw->wiphy->max_scan_ssids = 1;