From patchwork Wed May 18 18:25:18 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ivo van Doorn X-Patchwork-Id: 794432 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id p4IIQeCu002329 for ; Wed, 18 May 2011 18:26:40 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933431Ab1ERS0i (ORCPT ); Wed, 18 May 2011 14:26:38 -0400 Received: from mail-ew0-f46.google.com ([209.85.215.46]:33255 "EHLO mail-ew0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932709Ab1ERS0i (ORCPT ); Wed, 18 May 2011 14:26:38 -0400 Received: by mail-ew0-f46.google.com with SMTP id 4so526998ewy.19 for ; Wed, 18 May 2011 11:26:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:from:to:subject:date:user-agent:cc:references :in-reply-to:mime-version:message-id:content-type :content-transfer-encoding; bh=+2AqS5qmyc3iqE/kdAFRbOc2aqpOXAZ3UcwrKBhLQAg=; b=itq1okCU0Nb8bmMjlzrzj7nVh3zJ/dRnMBz9fdpJQdhslCNWJY3yc8rQBGjHcHImXT jUmRHLPNtWY+/8NIDhoqP7aPsv+2aW0fQoKZ7y7CCjPt2lT+bw/jrraQb5IMxLRI6KJt X01bOv4C7TXSHneMWChczuPpwdQzOx0ZVOtXc= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:subject:date:user-agent:cc:references:in-reply-to :mime-version:message-id:content-type:content-transfer-encoding; b=MaH+6MzIuWewrVNsG6R5MPrKWAChurifD2guM1ymx4fZ72UADVVGhCca3R2tzgnhqx spfOUUcnU9DGXIgZHKja02X1dy3yKkhMx3PQ2JbPoq5F63l0Woxas1q+Cl4628EuiU4v GKWsiuALgkbYYXSQ8mL+b1xv9TOGCXJk+E9J4= Received: by 10.213.108.66 with SMTP id e2mr315389ebp.133.1305743197371; Wed, 18 May 2011 11:26:37 -0700 (PDT) Received: from localhost.localdomain (g121037.upc-g.chello.nl [80.57.121.37]) by mx.google.com with ESMTPS id 34sm1354242eee.1.2011.05.18.11.26.34 (version=SSLv3 cipher=OTHER); Wed, 18 May 2011 11:26:36 -0700 (PDT) From: Ivo van Doorn To: "John W. Linville" Subject: [PATCH 2/7] rt2x00: Don't disable G0 PA_PE bit in case of BT coexistence. Date: Wed, 18 May 2011 20:25:18 +0200 User-Agent: KMail/1.13.5 (Linux/2.6.32.26-175.fc12.x86_64; KDE/4.4.5; x86_64; ; ) Cc: linux-wireless@vger.kernel.org, users@rt2x00.serialmonkey.com References: <201105182022.20341.IvDoorn@gmail.com> In-Reply-To: <201105182022.20341.IvDoorn@gmail.com> MIME-Version: 1.0 Message-Id: <201105182025.19264.IvDoorn@gmail.com> 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]); Wed, 18 May 2011 18:26:40 +0000 (UTC) From: Gertjan van Wingerde (split off from the earlier RT35xx patch submitted by Shiang) Signed-off-by: Shiang Tu Signed-off-by: Gertjan van Wingerde Signed-off-by: Ivo van Doorn --- drivers/net/wireless/rt2x00/rt2800lib.c | 6 +++++- 1 files changed, 5 insertions(+), 1 deletions(-) diff --git a/drivers/net/wireless/rt2x00/rt2800lib.c b/drivers/net/wireless/rt2x00/rt2800lib.c index 1cad89e..ce736e9 100644 --- a/drivers/net/wireless/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/rt2x00/rt2800lib.c @@ -1811,7 +1811,11 @@ static void rt2800_config_channel(struct rt2x00_dev *rt2x00dev, rt2x00_set_field32(&tx_pin, TX_PIN_CFG_LNA_PE_G0_EN, 1); rt2x00_set_field32(&tx_pin, TX_PIN_CFG_RFTR_EN, 1); rt2x00_set_field32(&tx_pin, TX_PIN_CFG_TRSW_EN, 1); - rt2x00_set_field32(&tx_pin, TX_PIN_CFG_PA_PE_G0_EN, rf->channel <= 14); + if (test_bit(CAPABILITY_BT_COEXIST, &rt2x00dev->cap_flags)) + rt2x00_set_field32(&tx_pin, TX_PIN_CFG_PA_PE_G0_EN, 1); + else + rt2x00_set_field32(&tx_pin, TX_PIN_CFG_PA_PE_G0_EN, + rf->channel <= 14); rt2x00_set_field32(&tx_pin, TX_PIN_CFG_PA_PE_A0_EN, rf->channel > 14); rt2800_register_write(rt2x00dev, TX_PIN_CFG, tx_pin);