From patchwork Tue Apr 17 12:07:01 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rakesh Pillai X-Patchwork-Id: 10344871 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 7CE376039A for ; Tue, 17 Apr 2018 12:08:13 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 7169E28A44 for ; Tue, 17 Apr 2018 12:08:13 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 65E1B28A62; Tue, 17 Apr 2018 12:08:13 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id DDD0C28A44 for ; Tue, 17 Apr 2018 12:08:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=XxwWCCcE/iyzPjZ+GYolvYtjmfiSiMtfbrShXJyRbuQ=; b=jX51e4VOxC4mm0m8BNx8jEOb8I Lb67btZRq6nKylIPln98D3NvEVxfoUqyRXYmo8RMsT8H55/3oSakGMPkOH6ynySGV9RX9SSsUHMvY o/YrMjg5gSIUFwJsK0HejyXT/dG2dxvbEIAfZZ5MPnNpopbymrjnH0OtL8ZzyiayXW/ipIPqTWHTM 8blDyMbsr8vQPmuFjEvjGgbkhFgNQqnA98iYsBDJOLYLlqlbRwxpt9nVjhfc6Hm67k5Ee+jMI0nmw ZLI2K/y0rEXLkIMh+ROkOcXlWiyTe5jIRIcFem64WfNfo7E7xM1ud+1zyqmOoRKef5ooBZjTYlPg3 mNvkaMPw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1f8PP4-0001qw-Dv; Tue, 17 Apr 2018 12:08:06 +0000 Received: from smtp.codeaurora.org ([198.145.29.96]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1f8POm-0001Ws-73 for ath10k@lists.infradead.org; Tue, 17 Apr 2018 12:07:50 +0000 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id 4F4F160C64; Tue, 17 Apr 2018 12:07:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1523966857; bh=THDnMJbJk5NaxG3teMR3+Vls9sinPNiYW+AIc3qnS/s=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=CVo0YyvzoFN7LRq1xuOPFKN4wibsJCccmh3ZeSWfaQVVLJEOnz4RgpqsDJWmJSrRX VQzw5dVkFe3laNzYfqt9trpMXEHG/V190hMmE9+mLzqiS+33kOakPVMYXF5Z4dd0DI aY+jvH9Wy9yJP5uujd750OTUd+9MAJ78HqC22JJE= Received: from pillair-linux.qualcomm.com (blr-c-bdr-fw-01_globalnat_allzones-outside.qualcomm.com [103.229.19.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: pillair@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id BC5FB60385; Tue, 17 Apr 2018 12:07:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1523966857; bh=THDnMJbJk5NaxG3teMR3+Vls9sinPNiYW+AIc3qnS/s=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=CVo0YyvzoFN7LRq1xuOPFKN4wibsJCccmh3ZeSWfaQVVLJEOnz4RgpqsDJWmJSrRX VQzw5dVkFe3laNzYfqt9trpMXEHG/V190hMmE9+mLzqiS+33kOakPVMYXF5Z4dd0DI aY+jvH9Wy9yJP5uujd750OTUd+9MAJ78HqC22JJE= DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org BC5FB60385 Authentication-Results: pdx-caf-mail.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: pdx-caf-mail.web.codeaurora.org; spf=none smtp.mailfrom=pillair@codeaurora.org From: pillair@codeaurora.org To: ath10k@lists.infradead.org Subject: [PATCH v2 4/4] ath10k: Enable sta idle power save Date: Tue, 17 Apr 2018 17:37:01 +0530 Message-Id: <1523966821-21903-5-git-send-email-pillair@codeaurora.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1523966821-21903-1-git-send-email-pillair@codeaurora.org> References: <1523966821-21903-1-git-send-email-pillair@codeaurora.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20180417_050748_319856_AB452A0B X-CRM114-Status: UNSURE ( 9.83 ) X-CRM114-Notice: Please train this message. X-BeenThere: ath10k@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Rakesh Pillai , Govind Singh , linux-wireless@vger.kernel.org MIME-Version: 1.0 Sender: "ath10k" Errors-To: ath10k-bounces+patchwork-ath10k=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP From: Govind Singh Enable sta power save in fw for the targets that supports idle power save. The idle ps enable command will be ignored by the firmware which does not support this feature. Signed-off-by: Govind Singh Signed-off-by: Rakesh Pillai --- drivers/net/wireless/ath/ath10k/mac.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/drivers/net/wireless/ath/ath10k/mac.c b/drivers/net/wireless/ath/ath10k/mac.c index 7e02ca02b28e..1d9222af1bb2 100644 --- a/drivers/net/wireless/ath/ath10k/mac.c +++ b/drivers/net/wireless/ath/ath10k/mac.c @@ -4679,6 +4679,13 @@ static int ath10k_start(struct ieee80211_hw *hw) } } + param = ar->wmi.pdev_param->idle_ps_config; + ret = ath10k_wmi_pdev_set_param(ar, param, 1); + if (ret && ret != -EOPNOTSUPP) { + ath10k_warn(ar, "failed to enable idle_ps_config: %d\n", ret); + goto err_core_stop; + } + __ath10k_set_antenna(ar, ar->cfg_tx_chainmask, ar->cfg_rx_chainmask); /*