From patchwork Thu Jan 31 05:53:03 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Siva Rebbagondla X-Patchwork-Id: 10789691 X-Patchwork-Delegate: kvalo@adurom.com Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id EBA391390 for ; Thu, 31 Jan 2019 05:53:40 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id E5015307A6 for ; Thu, 31 Jan 2019 05:53:40 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id D8838307B3; Thu, 31 Jan 2019 05:53:40 +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=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8391C307A6 for ; Thu, 31 Jan 2019 05:53:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726490AbfAaFxj (ORCPT ); Thu, 31 Jan 2019 00:53:39 -0500 Received: from mail-pf1-f195.google.com ([209.85.210.195]:33445 "EHLO mail-pf1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725875AbfAaFxj (ORCPT ); Thu, 31 Jan 2019 00:53:39 -0500 Received: by mail-pf1-f195.google.com with SMTP id c123so1008662pfb.0 for ; Wed, 30 Jan 2019 21:53:39 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=bE161hYCDVB1Ui5bpyCuPHmtXVi+qYjmnQvupFiQdGs=; b=Wx4vJTe5uKAEbSP0GUUj4qE9UWDWB+m+aKGrkijvGbwkgeEQefllHGnESS0r0/Abq9 t/cjjDvZDwYWYFvwGSPm0zl6B85tErga9tOl0eTrhe69uKtohyfAdFJkGoaAe/0R21CC 81ykQJbwnUvQWbovIExl+1l7oPLVUXrVJatF60w1NmFPU4OOPVMXvGV2ZRH6UIG4ygKG kjnN7x/umM3f4DkB9ooUJfKjq6ScFL6iNW0C3OktmOekidmd+ktovwAnb/c3u7oEp9RL EWSXhG5Pk3w7gvzfSo1sGCz3Uidzl5arHR2OHm+ERb4SrFdPH30Ig7AG5V4l9ePyUqTe SqGA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=bE161hYCDVB1Ui5bpyCuPHmtXVi+qYjmnQvupFiQdGs=; b=o0HwBBlIDd/yC5qBCPIc70sk3Y8/a/eLYzrYcz4qE1+mQ7fz2JmBRZjd9trkONc6f8 TT5CDKDYtxQhFTSZXusGI34u3AO5lKzSaa3vBvzigzMVgLD/y6TZem3C0IWFv/Gj36Yd daUcu9YZrGk10sXyJcPAKNMjkBfNmq+9EpjI5Z8mB+Xf2gXr/7q5xeZXIedfCfTroxeM nhqTyu4YKju6rkq7d3/jCzODd+LBhNAtbPOlqCWpnIn9f2z6pY1PRyB7oxg8z2AgMeMl GWKRxcFZhZmnOmMKhlxJlx400+leVpG81+7aOZuIaS9c7LaseaGxx0awNGq0etshibCr Y9Ow== X-Gm-Message-State: AJcUukcoaruQgd28AgyRSGcnBMs6THYVFu/vAp7+G82n1ibMqZOKNKQ1 TZ4QLfnj/7fqimHazQmXHq0= X-Google-Smtp-Source: ALg8bN4YZJptqghIDkFTJk7Q5rih6A7USyKOb39LAejv6L4cWlo0eRgncCO4IvUAqFejwKkBecDLAg== X-Received: by 2002:a62:4641:: with SMTP id t62mr33159804pfa.141.1548914018459; Wed, 30 Jan 2019 21:53:38 -0800 (PST) Received: from cpu459.localdomain ([203.196.161.90]) by smtp.gmail.com with ESMTPSA id h19sm4314493pfn.114.2019.01.30.21.53.35 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 30 Jan 2019 21:53:37 -0800 (PST) From: Siva Rebbagondla To: Kalle Valo Cc: linux-wireless@vger.kernel.org, rishikesh.basu@redpinesignals.com, siva.rebbagondla@redpinesignals.com, krishna.pedda@redpinesignals.com, ganapathi.kondraju@redpinesignals.com Subject: [v2 3/5] rsi: fix wowlan wakeup issue for hibernate(S4) Date: Thu, 31 Jan 2019 11:23:03 +0530 Message-Id: <1548913985-7180-4-git-send-email-siva8118@gmail.com> X-Mailer: git-send-email 2.5.5 In-Reply-To: <1548913985-7180-1-git-send-email-siva8118@gmail.com> References: <1548913985-7180-1-git-send-email-siva8118@gmail.com> Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Siva Rebbagondla At SDIO restore ieee80211_restart_hw() is getting called to restart all MAC operations. This step is not required. Returning 1 from mac80211_resume() will serve this purpose. Signed-off-by: Siva Rebbagondla --- drivers/net/wireless/rsi/rsi_91x_mac80211.c | 8 ++++++-- drivers/net/wireless/rsi/rsi_91x_sdio.c | 1 - 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/drivers/net/wireless/rsi/rsi_91x_mac80211.c b/drivers/net/wireless/rsi/rsi_91x_mac80211.c index aded1ae..8d1282f 100644 --- a/drivers/net/wireless/rsi/rsi_91x_mac80211.c +++ b/drivers/net/wireless/rsi/rsi_91x_mac80211.c @@ -1938,8 +1938,12 @@ static int rsi_mac80211_resume(struct ieee80211_hw *hw) rsi_dbg(INFO_ZONE, "%s: mac80211 resume\n", __func__); - if (common->hibernate_resume) - return 0; + if (common->hibernate_resume) { + /* Device need a complete restart of all MAC operations. + * returning 1 will serve this purpose. + */ + return 1; + } mutex_lock(&common->mutex); rsi_send_wowlan_request(common, 0, 0); diff --git a/drivers/net/wireless/rsi/rsi_91x_sdio.c b/drivers/net/wireless/rsi/rsi_91x_sdio.c index 4005c1d..43e8a0d 100644 --- a/drivers/net/wireless/rsi/rsi_91x_sdio.c +++ b/drivers/net/wireless/rsi/rsi_91x_sdio.c @@ -1393,7 +1393,6 @@ static int rsi_restore(struct device *dev) common->iface_down = true; adapter->sc_nvifs = 0; - ieee80211_restart_hw(adapter->hw); common->wow_flags = 0; common->iface_down = false;