Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp55683rwb; Fri, 30 Sep 2022 17:16:05 -0700 (PDT) X-Google-Smtp-Source: AMsMyM47VijCEQROrlRHCNIzJKH38Eg9FFbjkQUDWbizGVWY0b+rZkCklctI/iakfxXpGPD1f/vZ X-Received: by 2002:a17:907:97cf:b0:787:cb0d:daef with SMTP id js15-20020a17090797cf00b00787cb0ddaefmr7425336ejc.158.1664583365054; Fri, 30 Sep 2022 17:16:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1664583365; cv=none; d=google.com; s=arc-20160816; b=R+yLFK9d9pHEvYOgggp6TmjUiDiYs7ymMOTyHUev7nYI2fuj2wfTF4BREVsQ7CoFkc 2mfia/rplRfjdP4QNpTFxvn0YCxCWrgT66bZRksSHyke/KiFFaInJWc4mrgTf0+PBJ7P Nq91nfQeV6Ea5xBvl/GirmRqcxUYiG1eiFKcbqGwXTbJg34sCL/Sueuzlk9hmRTfVQ/+ Dtd5B7E5sm9E88y6j6MNHFs2Gq9aeRvLpPeptt2UxjoUv8RLdAZLl5PJJqDYZqFFCC2S Z0RHc7bjDgjK9bdByEu7Jt3eMDkmZuSQtL1sHsKR32J3b008JHqOHfjcNY0uig7MR2r3 v0qw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:user-agent:date:to:cc:from:subject :references:in-reply-to:content-transfer-encoding:mime-version :dkim-signature; bh=6h0/WOD0NjyIuQeIvVYf0HlwwBVxyfofNLXZkKFjlLA=; b=MiwsF8KwSN6nQncO64/c2qUtBgKghHKgaiaMKs8v54O2VHJwIfq5xbbOTU8/A98tnt D/2KXKj6HZi+4WDyjg9RTIZafGWnXoH94U1K2KYRk3GqbjBD1d0btbLl2SFpT1qOoFju v+shVzIfdYTSOdc6KoWI/XQz/z/090gkHWfwrFcBjsB3RvDOjW7Ins6o+VSAiQaHqvmp UQ/GsSHTOh39u0Y58gyBlcYgoEtwIPzT9ML9C0ou5N84P1B+LFytA7kdTxHAv3jrx5FF aauJS2xOpXZyncn5OlMOaaS/H7HbpxYotaMf05F8Y5t2y0RnnCtf/ls5aBB958ktlwe1 xW/g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=dbUCXa4O; 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=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id hp8-20020a1709073e0800b0078786e168fcsi2717371ejc.452.2022.09.30.17.15.34; Fri, 30 Sep 2022 17:16:05 -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=@kernel.org header.s=k20201202 header.b=dbUCXa4O; 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=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232005AbiJAAGm (ORCPT + 99 others); Fri, 30 Sep 2022 20:06:42 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47652 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229594AbiJAAGk (ORCPT ); Fri, 30 Sep 2022 20:06:40 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 58D382A273; Fri, 30 Sep 2022 17:06:39 -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 dfw.source.kernel.org (Postfix) with ESMTPS id CEC5F62561; Sat, 1 Oct 2022 00:06:38 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 2E6C8C433D6; Sat, 1 Oct 2022 00:06:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1664582798; bh=6h0/WOD0NjyIuQeIvVYf0HlwwBVxyfofNLXZkKFjlLA=; h=In-Reply-To:References:Subject:From:Cc:To:Date:From; b=dbUCXa4OTeQkpemuU+6hMqwTsiuj6DpQAwB8xx0xdcmRKagflGKWU72/y5uzOvMMf Uuz0VaojFfDG2RlJYsWZGz+eVY1FDDGXV43zb/avwCdt09vq5b05fz1t8Wys2EFZ90 qLdA6rUgqX1zyY+fHsegdMpVTtBm9ZHgPaJc/Bjgytq2B9/tavZ1JyH7bpSK8SDXu0 BFVGeeLxmYJEtyUvZdneXxpg6EF6j1YP/uqrWS55z9SL+A8VH+awMvJOBenqGth4dN RwUDU9+ar/BM0tCoh92j/5x4cBZdFqtSj/r8/1ELrtnW5eJWS13pdJLtacD939libA DM53ZKlMLIT5g== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable In-Reply-To: <20220914033206.98046-1-linyujun809@huawei.com> References: <20220914033206.98046-1-linyujun809@huawei.com> Subject: Re: [PATCH -next] clk: imx: scu: fix memleak on platform_device_add() fails From: Stephen Boyd Cc: linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org To: Lin Yujun , abelvesa@kernel.org, aisheng.dong@nxp.com, festevam@gmail.com, kernel@pengutronix.de, linux-imx@nxp.com, mturquette@baylibre.com, s.hauer@pengutronix.de, shawnguo@kernel.org Date: Fri, 30 Sep 2022 17:06:36 -0700 User-Agent: alot/0.10 Message-Id: <20221001000638.2E6C8C433D6@smtp.kernel.org> X-Spam-Status: No, score=-7.2 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 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 Quoting Lin Yujun (2022-09-13 20:32:06) > No error handling is performed when platform_device_add() > fails. Add error processing before return, and modified > the return value. >=20 > Fixes: 77d8f3068c63 ("clk: imx: scu: add two cells binding support") > Signed-off-by: Lin Yujun > --- Reviewed-by: Stephen Boyd