Received: by 2002:a05:6358:4e97:b0:b3:742d:4702 with SMTP id ce23csp3091296rwb; Mon, 15 Aug 2022 17:54:57 -0700 (PDT) X-Google-Smtp-Source: AA6agR5eHY7E+T7+n5ghyEAHmNwKn+9564fIrPiURltaTxEyGfk3fbeShOyAULtK1H16US8fDHLP X-Received: by 2002:a17:906:4786:b0:732:fc99:cf68 with SMTP id cw6-20020a170906478600b00732fc99cf68mr12871242ejc.18.1660611211271; Mon, 15 Aug 2022 17:53:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1660611211; cv=none; d=google.com; s=arc-20160816; b=k0KXfQVm1mUUSs7LVMRbDVDDVcJNzSKv5jA7OSqes5n/Sl0uvoMrSzhGfKHvh3DhEG yLKWPK+SLSOkyjU35iTXzRSJDpHovoUqbSlfIwoUN8/Vbd6wX3KtpCnCyZZfz4ivin8q h5OS137wrFOEcMT+AP97HoF7qyQ593UJr3RTRW4XGJG7BCQ2qhZByLnuSRP9xTOBHLdH I7wCnoRb4WtQuJpVP0AI/Ls4y15q+N33ZLqx0naEAXfGq0p69xM/1mniE3Q+DOZC1WWH LdIjlRJkgnRYmNf1dZv4n6uOr7/ECRg5D4setDqiijxU8967epjuO1jVlI9iWvd11dMa D7Ww== 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:dkim-signature; bh=9cSa0o4lAKf88yAaHj6bbOYjFaJkUCa359KmIuJ5lrQ=; b=Dl0VSCQ3VV5XJ32TWA2FgVYu6TCn9SPMeR1TZ7B7b4bWeAbzoD8szEa7UZMCj77E6V T4UxBwOwVZcpwNSfHcHnj1AgrsH7OxlN1zAgpGC/JBmrX8XR0Yk5elmhjL4SZ4oqm/5U O0b2ECOVY0L1Rb9fpB6353DLSu/BUPRo8BmLAHcSBeMlpNT0PyWL9/EHOcHhmrAIktxh OUN+J5p8Em17i2rt/hLIs4bzpzqjlRVkmUeBGlW9hH3DoSotVUIbE4RGb5h0HvLvg5oe 9MEO7WNlc5ZKLH9cpUA1uxXYPGL3IDxP7tY1OO7bqx2fEykxcMAb2YU0LkRfjYFFPZqz t5lg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=cnOsOVUz; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id s20-20020aa7d794000000b0043bc832d514si7798037edq.318.2022.08.15.17.53.05; Mon, 15 Aug 2022 17:53:31 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=cnOsOVUz; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1354171AbiHOXot (ORCPT + 99 others); Mon, 15 Aug 2022 19:44:49 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60314 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1354194AbiHOXlh (ORCPT ); Mon, 15 Aug 2022 19:41:37 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5950783F3A; Mon, 15 Aug 2022 13:11:08 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 1D466B80EAD; Mon, 15 Aug 2022 20:11:07 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 7027CC433D7; Mon, 15 Aug 2022 20:11:05 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1660594265; bh=a4msX/u+y+7Zrc3gwU7scUBR6sDo4jLQHCMw3wNXdzc=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=cnOsOVUziZU3EJMzVey8ADgxFYK2EVylhehW86LevX1xf49Q7cKYUS26u+m3efZii r11gS1SHX3R8yUQoTrwwDup+enoIbW4blkyjyvLc3BT/72NFcw5ltdG7oS8wuXW/hB coHpcLsyPRcY2USfLtfWo6mEBngCObZi9qy0/0YQ= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Hulk Robot , Jian Zhang , Hans Verkuil , Mauro Carvalho Chehab , Sasha Levin Subject: [PATCH 5.19 0403/1157] media: driver/nxp/imx-jpeg: fix a unexpected return value problem Date: Mon, 15 Aug 2022 19:55:59 +0200 Message-Id: <20220815180455.790165113@linuxfoundation.org> X-Mailer: git-send-email 2.37.2 In-Reply-To: <20220815180439.416659447@linuxfoundation.org> References: <20220815180439.416659447@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Jian Zhang [ Upstream commit 5b304046a81eda221b5d06a9c62f7b5e45530fa5 ] In function mxc_jpeg_probe(), when devm_clk_get() fail, the return value will be unexpected, and it should be the devm_clk_get's error code. Fixes: 4c2e5156d9fa6 ("media: imx-jpeg: Add pm-runtime support for imx-jpeg") Reported-by: Hulk Robot Signed-off-by: Jian Zhang Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab Signed-off-by: Sasha Levin --- drivers/media/platform/nxp/imx-jpeg/mxc-jpeg.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/media/platform/nxp/imx-jpeg/mxc-jpeg.c b/drivers/media/platform/nxp/imx-jpeg/mxc-jpeg.c index 35a7cb936653..b2ea57b45028 100644 --- a/drivers/media/platform/nxp/imx-jpeg/mxc-jpeg.c +++ b/drivers/media/platform/nxp/imx-jpeg/mxc-jpeg.c @@ -2145,12 +2145,14 @@ static int mxc_jpeg_probe(struct platform_device *pdev) jpeg->clk_ipg = devm_clk_get(dev, "ipg"); if (IS_ERR(jpeg->clk_ipg)) { dev_err(dev, "failed to get clock: ipg\n"); + ret = PTR_ERR(jpeg->clk_ipg); goto err_clk; } jpeg->clk_per = devm_clk_get(dev, "per"); if (IS_ERR(jpeg->clk_per)) { dev_err(dev, "failed to get clock: per\n"); + ret = PTR_ERR(jpeg->clk_per); goto err_clk; } -- 2.35.1