Received: by 2002:a89:d88:0:b0:1fa:5c73:8e2d with SMTP id eb8csp2334470lqb; Mon, 27 May 2024 16:49:23 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCV8/hmcw3IGYIJ9F49yJQd0+TvZwMNM1ZLJawUCDcDGTDmxVQJfMh2uc6wycP88G4wtz/T86NAbwBilA5Dk3BiAF8a6Ap3QVrij2ek5Sw== X-Google-Smtp-Source: AGHT+IEQn7W1Jfd8+DWKgkVHoc4i0QKVs9wBkavYXnWZE0Mfj25wf26/aFAZtRJ488LywqIhtyau X-Received: by 2002:ac8:57ce:0:b0:43a:74d8:8971 with SMTP id d75a77b69052e-43fb0de14bfmr133528331cf.23.1716853763699; Mon, 27 May 2024 16:49:23 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1716853763; cv=pass; d=google.com; s=arc-20160816; b=akZqyGm2cpPDsTB9kJoowyIMWXhgmrCa8y5fsYt8tiaYhIQEFdwAQRa0iZS0Q0KNDe nWxLml/tx/kMa8SZxqlyan7IltRIJszLoKMYthxFysyJTK+YO2/IZC1z8h8dO9UmNK6M wJ3AEvzHIy6pi7fQ9mxZb/hsT/gjd1LQe9VcpKbiMnRQXMNB7M7QCC2sVlXBWtRwdtwh b6HLugJNBaAkfmmStZPAhkH+vwKFyouUP58mPcrf7SBPoCwdw+RIztRteEZtH1Sq9aX2 1SqvffGEFXYQFtXqRqe22dGL+lm5cn3x+V4zaJaehdKsbVSjOXYWX4nmL5I4CNNsFkOQ rDlg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :subject:cc:to:from:date; bh=6f2VSSKNYRSKK4jHso3LkYlLX7w170R5Om5nUHz9nw0=; fh=5T8WQ8oWRVJbnXagEhuJqhP8QOWHpKUKm0h9x/mo4pI=; b=I0jOlORZ3ISsl3BCsb3PJi1czbGWiJh5MYmNWiDLAeJKQGLniwMEZY63yhgaC/4fdv 1mYlsFYgdLTqrkyb+AT/RxpcTYt017H4uOcm0sgr+AfIWY4gLkSH439bVcMARVkGUZt6 k7Eej7p5iLBdGZkjcBUUoQWWttu3KdStLFbztzRacm/wwXver2xXX7eZprtnusDEpChl OdTYJA8/1FkA/h3EfjJAP0yVs9FOOJ0ysmWpmto3K7DJhvd/Y/IPWrGnEDN/Si+ugzNq mChYaARh299NGKoFQDBrUvzlDn1O1KRkorKNS2zlfYzgDD0vKgQdcigqqA4pTz7E5LDq 4e0w==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1); spf=pass (google.com: domain of linux-kernel+bounces-191521-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-191521-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id d75a77b69052e-43fb18ca674si89825421cf.678.2024.05.27.16.49.23 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 27 May 2024 16:49:23 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-191521-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; arc=pass (i=1); spf=pass (google.com: domain of linux-kernel+bounces-191521-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-191521-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 6F0651C21844 for ; Mon, 27 May 2024 23:49:23 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 8032413AD0E; Mon, 27 May 2024 23:49:18 +0000 (UTC) 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 0744817E912; Mon, 27 May 2024 23:49:17 +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=1716853758; cv=none; b=jCnFA1ILNSiv5JJE7bNZwXZOZPhCU9qpANd3rYz/TH6gpNZDdMByo+V9WNmPF7QhaoebX+2VVAY06hJ+Ktw1OF67kEQnGzw7SrLVX9nE1rCH9XyFjqNnYkBLfnqZgoONG0gTqgKH7ENoedBPqU4+plSVlaFYXFkJs1QdNskcfD0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716853758; c=relaxed/simple; bh=5m3EnQ61WrpxnMeU7r0cZtPifAGDeMV0+9Ex++zprw4=; h=Date:From:To:Cc:Subject:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=UTpdUJAtdOrVUYVh6lHfhzVR/HwI5GWQl538m8Y12xfoI+5srdksAkfYtreNc3iaZC7rPrAQxPLWmlZC9QxKJuDvx3NUqgTrpm66CVrRRU3B/QvG18W6M+muJntSRUPE2oLr0tHXlZkpwkj1m8IKI8VFYfT2maUHC9UAO6r6BuQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 93C6EC2BBFC; Mon, 27 May 2024 23:49:16 +0000 (UTC) Date: Mon, 27 May 2024 19:49:14 -0400 From: Steven Rostedt To: Tatsuya S Cc: mhiramat@kernel.org, mark.rutland@arm.com, mathieu.desnoyers@efficios.com, linux-kernel@vger.kernel.org, linux-trace-kernel@vger.kernel.org Subject: Re: [PATCH v2] ftrace: Fix stack trace entry generated by ftrace_pid_func() Message-ID: <20240527194914.2d25c4ec@rorschach.local.home> In-Reply-To: <20240527100916.5737-2-tatsuya.s2862@gmail.com> References: <20240527100916.5737-2-tatsuya.s2862@gmail.com> X-Mailer: Claws Mail 3.17.8 (GTK+ 2.24.33; x86_64-pc-linux-gnu) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit On Mon, 27 May 2024 18:44:56 +0900 Tatsuya S wrote: > On setting set_ftrace_pid, a extra entry generated by ftrace_pid_func() > is shown on stack trace(CONFIG_UNWINDER_FRAME_POINTER=y). > > [004] ..... 68.459382: > => 0xffffffffa00090af > => ksys_read > => __x64_sys_read > => x64_sys_call > => do_syscall_64 > => entry_SYSCALL_64_after_hwframe > > To resolve this issue, increment skip count > in function_stack_trace_call() if pids are set. Just a note, this isn't a "fix" but simply an improvement in output. I'm happy to take this (after testing and more reviewing), but it will be for the next merge window, and with a different subject line. "ftrace: Hide one more entry in stack trace when ftrace_pid is enabled" Or something like that. Thanks, -- Steve