Received: by 10.223.164.202 with SMTP id h10csp681837wrb; Thu, 9 Nov 2017 12:37:13 -0800 (PST) X-Google-Smtp-Source: ABhQp+Qf0+v/huqRpj6hlCwensGtJ1SFMRlEOnnYaXpc3Yu8FP5cCBajRWXWNDb4wn1PiC1gzYir X-Received: by 10.84.235.201 with SMTP id m9mr1569883plt.94.1510259833391; Thu, 09 Nov 2017 12:37:13 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1510259833; cv=none; d=google.com; s=arc-20160816; b=qR32/6asLfNH4+gc0q/9WC9gs4fXovv/r7G1AqNYwC7YsbQhVnakROmszeXrVvIi6v 5ixvNvu1wr4WhPrkMcloq6uNDYU5KNhuAqgvQ9xFzLtXBNvEmy13/Aovc0Q9li+cNpJ9 GOSEZaJyidxFYzZu4CuhxduJeUIM6IcL5ICD728NhNunCCHFD4C2GTJ/szJYh1f7M/Xg ZVLZjfok8ZN1KsTLT3dQT6ZJHLVhlim0j1Yq07v7mxyly00tVI1kCyvFo0W4T6GXJJJV DUP6OW4hyXFXcYUs9h2poZRj1DyCUrv7sPatCCCg2dYh0qYTozbo6Oo/qchPEMjv855d mzzw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=WEuEuFBgYVUbEK6WSKoOVo62lMAA/G5ZC3cb+xUpCjI=; b=El74+9N2rMg/u9m/gaQY8tihpodYGGku3NjYbC5e9K+RuYqbXXCrPWHyYawcmn+Hu4 CyQEXlWijh1Bsy0/LUdtILJYxBRpEupOotVrsvmH7Tjwf0r0PJnzG4aE+FGjtL24iSmr FUJbmPo7QZjZItg/8IXOZk8hQt2Rg/NdkOTewCkMIPZoh9YqjsOpVZmDCYuFvtzKYsL5 OXmt1b7i/8zLWG3y4KkLg5N3xSKExuTUkZ7L+H6ZN9wZN8ym7CdmsHgwEzuYOFKqbKLJ tdJ/5G2tRYYc7DpiudQVJ9AdRdWSTe4sw4DQl2oI5qFnOTGPnEhPNFMpOfe1ICKTrkyk C0YQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n63si7620857pfb.377.2017.11.09.12.36.59; Thu, 09 Nov 2017 12:37:13 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755265AbdKIUgL (ORCPT + 83 others); Thu, 9 Nov 2017 15:36:11 -0500 Received: from mga04.intel.com ([192.55.52.120]:13031 "EHLO mga04.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753097AbdKIUgH (ORCPT ); Thu, 9 Nov 2017 15:36:07 -0500 Received: from orsmga004.jf.intel.com ([10.7.209.38]) by fmsmga104.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 09 Nov 2017 12:36:06 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.44,370,1505804400"; d="scan'208";a="148048157" Received: from dkusalov-mobl4.amr.corp.intel.com (HELO localhost) ([10.254.117.34]) by orsmga004.jf.intel.com with ESMTP; 09 Nov 2017 12:36:05 -0800 From: Tom Zanussi To: rostedt@goodmis.org Cc: tglx@linutronix.de, mhiramat@kernel.org, namhyung@kernel.org, vedang.patel@intel.com, bigeasy@linutronix.de, joel.opensrc@gmail.com, joelaf@google.com, mathieu.desnoyers@efficios.com, baohong.liu@intel.com, rajvi.jingar@intel.com, julia@ni.com, linux-kernel@vger.kernel.org, linux-rt-users@vger.kernel.org, Tom Zanussi Subject: [PATCH v5 35/37] tracing: Increase trace_recursive_lock() limit for synthetic events Date: Thu, 9 Nov 2017 14:34:06 -0600 Message-Id: <45041a32e0261b55550c87a764631ccd31545630.1510252666.git.tom.zanussi@linux.intel.com> X-Mailer: git-send-email 1.9.3 In-Reply-To: References: In-Reply-To: References: Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Synthetic event generation needs to happen while the current event is still in progress, so add 1 to the trace_recursive_lock() recursion limit to account for that. Because we also want to allow for the possibility of a synthetic event being generated from another synthetic event, add an additional increment for that as well. Signed-off-by: Tom Zanussi --- kernel/trace/ring_buffer.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/kernel/trace/ring_buffer.c b/kernel/trace/ring_buffer.c index 763b3fb..8c862ea 100644 --- a/kernel/trace/ring_buffer.c +++ b/kernel/trace/ring_buffer.c @@ -2589,16 +2589,16 @@ static void rb_commit(struct ring_buffer_per_cpu *cpu_buffer, * IRQ context * NMI context * - * If for some reason the ring buffer starts to recurse, we - * only allow that to happen at most 4 times (one for each - * context). If it happens 5 times, then we consider this a - * recusive loop and do not let it go further. + * If for some reason the ring buffer starts to recurse, we only allow + * that to happen at most 6 times (one for each context, plus possibly + * two levels of synthetic event generation). If it happens 7 times, + * then we consider this a recusive loop and do not let it go further. */ static __always_inline int trace_recursive_lock(struct ring_buffer_per_cpu *cpu_buffer) { - if (cpu_buffer->current_context >= 4) + if (cpu_buffer->current_context >= 6) return 1; cpu_buffer->current_context++; -- 1.9.3 From 1583594907805751171@xxx Thu Nov 09 13:23:11 +0000 2017 X-GM-THRID: 1583534887630724203 X-Gmail-Labels: Inbox,Category Forums,HistoricalUnread