Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp3793083ybi; Mon, 29 Jul 2019 12:44:08 -0700 (PDT) X-Google-Smtp-Source: APXvYqwPsV3I4qybdDQD7mcuk1FhZtWYkUbKVUykIZ9bQza36DKN0pNUyCxBjiAVRo4HXp2EfYu8 X-Received: by 2002:a17:90a:d80b:: with SMTP id a11mr108108179pjv.53.1564429448146; Mon, 29 Jul 2019 12:44:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1564429448; cv=none; d=google.com; s=arc-20160816; b=VhLxcudF3ZaD8ZoLWNDdYc9469ahSQMVd9MGgM6a2AOgz99vtKMWm79V8GHJUHLwri qE2VSIyXf75hh/xXWKkj7hIYAlN+aaTD3bpscT+XOAy6fNwAEdS+sluJRHb1X6EsQebS 3y2ddFKWfB6CREU6z6IYFU/WkU7r0KG6ucN6mVzZWH3lk3/yb46AAnvZ/07sRRQ4dZuv zYRGBV8YGIhtDjqARblRr/Cb9TrqY644b+dN5q1/Pg6v85lCWiq71gnv7EO32zJOpbV1 XmJUdqzIZAIP/iMEYEtKzb+OA+fpoqFIhXa3ynCoUpSS8wo2+lvGQvux8XFuQS+cuPi7 D8/w== 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=/Dfc7BLbHyO4aet66DTKxbQxwTtFubh6LK4caOlsq0U=; b=p+hzXD3Gn+l/9cw+1J4buWsXjKCPV7A8y1y9mgXnrcL2EAP9sAPkbKX3wFOimBQPuE pdEZZZXI3bu9AMerhvkkFvLnDfsCr5LtcuyDPCUJug2ExUENPE+Dc0gO6iGykthhqvLm hyF4WbNyOMT2Am5K07EL1FvfF7unriu3HmWSbi/IwefV1e5prYhyN82z/8nwJzkFIQHx lbPr6t5pXuvfZK1RmImQx0MBkwkihoAbhldS06EyTUKoDc+FyYZ6h39Q8RUnD5zcBWGs fIK3d13O0jTqcxaNilcYQVQkyuhhLiudaulfK++TLuq/68l5L/gqYTSfMIxUmdRjDp1t IIfA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=xrp0CFmB; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id s12si25803829plp.63.2019.07.29.12.43.53; Mon, 29 Jul 2019 12:44:08 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=xrp0CFmB; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2389374AbfG2Tlc (ORCPT + 99 others); Mon, 29 Jul 2019 15:41:32 -0400 Received: from mail.kernel.org ([198.145.29.99]:57018 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2389363AbfG2Tlb (ORCPT ); Mon, 29 Jul 2019 15:41:31 -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 2DD7221655; Mon, 29 Jul 2019 19:41:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1564429290; bh=v7sks2e6muLIM6cZO40Wu7vtz4iGZ6tb3NNZnvw9x8w=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=xrp0CFmBGOPQnE/Ve38nLrFxjC+KE+7kQKLMIYxwz/V+sfIXeWe9no+Qdn6l1tTKG wJqy87lhH/N+75/ESa8Y/EwXHVRgasrwZ9dzMLb3z2IKDYfv2+QebuQn89Mx5947IR ZwonZOGiOlgfxSrPh0s6GNhyf6FeG2CPIqbSMvgo= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Axel Lin , Chen Feng , Lee Jones , Sasha Levin Subject: [PATCH 4.19 051/113] mfd: hi655x-pmic: Fix missing return value check for devm_regmap_init_mmio_clk Date: Mon, 29 Jul 2019 21:22:18 +0200 Message-Id: <20190729190707.758914907@linuxfoundation.org> X-Mailer: git-send-email 2.22.0 In-Reply-To: <20190729190655.455345569@linuxfoundation.org> References: <20190729190655.455345569@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 [ Upstream commit 7efd105c27fd2323789b41b64763a0e33ed79c08 ] Since devm_regmap_init_mmio_clk can fail, add return value checking. Signed-off-by: Axel Lin Acked-by: Chen Feng Signed-off-by: Lee Jones Signed-off-by: Sasha Levin --- drivers/mfd/hi655x-pmic.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/mfd/hi655x-pmic.c b/drivers/mfd/hi655x-pmic.c index 96c07fa1802a..6693f74aa6ab 100644 --- a/drivers/mfd/hi655x-pmic.c +++ b/drivers/mfd/hi655x-pmic.c @@ -112,6 +112,8 @@ static int hi655x_pmic_probe(struct platform_device *pdev) pmic->regmap = devm_regmap_init_mmio_clk(dev, NULL, base, &hi655x_regmap_config); + if (IS_ERR(pmic->regmap)) + return PTR_ERR(pmic->regmap); regmap_read(pmic->regmap, HI655X_BUS_ADDR(HI655X_VER_REG), &pmic->ver); if ((pmic->ver < PMU_VER_START) || (pmic->ver > PMU_VER_END)) { -- 2.20.1