Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp1678935pxu; Sun, 6 Dec 2020 03:48:39 -0800 (PST) X-Google-Smtp-Source: ABdhPJwaILJNAaz/5gm1Ipuql5hYtdmowdz9k+s1lujDBqW3AWF8FISbaxisXWEELv23Kd6AGcBc X-Received: by 2002:a17:906:4982:: with SMTP id p2mr14685339eju.416.1607255319395; Sun, 06 Dec 2020 03:48:39 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1607255319; cv=none; d=google.com; s=arc-20160816; b=ZdeCvRcG0BM4HybX0YBNxTkLpERos6qYUN3sPqEym+BB6skA+/8vRhetC1jEo6NCdK bXA0k+rBsuKRd5SixyVThg550LpBNcWGS1/+2/YUO5i7hySZP5NOu19JHnRPFZTE7SAn mqvKMaeJebEc2a8VxAAOCUT/ytFc3mxrNVMSCvYP1XvZGcji1G5f++/VIgh//I37uK2Z YaOPjOaGT5bUVldXiBq+e0Mx7v3lSaScl5DLopm+oSnogyxWTE6V65npaUr0gYovZJXf PhuyjyiOHhR8ih9yKuHGB1i3//La/cT8GWFeC4LvZrDtCo39hUjLxcsvJSAhEozFs0wz Gs4Q== 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; bh=MLH/N0/EvMeUjPRVSX2ro+VpBq+VtlmDqzjxfEooMKg=; b=wLvn47HVJjZU9ilFbFTz6p5S+hY8EH6Mkpcq/KZr9TwJrcZQkylpuqNIw5+sElgixw Zhn7PwgaBAljj9HrCHe2BeUtCmn6IEy8m3PpKz0e9zT1kxvwOALT9Kyc9bOl700DqJ7y lRCS3FiymNCa+7pKauCKogpJ4bKzy9QzVmJgSsnbTN499brEyXaZqfdPldEF/N5zshIy mBLwVPX3wfmzUwnlDwlqodrgo2rpSbE4DGTwAdQmIb5fK5j0TFCbf9xfwUY1OjEnicAD r7ghUVBOiqypboKVF85qGgOwag4wYfH+vS2nXW/f6Khv2nI3zOt2i/9l7LMvysenJR4M Ahpg== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (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 gs40si4850105ejc.370.2020.12.06.03.48.16; Sun, 06 Dec 2020 03:48:39 -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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729227AbgLFLrE (ORCPT + 99 others); Sun, 6 Dec 2020 06:47:04 -0500 Received: from mail.kernel.org ([198.145.29.99]:43410 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729245AbgLFLnz (ORCPT ); Sun, 6 Dec 2020 06:43:55 -0500 From: Greg Kroah-Hartman Authentication-Results: mail.kernel.org; dkim=permerror (bad message/signature format) To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Hulk Robot , Wang Hai , Andrew Lunn , Jakub Kicinski Subject: [PATCH 5.4 29/39] net: mvpp2: Fix error return code in mvpp2_open() Date: Sun, 6 Dec 2020 12:17:33 +0100 Message-Id: <20201206111556.082965251@linuxfoundation.org> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20201206111554.677764505@linuxfoundation.org> References: <20201206111554.677764505@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: Wang Hai [ Upstream commit 82a10dc7f0960735f40e8d7d3bee56934291600f ] Fix to return negative error code -ENOENT from invalid configuration error handling case instead of 0, as done elsewhere in this function. Fixes: 4bb043262878 ("net: mvpp2: phylink support") Reported-by: Hulk Robot Signed-off-by: Wang Hai Reviewed-by: Andrew Lunn Link: https://lore.kernel.org/r/20201203141806.37966-1-wanghai38@huawei.com Signed-off-by: Jakub Kicinski Signed-off-by: Greg Kroah-Hartman --- drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c | 1 + 1 file changed, 1 insertion(+) --- a/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c +++ b/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c @@ -3696,6 +3696,7 @@ static int mvpp2_open(struct net_device if (!valid) { netdev_err(port->dev, "invalid configuration: no dt or link IRQ"); + err = -ENOENT; goto err_free_irq; }