Message ID | 20230119143619.2733236-2-vschneid@redhat.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:eb09:0:0:0:0:0 with SMTP id s9csp364890wrn; Thu, 19 Jan 2023 06:43:25 -0800 (PST) X-Google-Smtp-Source: AMrXdXsIgxRlfVlRmqFamHbsNrIqFg1K1WpKJakOvLq9sp5kD57qbWHdEEdCh5RwYehZA270xkvN X-Received: by 2002:a17:907:1750:b0:7c0:f907:89a2 with SMTP id lf16-20020a170907175000b007c0f90789a2mr10505090ejc.61.1674139405544; Thu, 19 Jan 2023 06:43:25 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1674139405; cv=none; d=google.com; s=arc-20160816; b=KKXleCoJkPbOrMv92S+R6eh3xR0IeYsRpT2hjkZIEHjCAjuaxngvJhHEuQ8Aagl9DH J6KewNXUEQJ93DEP87cf04JBMKEFlsseEynAM8S6fRllnKONe+pICGusu1VzyZHUEPxF pgWXT6wBmrH1ak4rZ0lZqeT+8ayY5z53gHy4rGkoHKco/QYZDt+zWAsz6OCGvfkzrtLF ikTYQswHrLKRNeaPyIB/PQ5r5pOtHjuUbWVJC18LTW1tFOsaTgu0u2EERdIUBrTMyYj1 09CD4+2bZEDCCLPpXsXbo/V0oRkMyofrHREPafmylk255nYQM+HxleY7E1wg2KpzPCi0 01Sg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=sqdAC23AFCpafEftyGbYSrYoVeo5kk0ftc/PmTPLnCU=; b=MPcBah+Xb96UxYaQlqM5KPfCBGPG6qBvoSu7i8Y2L5/R5d/peslmouNycmeJePTwI4 FH5aN1RgTo/7WM5JInGWN5v+wGZoyFu69OdjpXm95jLOYORes/CcDI6M8AeibldIN8dU yWrZO4ykQAMJyFfIcPiZpmxcSM1A1KjZZ7A/ifjklnIz5JqT498fS1aTkP+AnOWFLdMm /zuNONIbe5zZ2xfZWqngKK7MaLF8jRCcN/j74e2uSwfTCODQ/9VbDqZVl42vAjZ7+Aqp 4DcJ6oq8dUNQFsaVjWg70vhUQB7p2XCC2pD3Fmawps5xOb+6fdR4wjhASic/lk5uA8Xv LFWQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=W9+8AyT7; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id q18-20020a056402519200b004854e1d2682si6045636edd.249.2023.01.19.06.42.59; Thu, 19 Jan 2023 06:43:25 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=W9+8AyT7; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231189AbjASOim (ORCPT <rfc822;pfffrao@gmail.com> + 99 others); Thu, 19 Jan 2023 09:38:42 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58096 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230351AbjASOig (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Thu, 19 Jan 2023 09:38:36 -0500 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id ACDD64B495 for <linux-kernel@vger.kernel.org>; Thu, 19 Jan 2023 06:37:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1674139027; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=sqdAC23AFCpafEftyGbYSrYoVeo5kk0ftc/PmTPLnCU=; b=W9+8AyT7F/t5LNlOnvhkQU+zlg3xwKMJW9vppecwOGkg0VFHHIokdbjWDtC5OUm2aGKfY4 lcW4GvEDHmTk2Rf7ZCgKRLBgXV8iOk5cBi3dt/PsCXbogmyVH+g2QHhbweqiETpivHIrh7 V3ZUQkX2D9y/MNwPj6yHUBtzr+AzXTA= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-457-hPiD0RM2Oa6zOe2Q691O6g-1; Thu, 19 Jan 2023 09:37:04 -0500 X-MC-Unique: hPiD0RM2Oa6zOe2Q691O6g-1 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.rdu2.redhat.com [10.11.54.4]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 4585B85CCE1; Thu, 19 Jan 2023 14:37:00 +0000 (UTC) Received: from vschneid.remote.csb (unknown [10.33.36.13]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 2EE5A2026D68; Thu, 19 Jan 2023 14:36:54 +0000 (UTC) From: Valentin Schneider <vschneid@redhat.com> To: linux-alpha@vger.kernel.org, linux-kernel@vger.kernel.org, linux-snps-arc@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-csky@vger.kernel.org, linux-hexagon@vger.kernel.org, linux-ia64@vger.kernel.org, loongarch@lists.linux.dev, linux-mips@vger.kernel.org, openrisc@lists.librecores.org, linux-parisc@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-riscv@lists.infradead.org, linux-s390@vger.kernel.org, linux-sh@vger.kernel.org, sparclinux@vger.kernel.org, linux-xtensa@linux-xtensa.org, x86@kernel.org Cc: Steven Rostedt <rostedt@goodmis.org>, "Paul E. McKenney" <paulmck@kernel.org>, Peter Zijlstra <peterz@infradead.org>, Thomas Gleixner <tglx@linutronix.de>, Sebastian Andrzej Siewior <bigeasy@linutronix.de>, Juri Lelli <juri.lelli@redhat.com>, Daniel Bristot de Oliveira <bristot@redhat.com>, Marcelo Tosatti <mtosatti@redhat.com>, Frederic Weisbecker <frederic@kernel.org>, Ingo Molnar <mingo@redhat.com>, Borislav Petkov <bp@alien8.de>, Dave Hansen <dave.hansen@linux.intel.com>, "H. Peter Anvin" <hpa@zytor.com>, Marc Zyngier <maz@kernel.org>, Mark Rutland <mark.rutland@arm.com>, Russell King <linux@armlinux.org.uk>, Nicholas Piggin <npiggin@gmail.com>, Guo Ren <guoren@kernel.org>, "David S. Miller" <davem@davemloft.net> Subject: [PATCH v4 1/7] trace: Add trace_ipi_send_cpumask() Date: Thu, 19 Jan 2023 14:36:13 +0000 Message-Id: <20230119143619.2733236-2-vschneid@redhat.com> In-Reply-To: <20230119143619.2733236-1-vschneid@redhat.com> References: <20230119143619.2733236-1-vschneid@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 3.1 on 10.11.54.4 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1755462401409754329?= X-GMAIL-MSGID: =?utf-8?q?1755462401409754329?= |
Series |
Generic IPI sending tracepoint
|
|
Commit Message
Valentin Schneider
Jan. 19, 2023, 2:36 p.m. UTC
trace_ipi_raise() is unsuitable for generically tracing IPI sources due to its "reason" argument being an uninformative string (on arm64 all you get is "Function call interrupts" for SMP calls). Add a variant of it that exports a target cpumask, a callsite and a callback. Signed-off-by: Valentin Schneider <vschneid@redhat.com> Reviewed-by: Steven Rostedt (Google) <rostedt@goodmis.org> --- include/trace/events/ipi.h | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+)
diff --git a/include/trace/events/ipi.h b/include/trace/events/ipi.h index 0be71dad6ec03..b1125dc27682c 100644 --- a/include/trace/events/ipi.h +++ b/include/trace/events/ipi.h @@ -35,6 +35,28 @@ TRACE_EVENT(ipi_raise, TP_printk("target_mask=%s (%s)", __get_bitmask(target_cpus), __entry->reason) ); +TRACE_EVENT(ipi_send_cpumask, + + TP_PROTO(const struct cpumask *cpumask, unsigned long callsite, void *callback), + + TP_ARGS(cpumask, callsite, callback), + + TP_STRUCT__entry( + __cpumask(cpumask) + __field(void *, callsite) + __field(void *, callback) + ), + + TP_fast_assign( + __assign_cpumask(cpumask, cpumask_bits(cpumask)); + __entry->callsite = (void *)callsite; + __entry->callback = callback; + ), + + TP_printk("cpumask=%s callsite=%pS callback=%pS", + __get_cpumask(cpumask), __entry->callsite, __entry->callback) +); + DECLARE_EVENT_CLASS(ipi_handler, TP_PROTO(const char *reason),