Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 4E17347CC71; Sat, 12 Sep 2026 13:15:02 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1789218903; cv=none; b=n8bFEC3ahUto6C866FOX1MT+pMuHloEAHfgZegyahFh0TL3pJsq2+a4TA7b8yzVak04Fhax1a1r9De4BFiFidCjCpPBX7RxVR075+6nUG71Evy071e4HXNTIrKS/1YXdwvk0CQ6LBthnLMjVcNSPheF5HTr/y++egJixFhE67pk= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1789218903; c=relaxed/simple; bh=XL6ml15P2RrpWIgIqRl310IBGmdPn/CJ2+Yp+AnBoQE=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=EVzAwhw8V7k2hBfP82f2Nas+EUud3G3y1oDFpmMjzygLdKxzPZTZwkjB6sUPyrXx0vrML7YfFwjJxRhsml8ezoWwegC+AC4PqMgXMU9MuEZkqR1hrVdHLeTBXpl0FLriUxC17h2Ax+HeqNyH+oW76Q82IV+xJlHDb0qOmWtL9mg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=g3UQ5Hwb; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="g3UQ5Hwb" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 155B81F000FF; Sat, 12 Sep 2026 13:15:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1789218901; bh=wAXbQfp37rT1rCzOYz8HyTe0I6NrRibqQACEj1dKTic=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=g3UQ5Hwb/U2ABUqa0Y35CnlbITlDjIqNTsA2Rzqox6RAjtzYok02/QcduhfLO2Mkd qVZdEJytPNQEmLUSHq57Z4DRJoPhcXKqSH+yI9/n6E9FaOQLUUetdlyMHIRENqtgwN EXIHTz/yGAU3DgTwQq4YylanVl+sTTaVNyOXjzCg= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Geert Uytterhoeven , Brian Masney , Nobuhiro Iwamatsu , Stephen Boyd , Sasha Levin Subject: [PATCH 6.12 1240/1376] clk: visconti: Make sure clk_init_data is fully initialized Date: Sat, 12 Sep 2026 09:01:06 +0200 Message-ID: <20260912065635.181641112@linuxfoundation.org> X-Mailer: git-send-email 2.55.0 In-Reply-To: <20260912065607.535295758@linuxfoundation.org> References: <20260912065607.535295758@linuxfoundation.org> User-Agent: quilt/0.69 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: patches@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 6.12-stable review patch. If anyone has any objections, please let me know. ------------------ From: Geert Uytterhoeven [ Upstream commit 39c0e6c844a14945040cca4ccf6997792ab764c4 ] 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. visconti_clk_register_gate() fills in init.parent_data, and assumes that init.parent_names is NULL. However, the latter in uninitialized, and thus may cause a crash. Make sure all members are fully initialized, to fix such bugs, and to avoid future breakage when converting drivers to a different method for specifying the parents. Fixes: b4cbe606dc3674b2 ("clk: visconti: Add support common clock driver and reset driver") Signed-off-by: Geert Uytterhoeven Reviewed-by: Brian Masney Reviewed-by: Nobuhiro Iwamatsu Signed-off-by: Stephen Boyd Signed-off-by: Sasha Levin --- drivers/clk/visconti/clkc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/clk/visconti/clkc.c b/drivers/clk/visconti/clkc.c index d0b193b5d0b35..4018d1298880d 100644 --- a/drivers/clk/visconti/clkc.c +++ b/drivers/clk/visconti/clkc.c @@ -81,9 +81,9 @@ static struct clk_hw *visconti_clk_register_gate(struct device *dev, u8 rs_idx, spinlock_t *lock) { + struct clk_init_data init = {}; struct visconti_clk_gate *gate; struct clk_parent_data *pdata; - struct clk_init_data init; struct clk_hw *hw; int ret; -- 2.53.0