Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp401242pxu; Tue, 1 Dec 2020 14:19:24 -0800 (PST) X-Google-Smtp-Source: ABdhPJzADpsrLw/0e/NkbsXPbDEPtOiaefscr4lLCW0aopmpseqL3Ene71evYkEME6RvLgO+rUo4 X-Received: by 2002:a17:906:1199:: with SMTP id n25mr5021560eja.293.1606861163812; Tue, 01 Dec 2020 14:19:23 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1606861163; cv=none; d=google.com; s=arc-20160816; b=jFaOUHcrpCpb6+M86j9RGnVHR5DO79V7Xy4z3ovlZYv8F+gTRCEiBRv77npY8jKnR1 SK8jkqWtUitDWc2ooIW+ECTK8ff7WvSyrA6sTVGj86jqRXYzbn2YKczrBYL0+wwUfyz6 8KgHJ6ZXzSk6HYXdZYqiIOdyzN/7gK2HFWCsnhDIrPoVnrwqy0A2QpvSRHDz3BtNeybA ygGJ4NXGRp2mXb7Gi/7GIIKEsqytFqOkldh67IZ/hSe34LztJDe64Oqa6GQpCuUdudW8 R5KgGDp3+2PI0ktZ/KlYZfK/gFbQ2dKBht3LfQqq2rlpNayJxJ2jzGxFJrI7NdroJRbl ibNg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=kRI1kMzkImqVWVA443iVvv0w8zMAZ3mp3w1A2H3+ftk=; b=HgvyhoR7+Hffzy5Ct7U2GxMiY3tQFc5qqJ8xRNlONHEwDQBlLUaHga6cftdOY0IKOY oO1DOsHZuYjm61PjBqWxAxyqSmODf7yDg05SZCwoW6jb5y/SIB6VdPc+3BjdJYp8UTbQ HN9At8pgb4XykKdF21WjnjIhR/pGGsMtOZFeVgcmYxFRvQSZgEKqZFmhWLHn2ntSdWRc cAZ3LrcxJXZQkRU+7Hg43/ajjoqjf53BNG8kbyQlEIBzw0pGP3chETlb9voNMubbv4GU dzIN8O50jUwIwwWdWsjn/7wF2eJplGeAbBwvZAKnEhtgm12+b2iuBf1zmLmMFfQCMNnu xM0w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=wvQn2ykh; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id k17si805215edf.245.2020.12.01.14.19.01; Tue, 01 Dec 2020 14:19:23 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=wvQn2ykh; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388043AbgLAI7C (ORCPT + 99 others); Tue, 1 Dec 2020 03:59:02 -0500 Received: from mail.kernel.org ([198.145.29.99]:34484 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388014AbgLAI6v (ORCPT ); Tue, 1 Dec 2020 03:58:51 -0500 Received: from localhost (83-86-74-64.cable.dynamic.v4.ziggo.nl [83.86.74.64]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 1211722253; Tue, 1 Dec 2020 08:58:09 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1606813090; bh=InAYkVsIsJSoqko8jRg4fH2YZmD7qTqLiZNNJR1hFX4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=wvQn2ykhL+163I+byssltbszyb7nKqI9b+BQ4T13f+St6Gv137+zf9aTv3vTjvP46 7a0bP+I775dUZ6NViJm/3vkJYpSh+oS2RCIsuDpc4WrjBO9HfmKvOL8RipfSbAosdw ZlWprcu846m8FxvsHzVCJ+3a775ETu7R20nBnn7A= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Hulk Robot , Zhang Changzhong , Edwin Peer , Jakub Kicinski , Sasha Levin Subject: [PATCH 4.14 30/50] bnxt_en: fix error return code in bnxt_init_board() Date: Tue, 1 Dec 2020 09:53:29 +0100 Message-Id: <20201201084648.737253775@linuxfoundation.org> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20201201084644.803812112@linuxfoundation.org> References: <20201201084644.803812112@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Zhang Changzhong [ Upstream commit 3383176efc0fb0c0900a191026468a58668b4214 ] Fix to return a negative error code from the error handling case instead of 0, as done elsewhere in this function. Fixes: c0c050c58d84 ("bnxt_en: New Broadcom ethernet driver.") Reported-by: Hulk Robot Signed-off-by: Zhang Changzhong Reviewed-by: Edwin Peer Link: https://lore.kernel.org/r/1605792621-6268-1-git-send-email-zhangchangzhong@huawei.com Signed-off-by: Jakub Kicinski Signed-off-by: Sasha Levin --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers/net/ethernet/broadcom/bnxt/bnxt.c index 4a3ee5db19d34..6ed1d7c86cfea 100644 --- a/drivers/net/ethernet/broadcom/bnxt/bnxt.c +++ b/drivers/net/ethernet/broadcom/bnxt/bnxt.c @@ -7212,6 +7212,7 @@ static int bnxt_init_board(struct pci_dev *pdev, struct net_device *dev) if (dma_set_mask_and_coherent(&pdev->dev, DMA_BIT_MASK(64)) != 0 && dma_set_mask_and_coherent(&pdev->dev, DMA_BIT_MASK(32)) != 0) { dev_err(&pdev->dev, "System does not support DMA, aborting\n"); + rc = -EIO; goto init_err_disable; } -- 2.27.0