From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.8 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5664EC388F9 for ; Sat, 31 Oct 2020 13:09:40 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id F160620791 for ; Sat, 31 Oct 2020 13:09:39 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727445AbgJaNJf (ORCPT ); Sat, 31 Oct 2020 09:09:35 -0400 Received: from mail.kernel.org ([198.145.29.99]:57872 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727211AbgJaNJd (ORCPT ); Sat, 31 Oct 2020 09:09:33 -0400 Received: from gandalf.local.home (cpe-66-24-58-225.stny.res.rr.com [66.24.58.225]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id ADF0A2068D; Sat, 31 Oct 2020 13:09:32 +0000 (UTC) Received: from rostedt by gandalf.local.home with local (Exim 4.94) (envelope-from ) id 1kYqdP-006ClF-1C; Sat, 31 Oct 2020 09:09:31 -0400 Message-ID: <20201031130642.971173960@goodmis.org> User-Agent: quilt/0.66 Date: Sat, 31 Oct 2020 09:06:42 -0400 From: Steven Rostedt To: linux-kernel@vger.kernel.org Cc: Ingo Molnar , Andrew Morton , Miroslav Benes , Josh Poimboeuf , Jiri Kosina , Petr Mladek Subject: [for-linus][PATCH 0/3] tracing/ftrace: trace_printk buffer fix and ftrace recursion fixes Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The indexing of the different context buffers had an off by one error. The recursion protection for ftrace callbacks had two bugs. One that would make NMIs always appear to be recursing The other is trasitions between interrupt context could also cause false positives and miss tracing those functions. Qiujun Huang (1): tracing: Fix out of bounds write in get_trace_buf Steven Rostedt (VMware) (2): ftrace: Fix recursion check for NMI test ftrace: Handle tracing when switching between context ---- kernel/trace/trace.c | 2 +- kernel/trace/trace.h | 26 +++++++++++++++++++++++--- kernel/trace/trace_selftest.c | 9 +++++++-- 3 files changed, 31 insertions(+), 6 deletions(-)