Received: by 2002:a05:6358:1087:b0:cb:c9d3:cd90 with SMTP id j7csp1551488rwi; Thu, 27 Oct 2022 17:54:18 -0700 (PDT) X-Google-Smtp-Source: AMsMyM7ui/HUyGex8ABYaKyANtgr7IwyHy8QhHL0GkaELDoyAdLQaMwW/PcjuS/tI2FV3/v/IHzl X-Received: by 2002:a65:5242:0:b0:46e:9bac:178 with SMTP id q2-20020a655242000000b0046e9bac0178mr35776655pgp.300.1666918458274; Thu, 27 Oct 2022 17:54:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666918458; cv=none; d=google.com; s=arc-20160816; b=nflLJwGPF/6167Xs3NYckRCIW60ErfPVidiyNA2kFrooAYUGO4/CQDpkzWkkAS6TlP 9yJMcnQKsc39atxyRZc9NrCPjK8urf2/Waa6WS+o/g49d8zrVr8jDtb5p501CfivPAc9 A5UxEvnZvdCCJas0LnwJEs+w2k/bcQKcI9bJC3Jattg2q7djL8Qvh2GvzuPuMXNUgSua 1fy+g6DYmYgdghJs31Z8Fx64EGrMcxrRbgLIFtORqkdEQSHjaMDMJANxB6rqbqSS2EkU umKaFvUdK25GDG2ilOvbiyu+D7EDlTupoqrikSugWRf1eEAVoKN9A1UA3LqbQU+LXTSx wa8A== 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=ppmtY7LtsXtOE0Tu82bTFljW5h5jmKFRbXlzY6mSSRc=; b=FdR9kpCUqAiO5rkaqysNOUEwd9p50eo+HMNYkuADRT6OtiwzqPAjJ5NyP0NADhS/fS ieFhtIrYWMfGhXMvON1liME80kCgXC1gZ9vxz8abloGgobwUvWfCgG8z8n6sVlr/jjv3 c15QJv2UR7uyGK++rMk8yS+nX1ADuZtZffAXoPh2HypICWQNIqhdkDkathI0WqTmJpLD 2NPSrJo8sXZN/JYmfTzsN1H10ON1ypzk7LW5G1evcg9zZlK9wFBzDTYQcY8SNEbjVBr/ 2gb7mfUwGg0qzGhZjzy+7LEQCQyBa9PJ3ORVNciefZFlXBg8FZ3GDiCsHbfOFfgNcB3u HlbQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=fZwa0wu8; 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 d13-20020a170902654d00b00176ab430a57si2874190pln.546.2022.10.27.17.54.05; Thu, 27 Oct 2022 17:54:18 -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=fZwa0wu8; 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 S235252AbiJ1AlP (ORCPT + 99 others); Thu, 27 Oct 2022 20:41:15 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54200 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234492AbiJ1AlO (ORCPT ); Thu, 27 Oct 2022 20:41:14 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B2A034E60A; Thu, 27 Oct 2022 17:41:13 -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 4EEA66255E; Fri, 28 Oct 2022 00:41:13 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 88078C433C1; Fri, 28 Oct 2022 00:41:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1666917672; bh=ppmtY7LtsXtOE0Tu82bTFljW5h5jmKFRbXlzY6mSSRc=; h=In-Reply-To:References:Subject:From:Cc:To:Date:From; b=fZwa0wu8kngOAvkpJDLYXMhLu2VlibkjLd8PW71+I1VY+PPr5SdTypeHyFBYCQ2aL P/T8l5y5i/Kim4Xpx6pA/kGwPEXRLJEUIrOwo1SIMTTJW6I8ZIRomnbyB4QeFTXLAK D8pNnNY2QANF42lGMg4pahbiiouh2l4Ywlm+pUXoH4L78bZJYkuJBxIiKo55sUsqsj Q2lWbt9ise5/+HC96aekxB5dd0tGYi99Z8AgWjOTP1q89KAFXprll0pOFsUdTNht8a 9cWSE4H6d6Qeu3oEZwvOy9phDNkPdxr/B8dnvkjDe9VUlttIjaVsX8GafAwCJ+llBL iitQ4/aIws+Ew== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable In-Reply-To: <20221017164646.4193618-1-dario.binacchi@amarulasolutions.com> References: <20221017164646.4193618-1-dario.binacchi@amarulasolutions.com> Subject: Re: [PATCH] clk: ti: mux: don't free `parent_names' on kzalloc() failure From: Stephen Boyd Cc: Amarula patchwork , michael@amarulasolutions.com, Dario Binacchi , Greg Kroah-Hartman , Michael Turquette , Tero Kristo , Thomas Gleixner , Tony Lindgren , linux-clk@vger.kernel.org, linux-omap@vger.kernel.org To: Dario Binacchi , linux-kernel@vger.kernel.org Date: Thu, 27 Oct 2022 17:41:09 -0700 User-Agent: alot/0.10 Message-Id: <20221028004112.88078C433C1@smtp.kernel.org> X-Spam-Status: No, score=-7.6 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 Dario Binacchi (2022-10-17 09:46:46) > Although no operation is performed by kfree() on a NULL pointer, it's > however suboptimal and semantically wrong doing it. Passing NULL to kfree() is fine. This is trying to optimize an error path as well. No thanks.