From patchwork Wed Oct 17 06:37:48 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shivasharan Srikanteshwara X-Patchwork-Id: 10644657 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 BD6231508 for ; Wed, 17 Oct 2018 06:38:39 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id AE53429A18 for ; Wed, 17 Oct 2018 06:38:39 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id A26172999D; Wed, 17 Oct 2018 06:38:39 +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,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 310C72999D for ; Wed, 17 Oct 2018 06:38:39 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727307AbeJQOcq (ORCPT ); Wed, 17 Oct 2018 10:32:46 -0400 Received: from mail-pl1-f194.google.com ([209.85.214.194]:42724 "EHLO mail-pl1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727099AbeJQOcq (ORCPT ); Wed, 17 Oct 2018 10:32:46 -0400 Received: by mail-pl1-f194.google.com with SMTP id c8-v6so12172446plo.9 for ; Tue, 16 Oct 2018 23:38:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=Q8x2m+ybc+PpE8RhAVR12yICjG4VgQnRxbJZ0ur2cOM=; b=LYLMDVRL96hszgAKgiVruyHM38/xfQEC8zz7rHFW/lqtH63gHAMH0HtwUh25TLetxy mw3rL0V9mcURZHKWe8JkzoSqwKeF66Zml/JHp+xFby/QMqqHFGvIv81GuApEWpj6uNO9 a5aPA1Piv7kra7p3chTBBIjLEQk/0BIwK0uVI= 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=Q8x2m+ybc+PpE8RhAVR12yICjG4VgQnRxbJZ0ur2cOM=; b=mOOubUxNfd/dJRGAV4jWo8n6np0eudISEmXf2RrTq7MvsX5ylT2NE+LD1E7T8wK/2R ciqDo5M6hg2rEIqjhkqRRs2lLzFf472EtLQh8ra4DFMsWXAI1LYE/61uXqaW73PXYbea kIf0mvxLzbqehG0Mt+SXAJQLv94jE1o2+vfu9hCPbXAjf2DPhGByt72OtC5Y/BHO4Rak P8x1bJjmqSB+xyeCdEs0dNfdw5Z/mKVme3sOH7aTJPcc/wFSOzk7YFYrTDwSXj2emhvy 8LzybmBrpQpKB2CjhBzcu6HUzN2B6BTFgjCzdAlwjQENla2M7aUNPgOU3qCnk5lkP9Ym ejsg== X-Gm-Message-State: ABuFfohZFXtOpl3PmMpXfwNFg+Py2wBO0myyW2VcEBOPMs3Bb8zDtVDZ FHrwDeEZlgG0l73iRtZ4WSPYSD406/1NwA== X-Google-Smtp-Source: ACcGV60jpjjQK9daYUIS4/7KyKwVRH2pPcHQT5Cq8SEbQI0YiM3VwsyDKiKJv1j3LVpsZugMigzZ8Q== X-Received: by 2002:a17:902:34a:: with SMTP id 68-v6mr24586638pld.39.1539758317588; Tue, 16 Oct 2018 23:38:37 -0700 (PDT) Received: from dhcp-135-24-192-142.dhcp.broadcom.net ([192.19.234.250]) by smtp.gmail.com with ESMTPSA id y131-v6sm19375425pfg.164.2018.10.16.23.38.35 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 16 Oct 2018 23:38:36 -0700 (PDT) From: Shivasharan S To: linux-scsi@vger.kernel.org Cc: kashyap.desai@broadcom.com, sumit.saxena@broadcom.com, Shivasharan S Subject: [PATCH V2 10/19] megaraid_sas: Fail init if heartbeat timer fails Date: Tue, 16 Oct 2018 23:37:48 -0700 Message-Id: <1539758277-1882-11-git-send-email-shivasharan.srikanteshwara@broadcom.com> X-Mailer: git-send-email 2.4.3 In-Reply-To: <1539758277-1882-1-git-send-email-shivasharan.srikanteshwara@broadcom.com> References: <1539758277-1882-1-git-send-email-shivasharan.srikanteshwara@broadcom.com> Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP When driver fails to start the heartbeat timer, exit from FW init. Signed-off-by: Shivasharan S --- drivers/scsi/megaraid/megaraid_sas_base.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/scsi/megaraid/megaraid_sas_base.c b/drivers/scsi/megaraid/megaraid_sas_base.c index 8a251d03be34..27dbccbbfd8d 100644 --- a/drivers/scsi/megaraid/megaraid_sas_base.c +++ b/drivers/scsi/megaraid/megaraid_sas_base.c @@ -5694,10 +5694,12 @@ static int megasas_init_fw(struct megasas_instance *instance) /* Launch SR-IOV heartbeat timer */ if (instance->requestorId) { - if (!megasas_sriov_start_heartbeat(instance, 1)) + if (!megasas_sriov_start_heartbeat(instance, 1)) { megasas_start_timer(instance); - else + } else { instance->skip_heartbeat_timer_del = 1; + goto fail_get_ld_pd_list; + } } /*