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 5A1B124337C; Tue, 20 May 2025 13:55:22 +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=1747749322; cv=none; b=Lio2ZOmCd5/M6GJsCxlCQ7Q7/ph7hGbhfZWP+XgWTwjkJtdgjkTCmwjaAThRgL71imuB63i3fsVMuQOiNgxYfZPyW262kHKyLCfxPXRPyKING/xjVuFFjB0/5DKXJysGpV1H30wp6wht0OSMVUUIdHsxPZq1OVG8k7EugNRgfcY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1747749322; c=relaxed/simple; bh=CDXOXUDE7167CAsX3b8jBkC/cDfA/qwRXb68xwQTf14=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=L3tOAcF84EHARnXDzUiPzo8VewlJhscGSA6y/UDRl9WdM6laic1ut6Q0gPGSY8WPzANXymyO5T2W7jfkSKhOkVcOGz9BwGoH49BC7DBR+8D55tI8/meQe3wuodX5KzONItZB/yiX/g7C9PW35pRNjW0fHZZgGbmXtfcMgFCQiKM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=bqrinhJP; 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="bqrinhJP" Received: by smtp.kernel.org (Postfix) with ESMTPSA id C7CD4C4CEE9; Tue, 20 May 2025 13:55:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1747749322; bh=CDXOXUDE7167CAsX3b8jBkC/cDfA/qwRXb68xwQTf14=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=bqrinhJP8Wmk2z/yh2krJBXOPLPxQZCB3mvFkqn/s10tns0T3uRkEmAZBPo7ez6hM 45WfvUCce9xoj44Bg4IWI7Xq3zz5qm/wvNJhugA+a+h9Y8RyHje6KN52mF4DTmUc+1 PGxAToVCUyvTHDxp8de0hi5E6EY21TDrHaHNZs5k= 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 5.15 38/59] tracing: samples: Initialize trace_array_printk() with the correct function Date: Tue, 20 May 2025 15:50:29 +0200 Message-ID: <20250520125755.365863150@linuxfoundation.org> X-Mailer: git-send-email 2.49.0 In-Reply-To: <20250520125753.836407405@linuxfoundation.org> References: <20250520125753.836407405@linuxfoundation.org> User-Agent: quilt/0.68 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 5.15-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)) {