Received: by 2002:a25:ef43:0:0:0:0:0 with SMTP id w3csp122340ybm; Tue, 26 May 2020 12:19:40 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx+HrQyZIR0dQQx/VmCWJth/dpcEYnJvaL+WiUCLTzTcJb6H7MLIThPl6zC3PTp3d5386Qe X-Received: by 2002:a50:afa5:: with SMTP id h34mr9251797edd.34.1590520780847; Tue, 26 May 2020 12:19:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1590520780; cv=none; d=google.com; s=arc-20160816; b=R+DclOlOOVXOhUHdrx1vjqIo+kxMr1QYCpDgTyUew6qdgF2h/eUI92Q6B6nN7F3xUJ GrQHByQzsAN7dVU/5x5bNiX+9VinX3n18Rw/rcOqFeX/zhV9l2H3eyf7rUD+9ky1bV4B V6lWMo+D1EKoyJm7ucQkdo63Rim/qV/Nwo1OUrFL5AEViTUZcxT6LDg532mnW1KTWFk/ oqaPf7M9ARIcrAsMijNZVjmn4tEasyWBYNDcKLtb0mtfWWQBz5LlnGA/iyvFt8FUyojG U3l/TZq07GJ8yqK0MpKChbW34pLwtkc+kfuv1ZLW4k3wmb3jO8iO7Nql0zs3VOce1nJl 1k9A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=On4cUruEEQcL2saB+xQw53L4Aa5SIuZAP4/528ppfis=; b=B8OTgbBjLoirT1oc5ec5ixOcJbxIi2iev4bV75M+nbDd+qDlOYD4b9btLZ9tVsi4w+ plXot0fHYqS8pgwOvx15xAJlWrnl7s5Z0GRHYwNc/1wfZeLZpGTrF1pwl4RwJREOOivI GZNOK69OmeSMrMHivZiHhe1DrCqp0NI2tKzolVfBxK3wqRopWdmvHuNWXuIH9JSTs71X IV6hOD1ay0x+kK66elLYkv1f4e2mv1z7i4tWuF8oCcFIsgTrl6pLKw+Qec5AO5wNBpSt QDI7MWIaBCqaBBcPy44m6CX7OkRk1HvTkISofoZnGDAjBdNxlgdohZ8QAi9wWB13VRwr IQxw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=QZxEp6zv; 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 w15si444753ede.241.2020.05.26.12.19.17; Tue, 26 May 2020 12:19:40 -0700 (PDT) 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=@kernel.org header.s=default header.b=QZxEp6zv; 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 S2392243AbgEZTPF (ORCPT + 99 others); Tue, 26 May 2020 15:15:05 -0400 Received: from mail.kernel.org ([198.145.29.99]:46444 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2392088AbgEZTPD (ORCPT ); Tue, 26 May 2020 15:15:03 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (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 8D5E120888; Tue, 26 May 2020 19:15:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1590520503; bh=78N8hQGhGPFVLaXmK4KVhx2rUwxFGMkns25RJDOs+mU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=QZxEp6zvYxZZ2AMi256fWbLKaxcgdtsWhkHRlk/Z2mw9uvHkUR62a5+3DsbO34uLr hGVIvseAx2E5YeWy83ChJPrYY607pwHETnK4YN0f0d8HusSWcnjFtEKHFT+m2O39vy 5j205oXIlIeOycGxm1yeznzTEyAOUlGYE2Vk+rhY= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Hulk Robot , Wei Yongjun , Samuel Iglesias Gonsalvez Subject: [PATCH 5.6 104/126] ipack: tpci200: fix error return code in tpci200_register() Date: Tue, 26 May 2020 20:54:01 +0200 Message-Id: <20200526183946.412535378@linuxfoundation.org> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20200526183937.471379031@linuxfoundation.org> References: <20200526183937.471379031@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Wei Yongjun commit 133317479f0324f6faaf797c4f5f3e9b1b36ce35 upstream. Fix to return negative error code -ENOMEM from the ioremap() error handling case instead of 0, as done elsewhere in this function. Fixes: 43986798fd50 ("ipack: add error handling for ioremap_nocache") Reported-by: Hulk Robot Signed-off-by: Wei Yongjun Cc: stable Acked-by: Samuel Iglesias Gonsalvez Link: https://lore.kernel.org/r/20200507094237.13599-1-weiyongjun1@huawei.com Signed-off-by: Greg Kroah-Hartman --- drivers/ipack/carriers/tpci200.c | 1 + 1 file changed, 1 insertion(+) --- a/drivers/ipack/carriers/tpci200.c +++ b/drivers/ipack/carriers/tpci200.c @@ -306,6 +306,7 @@ static int tpci200_register(struct tpci2 "(bn 0x%X, sn 0x%X) failed to map driver user space!", tpci200->info->pdev->bus->number, tpci200->info->pdev->devfn); + res = -ENOMEM; goto out_release_mem8_space; }