Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp3799060ybi; Mon, 29 Jul 2019 12:51:31 -0700 (PDT) X-Google-Smtp-Source: APXvYqxbhDw0gNasIk8jFsDHlfdT7c5ubG+kZ+ouc/JuiyvDcRBH3nIz/bgkCEnnkFk//9oXb9PQ X-Received: by 2002:a63:221f:: with SMTP id i31mr108187835pgi.251.1564429891208; Mon, 29 Jul 2019 12:51:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1564429891; cv=none; d=google.com; s=arc-20160816; b=PNsVuXXnunwNj53Sj54KwbNbUb0/6SKcxuFjNhcBkXy1MTrOjTTcpb6XSqE/fM/qE6 FqVnFutaxJOpWiZAN8mvh1PG+W46ObxJBZjI7HlnORIzel8GERqPLho+fDAtwKBwMt1+ UqAiaVekerVVOtB7ci8taS6TpMLOv4z2UbVtR25b2HUCiRC9cziNphSqCpk9MZ+6or/k Snv10T7dxyHB/PESAf7lB3KM2prrArfnY+LMDCECaJExsn3ezhi5zW5YoJsjJWZ7A1Nx TBy1G+PEWhjpgqYwFdMcEj3o5WYtlQCPFz4H45HXlvw9Q1QKPoM/C/phmsh3cUWIma6C s80w== 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=YcLsYcQQUbAKG7/9d41UgWoPeZ3gC16cojmsIfpPJ8w=; b=iRdaIl4Kf2VhaGpV2kuEO4rS4kDvgNU5D/rxh8WXrms62uWj7+hBM+H2hx+6AENSE7 6xLftJRi3SbMUZ5TNbhKkivZfT09gw/3QSCipfm5In3DuUWtTf1sOgCqL2fMOg+3ED1h 5DQYac/YFuD0zV/HdPE6/IAMZbMR2ifnVK5D80GYYYDxmOnZMPUVvYt8iy3gUN+ALWB7 50SG3GQDGCvIN+8+hscksT9X22hEK5ony7Br/mM40cZTj5M1MlfJ+X3aOGco/D6bGrEf x3/cbbYyk/WIr+po4DKw0dX0110eJAkLnHrfdlCsm7qia10U+YgwabSRjMBISAki0WXv YJlQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=T2CKGCzV; 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 n2si9033007pga.426.2019.07.29.12.51.16; Mon, 29 Jul 2019 12:51:31 -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=T2CKGCzV; 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 S2390623AbfG2TuB (ORCPT + 99 others); Mon, 29 Jul 2019 15:50:01 -0400 Received: from mail.kernel.org ([198.145.29.99]:40772 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2389663AbfG2TuA (ORCPT ); Mon, 29 Jul 2019 15:50:00 -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 B44D020C01; Mon, 29 Jul 2019 19:49:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1564429799; bh=enZV5mm6GX8OonBbiwhZ2ajgJhKHhqsOOYLEAxaxQCY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=T2CKGCzV8nxCvTS9c4Zlv72g75DOzvkFC5p+/aVJ+yXO3fqhdgOIWUpQ/aqmcaXlS FAQ7RLo2ea06hZgRwh1JQd+Dv7L6Bk9hdm2ZmMk2urTHgEwC2xeEjaWTrVH5sedMox ePkIXdJmZ/4fvZGOUN7p9uUQhER4Pb6aOOtW0PY0= 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 5.2 099/215] mfd: hi655x-pmic: Fix missing return value check for devm_regmap_init_mmio_clk Date: Mon, 29 Jul 2019 21:21:35 +0200 Message-Id: <20190729190756.278518319@linuxfoundation.org> X-Mailer: git-send-email 2.22.0 In-Reply-To: <20190729190739.971253303@linuxfoundation.org> References: <20190729190739.971253303@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 f1c51ce309fa..7e3959aaa285 100644 --- a/drivers/mfd/hi655x-pmic.c +++ b/drivers/mfd/hi655x-pmic.c @@ -109,6 +109,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