From patchwork Sun Mar 15 14:00:17 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Kondratiev X-Patchwork-Id: 6013001 X-Patchwork-Delegate: kvalo@adurom.com Return-Path: X-Original-To: patchwork-linux-wireless@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 07DC39F399 for ; Sun, 15 Mar 2015 14:00:55 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 462362021F for ; Sun, 15 Mar 2015 14:00:54 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 561A52022A for ; Sun, 15 Mar 2015 14:00:53 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752338AbbCOOAu (ORCPT ); Sun, 15 Mar 2015 10:00:50 -0400 Received: from sabertooth02.qualcomm.com ([65.197.215.38]:64722 "EHLO sabertooth02.qualcomm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752545AbbCOOAr (ORCPT ); Sun, 15 Mar 2015 10:00:47 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=qca.qualcomm.com; i=@qca.qualcomm.com; q=dns/txt; s=qcdkim; t=1426428047; x=1457964047; h=from:cc:to:subject:date:message-id:in-reply-to: references; bh=L4IRpET03HM5q+g+t21aC2euO9Y26QzDZv38PztXREk=; b=NCqLsNptOo/uhJfboM391kKWjPAX9vzAI3rS/jNSetKIuPtIk0BmLrdv jtYoRiwzbc/Gl1uGNjd94CkfrC37iknxvWrePA1sKOYW5lmhH5fMMXsTT XJm4KQKs1lQH/Dab1SkJm//FF46FucodFDt7Adlja1mW3tyBghd9cAOxc c=; X-IronPort-AV: E=McAfee;i="5600,1067,7740"; a="85918047" Received: from ironmsg04-r.qualcomm.com ([172.30.46.18]) by sabertooth02.qualcomm.com with ESMTP/TLS/DHE-RSA-AES256-SHA; 15 Mar 2015 07:00:47 -0700 From: Vladimir Kondratiev Cc: Vladimir Kondratiev , linux-wireless@vger.kernel.org, wil6210@qca.qualcomm.com X-IronPort-AV: E=Sophos;i="5.11,404,1422950400"; d="scan'208";a="925534721" Received: from lx-wigig-72.mea.qualcomm.com ([10.18.176.26]) by Ironmsg04-R.qualcomm.com with ESMTP; 15 Mar 2015 07:00:45 -0700 To: Kalle Valo Subject: [PATCH 2/7] wil6210: fix check for FW responsiveness Date: Sun, 15 Mar 2015 16:00:17 +0200 Message-Id: <1426428024-4538-4-git-send-email-qca_vkondrat@qca.qualcomm.com> X-Mailer: git-send-email 2.1.0 In-Reply-To: <1426428024-4538-1-git-send-email-qca_vkondrat@qca.qualcomm.com> References: <1426428024-4538-1-git-send-email-qca_vkondrat@qca.qualcomm.com> Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID,T_RP_MATCHES_RCVD,UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP "echo" used to be called when no firmware loaded to the NIC, this causes error output. Probe firmware with "echo" only after it returned "ready" event. Signed-off-by: Vladimir Kondratiev --- drivers/net/wireless/ath/wil6210/main.c | 2 ++ drivers/net/wireless/ath/wil6210/pcie_bus.c | 2 -- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/wireless/ath/wil6210/main.c b/drivers/net/wireless/ath/wil6210/main.c index afff8d3..a5fd605 100644 --- a/drivers/net/wireless/ath/wil6210/main.c +++ b/drivers/net/wireless/ath/wil6210/main.c @@ -724,6 +724,8 @@ int wil_reset(struct wil6210_priv *wil, bool load_fw) /* we just started MAC, wait for FW ready */ rc = wil_wait_for_fw_ready(wil); + if (rc == 0) /* check FW is responsive */ + rc = wmi_echo(wil); } return rc; diff --git a/drivers/net/wireless/ath/wil6210/pcie_bus.c b/drivers/net/wireless/ath/wil6210/pcie_bus.c index 25343cf..1099861 100644 --- a/drivers/net/wireless/ath/wil6210/pcie_bus.c +++ b/drivers/net/wireless/ath/wil6210/pcie_bus.c @@ -246,8 +246,6 @@ static int wil_pcie_probe(struct pci_dev *pdev, const struct pci_device_id *id) wil6210_debugfs_init(wil); - /* check FW is alive */ - wmi_echo(wil); return 0;