From patchwork Tue Nov 22 20:39:32 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mathieu Desnoyers X-Patchwork-Id: 24583 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp2433118wrr; Tue, 22 Nov 2022 12:53:38 -0800 (PST) X-Google-Smtp-Source: AA0mqf4LbFXWzUBejlh3FgUBj1io8y27pMcCHIMGRvOoMpvFQygNHviye1DtxyrYMSvbmkNbzSVe X-Received: by 2002:a17:902:e48b:b0:17f:799b:297d with SMTP id i11-20020a170902e48b00b0017f799b297dmr5340315ple.72.1669150418025; Tue, 22 Nov 2022 12:53:38 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1669150418; cv=none; d=google.com; s=arc-20160816; b=ELlchnoQajQ7wEkfEWlyk1y+l9ymCKTdpobli8ySO8qHW9K9a1nSu39mdzpOO8BEpc 0l5Azls7vM4nUqKHPCrhKS5LI5ltdipKnD6x1zXFaohhbmcuOaX08IOE8nR0d9KP0E+N 1XuubUzMe3ijXKgGamnxjMH3/pjTv7brR0ZY2YkEFRynp1vtv9QegXNFVLCsV0ut5r16 mz/3IoNz6sjGvPXJKAqLb8aDLIQaoCjBW+dKpDVPigQy/rVWCObqdsBdi1FwGM8g3lma ZpCicjnUn+Q1x9d1I48fTbF+CD8d68X97lSgKlXIHfpFqw7cpey9YatERNP18OHhpflo iMYQ== 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=gw9/6zmsJhWH66XXt290j/s20RG3vp7FP+JN29YAHhk=; b=vrRdtYTZtLH8UrGp3q1lAFnUMS0GracUmemlZb7BbPb6MD58RBfHtQFz16N2hiJgMn wf3c4HdCPZpRYrnQZmsTXjhSfW0EwwopCaDOCljMxky+t6+/jUv3LxTjKROG6VFg1xuQ 0l0HLO8egrRy4E2BLCWKIhEouvzJcucXpt9di/baK8budQo9l1DJMdMlk+p5bQFfvDSl eoEA4hlByc9LgC2M52Xg29/B2gU3D58z7Gp5I2koF7UogpTOKTzg0Q2qnaGpuNq8UPNZ r1q2BAQY4NMN3MheBln7v+0K200bmIRA4a0PlbhNzV0Tzp7a0uE6W1tqhSgmDzjLX3tz zF6g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@efficios.com header.s=smtpout1 header.b=FH7kxxsZ; 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=efficios.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id s5-20020a170902ea0500b0017d8a86e524si8267252plg.506.2022.11.22.12.53.23; Tue, 22 Nov 2022 12:53:38 -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=@efficios.com header.s=smtpout1 header.b=FH7kxxsZ; 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=efficios.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235144AbiKVUm1 (ORCPT + 99 others); Tue, 22 Nov 2022 15:42:27 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46058 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234569AbiKVUlB (ORCPT ); Tue, 22 Nov 2022 15:41:01 -0500 Received: from smtpout.efficios.com (unknown [IPv6:2607:5300:203:b2ee::31e5]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CDBFB716E3; Tue, 22 Nov 2022 12:39:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=efficios.com; s=smtpout1; t=1669149597; bh=O1N2y3vjljIZnKe9A0DWaJyuaE+DJOz1zqwzlJQB/j4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=FH7kxxsZPNpCeWLHljPWd50s3fK1CsH4OXiUxDH0jqtzGiw0TUUBVWGDNuR+tQpct rroSkpWJfrMBtTt8xT9zKWR/lqefUTomiiG+stVJdiEQvrX3bJI6RsfRWx7T2aZhSD m/Jhj69J2E4Nkv7benyo6QmJxAk43hcbZaRUw1iSmeKuhvUZcMW1ckZrTFuZaZC6kA iUMIk0m2QCc0mqNZths82FXge0o/YMfl5Cj6dU2olLZuXPIGPqS31M7w5wD4h3ntKX XQORaOj+SPbuY1DXGDyub5sJAIhj6RZodCmsIkL6QlfX+h9iOF2udmmPFapgNLVpW1 /10GtKzySEgEQ== Received: from localhost.localdomain (192-222-180-24.qc.cable.ebox.net [192.222.180.24]) by smtpout.efficios.com (Postfix) with ESMTPSA id 4NGx2h5jgJzXLV; Tue, 22 Nov 2022 15:39:56 -0500 (EST) From: Mathieu Desnoyers To: Peter Zijlstra Cc: linux-kernel@vger.kernel.org, Thomas Gleixner , "Paul E . McKenney" , Boqun Feng , "H . Peter Anvin" , Paul Turner , linux-api@vger.kernel.org, Christian Brauner , Florian Weimer , David.Laight@ACULAB.COM, carlos@redhat.com, Peter Oskolkov , Alexander Mikhalitsyn , Chris Kennelly , Mathieu Desnoyers Subject: [PATCH 30/30] tracing/rseq: Add mm_numa_cid field to rseq_update Date: Tue, 22 Nov 2022 15:39:32 -0500 Message-Id: <20221122203932.231377-31-mathieu.desnoyers@efficios.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20221122203932.231377-1-mathieu.desnoyers@efficios.com> References: <20221122203932.231377-1-mathieu.desnoyers@efficios.com> MIME-Version: 1.0 X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RDNS_NONE,SPF_HELO_NONE, SPF_PASS autolearn=no 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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1750231068761555829?= X-GMAIL-MSGID: =?utf-8?q?1750231068761555829?= Add the mm_numa_cid field to the rseq_update event, allowing tracers to follow which mm_numa_cid is observed by user-space, and whether negative mm_numa_cid values are visible in case of internal scheduler implementation issues. Signed-off-by: Mathieu Desnoyers --- include/trace/events/rseq.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/include/trace/events/rseq.h b/include/trace/events/rseq.h index 823b47d1ba1e..95f33d2c0714 100644 --- a/include/trace/events/rseq.h +++ b/include/trace/events/rseq.h @@ -18,16 +18,18 @@ TRACE_EVENT(rseq_update, __field(s32, cpu_id) __field(s32, node_id) __field(s32, mm_cid) + __field(s32, mm_numa_cid) ), TP_fast_assign( __entry->cpu_id = raw_smp_processor_id(); __entry->node_id = cpu_to_node(__entry->cpu_id); __entry->mm_cid = task_mm_cid(t); + __entry->mm_numa_cid = task_mm_numa_cid(t); ), - TP_printk("cpu_id=%d node_id=%d mm_cid=%d", __entry->cpu_id, - __entry->node_id, __entry->mm_cid) + TP_printk("cpu_id=%d node_id=%d mm_cid=%d mm_numa_cid=%d", __entry->cpu_id, + __entry->node_id, __entry->mm_cid, __entry->mm_numa_cid) ); TRACE_EVENT(rseq_ip_fixup,