Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp1416615pxu; Mon, 23 Nov 2020 22:36:41 -0800 (PST) X-Google-Smtp-Source: ABdhPJy8Ax8ktnoCAA6c12FCCUMIJjcwhp9osWKUbAf0P2n0IV1LDQ2qfUjLlUJDM5VIxXprBKFY X-Received: by 2002:aa7:d607:: with SMTP id c7mr2486408edr.70.1606199800858; Mon, 23 Nov 2020 22:36:40 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1606199800; cv=none; d=google.com; s=arc-20160816; b=P+LcdPcHDxdabHQnw9gtaX1X/NmJDdm45vRRjIv9kbeiEKGZyB3v0PFW/YTVqmfTKK uF2LhZ2rbqvpG/dSjQm4KEIMkYPx5GYkmD4XjU59wgWbLP7koza6b11y6LIUp5slr8J/ bAkSlDJC7Umwph1cYEQoXzcAiKQSHYOXsRhfR8Vj5QQhXXISnScbEZVZxyf0s7jUqENP 7P8vIqNK0esi8H0n6VI5lM1Hyznpg+7LVcn3UizwLteoXMfhrKvQwbiDccLtNwMjDCXm h8dgrO/TgOlulEzKYlv3a3weU/qH/077e0dElcSD5xNoHnnwvO4DmEsAuSDLVDK1S+zx GhlA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:subject:cc:to:from; bh=T88jAytiF7z6ZxnvBxmEzBoRxroavkBqEdF6CwtscX4=; b=GGRTqdTvWCN2z7ODI6efr/oTCXQIDS8csmvRzIeOt7lwk69WBkQOXnyp6odbfQOu9M QBWp3egkSPEAsk8XOTgMaSxvWLaTHEVUbqprWfToQ9dsP8mR4MvH9cOVOVP4znKtewr+ y8nwsQ2T882ujT9d3E/IP0ms69VUtaMFxOhdqWA+GJKwBjkvW7wECnVFW3JX2/+asoCe O7OndQOniG9rxTY4DiE5PYtgX5CeWfPI2VkwwiIYlAkbvs43Y43A4uWwIo0tYA0yAt7Y piIgt30WAPJtIimGy7ki+LQsxd+Ky6ztiP1C9a0DK1vBMvpQxrdiIfkVpLW1BbJvWalp qBgQ== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id be20si8239850edb.423.2020.11.23.22.36.17; Mon, 23 Nov 2020 22:36:40 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729552AbgKXGag (ORCPT + 99 others); Tue, 24 Nov 2020 01:30:36 -0500 Received: from szxga07-in.huawei.com ([45.249.212.35]:8393 "EHLO szxga07-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725786AbgKXGag (ORCPT ); Tue, 24 Nov 2020 01:30:36 -0500 Received: from DGGEMS402-HUB.china.huawei.com (unknown [172.30.72.60]) by szxga07-in.huawei.com (SkyGuard) with ESMTP id 4CgDfB1kZwz72HQ; Tue, 24 Nov 2020 14:30:10 +0800 (CST) Received: from huawei.com (10.175.124.27) by DGGEMS402-HUB.china.huawei.com (10.3.19.202) with Microsoft SMTP Server id 14.3.487.0; Tue, 24 Nov 2020 14:30:18 +0800 From: Wang ShaoBo To: CC: , , , , , Subject: [PATCH] EDAC, mv64x60: Fix error return code in mv64x60_pci_err_probe() Date: Tue, 24 Nov 2020 14:30:09 +0800 Message-ID: <20201124063009.1529-1-bobo.shaobowang@huawei.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.175.124.27] X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Fix to return -ENODEV error code when edac_pci_add_device() failed instaed of 0 in mv64x60_pci_err_probe(), as done elsewhere in this function. Fixes: 4f4aeeabc061 ("drivers-edac: add marvell mv64x60 driver") Signed-off-by: Wang ShaoBo --- drivers/edac/mv64x60_edac.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/edac/mv64x60_edac.c b/drivers/edac/mv64x60_edac.c index 3c68bb525d5d..456b9ca1fe8d 100644 --- a/drivers/edac/mv64x60_edac.c +++ b/drivers/edac/mv64x60_edac.c @@ -168,6 +168,7 @@ static int mv64x60_pci_err_probe(struct platform_device *pdev) if (edac_pci_add_device(pci, pdata->edac_idx) > 0) { edac_dbg(3, "failed edac_pci_add_device()\n"); + res = -ENODEV; goto err; } -- 2.17.1