From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 C17532512E9; Tue, 20 May 2025 14:19:05 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1747750745; cv=none; b=cddThD6Gicngr2ylsAqFvm7JMT3RQM1mTPsFcQhx96hFT2FRPSX/3GclT23iLnyIzcra9+M/OOU+XKy2ZQbuNN7kpRbxFAwB6SNxB4AKV6sLLLO9sqWYXWkly02AyGxcUIs+OkYwaHbWCI86iuI+jLMUOSjxXuePUo8UUXcFBA0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1747750745; c=relaxed/simple; bh=RFQCyXiMQofrbL7nquMLg+EPDSOqDpislfs2wNvjGGk=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=P3pGKn7a3+FOSefc3Y8K5QZ6Z/baf3pojHJXIsPWFgEPd6+xrrxpXTI42otkCe9nLy3L6aRDeuMfc4b8D2AqHid46PRo5SATV/BC0vZlfHsWyOV7ik0UU9E0Vl1uLe4S3MguUc/aqjxFNw56x39iO8rFsIkXSWk0TvddcYhmU0c= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=IMJCjEhB; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="IMJCjEhB" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4095EC4CEE9; Tue, 20 May 2025 14:19:05 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1747750745; bh=RFQCyXiMQofrbL7nquMLg+EPDSOqDpislfs2wNvjGGk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=IMJCjEhB8E30QkunsDxbSschMqVJB2bdnX0z7zEzQCwEz2tfqDRykBPxt4aYzfn/m seh78M3QGY52TO+5KAzf6Vz74EeNeZJmrRq9MEg4AqdrR7lxQU5rQ59tX2jXpZVrwd XcRuhZDPWCvmoAfbLJeBDSCv6uQ16xiiaTxFp/90= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Masami Hiramatsu , Mathieu Desnoyers , Divya Indi , "Steven Rostedt (Google)" Subject: [PATCH 6.14 106/145] tracing: samples: Initialize trace_array_printk() with the correct function Date: Tue, 20 May 2025 15:51:16 +0200 Message-ID: <20250520125814.709555792@linuxfoundation.org> X-Mailer: git-send-email 2.49.0 In-Reply-To: <20250520125810.535475500@linuxfoundation.org> References: <20250520125810.535475500@linuxfoundation.org> User-Agent: quilt/0.68 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: stable@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 6.14-stable review patch. If anyone has any objections, please let me know. ------------------ From: Steven Rostedt commit 1b0c192c92ea1fe2dcb178f84adf15fe37c3e7c8 upstream. When using trace_array_printk() on a created instance, the correct function to use to initialize it is: trace_array_init_printk() Not trace_printk_init_buffer() The former is a proper function to use, the latter is for initializing trace_printk() and causes the NOTICE banner to be displayed. Cc: stable@vger.kernel.org Cc: Masami Hiramatsu Cc: Mathieu Desnoyers Cc: Divya Indi Link: https://lore.kernel.org/20250509152657.0f6744d9@gandalf.local.home Fixes: 89ed42495ef4a ("tracing: Sample module to demonstrate kernel access to Ftrace instances.") Fixes: 38ce2a9e33db6 ("tracing: Add trace_array_init_printk() to initialize instance trace_printk() buffers") Signed-off-by: Steven Rostedt (Google) Signed-off-by: Greg Kroah-Hartman --- samples/ftrace/sample-trace-array.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/samples/ftrace/sample-trace-array.c +++ b/samples/ftrace/sample-trace-array.c @@ -112,7 +112,7 @@ static int __init sample_trace_array_ini /* * If context specific per-cpu buffers havent already been allocated. */ - trace_printk_init_buffers(); + trace_array_init_printk(tr); simple_tsk = kthread_run(simple_thread, NULL, "sample-instance"); if (IS_ERR(simple_tsk)) {