From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 001CA374187 for ; Fri, 21 Aug 2026 11:29:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1787311757; cv=none; b=szW4PcwQiKHWQXK0MEqBi6LC5DcPAcSxqQr8K1WUSU5vFHxWAKBYCDzrN7FumiWF20inyW6IzT0Zebi+Yk+QLFMN6PiBMibUfslQNMXgq7n5eAX+MqKUEXpOkfzupgHAtvOFCQYz2ksTE+gbGv+lKgIJ07TRL9fVS4cdwAIzbEk= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1787311757; c=relaxed/simple; bh=rReboDtVWR+LchIn66VCIiRA4RrsNZEU4pEK04rnFMY=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=bAE/OzAuKogjlDchDrb6fBGBLZLVdp7QdwOlfWjjnM3dG+S7xhBB+MTsSQbJ6Btrp+jTO6qaEqN5iCWQ/qLXBS6VnsH/BdacvCpu7BEBqG0R0M2kCT7Sga852gR7fzZCKMbWm2/lJuQ1f8aT1fZAbQflp82khhxniPKxMU02eqE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; dkim=pass (1024-bit key) header.d=arm.com header.i=@arm.com header.b=qS9LZGFo; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=arm.com header.i=@arm.com header.b="qS9LZGFo" Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 8ABFE165C for ; Fri, 21 Aug 2026 04:29:11 -0700 (PDT) Received: from [192.168.0.1] (usa-sjc-imap-foss1.foss.arm.com [10.121.207.14]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 380E83F763 for ; Fri, 21 Aug 2026 04:29:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=arm.com; s=foss; t=1787311755; bh=rReboDtVWR+LchIn66VCIiRA4RrsNZEU4pEK04rnFMY=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=qS9LZGFob5N2nr/6YZVBkxQA3Mj7DQI+zYzw8RZHWvNL8nTbLXqVSKJHTFuR/MNhc JbPa5u3xWPnXnhblLp8CRzgYalQD70iE9RZYrEriv1GTzAdurcvcWu/o3cheUjF97t hJOpWOP2E2ukXHEkC4lLEiieUCvv8udanG5ON5qM= Date: Fri, 21 Aug 2026 12:28:01 +0100 From: Liviu Dudau To: Geert Uytterhoeven Cc: Ryan Chen , Joel Stanley , Stephen Boyd , Brian Masney , Jerome Brunet , Andrew Jeffery , Billy Tsai , Nicolas Ferre , Alexandre Belloni , Claudiu Beznea , Ray Jui , Scott Branden , Broadcom internal kernel review list , Taichi Sugaya , Takao Orito , Linus Walleij , Avi Fishman , Tomer Maimon , Tali Perry , Patrick Venture , Nancy Yuen , Benjamin Fair , Sudeep Holla , Cristian Marussi , David Lechner , Abel Vesa , Peng Fan , Frank Li , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , Paul Cercueil , Santosh Shilimkar , Andrew Lunn , Gregory Clement , Sebastian Hesselbarth , Vladimir Zapolskiy , Heiko Stuebner , Krzysztof Kozlowski , Sylwester Nawrocki , Chanwoo Choi , Peter Griffin , Alim Akhtar , Dinh Nguyen , Viresh Kumar , Maxime Coquelin , Alexandre Torgue , Emilio =?utf-8?B?TMOzcGV6?= , Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Prashant Gaikwad , Thierry Reding , Jonathan Hunter , Kunihiko Hayashi , Masami Hiramatsu , Ulf Hansson , Lorenzo Pieralisi , Michal Simek , Matthias Brugger , linux-clk@vger.kernel.org, linux-aspeed@lists.ozlabs.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, openbmc@lists.ozlabs.org, arm-scmi@vger.kernel.org, imx@lists.linux.dev, linux-mips@vger.kernel.org, linux-renesas-soc@vger.kernel.org, linux-rockchip@lists.infradead.org, linux-samsung-soc@vger.kernel.org, soc@lists.linux.dev, linux-stm32@st-md-mailman.stormreply.com, linux-sunxi@lists.linux.dev, linux-tegra@vger.kernel.org, linux-mediatek@lists.infradead.org Subject: Re: [PATCH 40/45] clk: versatile: Make sure clk_init_data is fully initialized Message-ID: References: <7c480e73222bb51982fb82dc0cc6cd503f2e8b92.1787239813.git.geert+renesas@glider.be> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <7c480e73222bb51982fb82dc0cc6cd503f2e8b92.1787239813.git.geert+renesas@glider.be> On Fri, Aug 21, 2026 at 10:53:50AM +0200, Geert Uytterhoeven wrote: > The clk_init_data structure contains several mutually-exclusive members > for different methods to specify the possible parents of a clock, > prompting drivers to initialize only the members they need. However, > not initializing all members may cause subtle issues, which are only > exposed when CONFIG_INIT_STACK_ALL_PATTERN or CONFIG_INIT_STACK_NONE is > enabled. > > Make sure all members are fully initialized, to avoid such bugs, and to > prevent future breakage when converting drivers to a different method > for specifying the parents. > > Signed-off-by: Geert Uytterhoeven Reviewed-by: Liviu Dudau Best regards, Liviu > --- > Compile-tested only. > --- > drivers/clk/versatile/clk-icst.c | 2 +- > drivers/clk/versatile/clk-sp810.c | 2 +- > drivers/clk/versatile/clk-vexpress-osc.c | 2 +- > 3 files changed, 3 insertions(+), 3 deletions(-) > > diff --git a/drivers/clk/versatile/clk-icst.c b/drivers/clk/versatile/clk-icst.c > index 6bd3db54dd229d28..97a1bfd6cf0ed995 100644 > --- a/drivers/clk/versatile/clk-icst.c > +++ b/drivers/clk/versatile/clk-icst.c > @@ -360,8 +360,8 @@ struct clk *icst_clk_setup(struct device *dev, > { > struct clk *clk; > struct clk_icst *icst; > - struct clk_init_data init; > struct icst_params *pclone; > + struct clk_init_data init = {}; > > icst = kzalloc_obj(*icst); > if (!icst) > diff --git a/drivers/clk/versatile/clk-sp810.c b/drivers/clk/versatile/clk-sp810.c > index b0e69686f7a9a93e..28e5c0cf1fda38e4 100644 > --- a/drivers/clk/versatile/clk-sp810.c > +++ b/drivers/clk/versatile/clk-sp810.c > @@ -86,7 +86,7 @@ static void __init clk_sp810_of_setup(struct device_node *node) > const char *parent_names[2]; > int num = ARRAY_SIZE(parent_names); > char name[12]; > - struct clk_init_data init; > + struct clk_init_data init = {}; > static int instance; > int i; > bool deprecated; > diff --git a/drivers/clk/versatile/clk-vexpress-osc.c b/drivers/clk/versatile/clk-vexpress-osc.c > index 9adbf5c33bd1cada..72e872ec6b7c9b47 100644 > --- a/drivers/clk/versatile/clk-vexpress-osc.c > +++ b/drivers/clk/versatile/clk-vexpress-osc.c > @@ -64,7 +64,7 @@ static const struct clk_ops vexpress_osc_ops = { > > static int vexpress_osc_probe(struct platform_device *pdev) > { > - struct clk_init_data init; > + struct clk_init_data init = {}; > struct vexpress_osc *osc; > u32 range[2]; > int ret; > -- > 2.43.0 > -- ==================== | I would like to | | fix the world, | | but they're not | | giving me the | \ source code! / --------------- ¯\_(ツ)_/¯