Received: by 2002:ab2:6203:0:b0:1f5:f2ab:c469 with SMTP id o3csp2339303lqt; Mon, 22 Apr 2024 08:08:38 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWcZbvYKMg2yO3TRkTT9UiEdu4JcylP4Cih5WGJ0EQzUeXtlpESNxzf+0H0RBpPMz+e1Jmlld27rxqYwDzRBfffWt2vsZxKHojwb0TTJA== X-Google-Smtp-Source: AGHT+IHLCeuhaiOuTtI+fvbsaF4VbZmwtXjgymnOZdcl64cqVLj38Jav3FNtMJxd3x/MwU2FZZCH X-Received: by 2002:a17:906:33da:b0:a52:56e7:e9c0 with SMTP id w26-20020a17090633da00b00a5256e7e9c0mr7334758eja.7.1713798518011; Mon, 22 Apr 2024 08:08:38 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1713798517; cv=pass; d=google.com; s=arc-20160816; b=robwYCgEV/LMS2pVA7Wx57tUT6ItILJ3Ozrhn8Nc+wmN9ug7o9lml1LMcQQL/pcHCB 8/H406H9lrjtj1nhQhCBUwbPqx3b04aZ+c2e/pc70N3Bl49rdUbyblLX4Xp6rWvDk7Se r3JdUZ7uNG7CfETeR7mJepABHSha/f6wivWAcHD8BZeQ1ZWVdx51DqF3FCdyIW377KVv c/NVWz1j0IuF0C2lzn9mot0HbhKNtXwEtT4SyQmZ2AKLQLvUG//FQI9N08O157iaXxNj wGl/3Hr94RSxM29+aTesCnrFMRKZCw0t+ZdyQzD5EdEO2gCs0kZEhHegFlOc3M72byaf iZZQ== 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:dkim-signature; bh=tbM2v5PmS60dOmeqQsLnya3GablaTTSXwGLgLOtskTs=; fh=jgDiti4SZVvxbx81AM9Hn4RXq+MwnWuieVFnNwjeieY=; b=MXsWWyaDoPgk3w+yK7O6j7N4HP0z/OVpT2L5LarVJEtGxDGaTWknVG13LXmPv867ai BrVIrUhP6klL2pOiigQnUuoVvMwnywUK9cB0rGmzX1wQXTNamZmYGGJm6JcmgjF+lNtS 1GtRpVeBvdc92T3MIlbRWAJeZwJYaNYQSbCMFB8Xi75WMkpFN+7TfZEIOfsUv5qefC2w JAeTeLS+X2KrFOr8N/79lSv7ZG1Mo1LP6sg8MHEhec+zjLcQ9nSWsDLu3jb6sILcKnOu UlP4/Ec6SiqpscHdIkQDd23poFfaOvmHWuRrAsHwXU34Co7nsTs46NLq3BjWWwJ5vffU SfEQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="rzzItP2/"; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-153604-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-153604-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id hp31-20020a1709073e1f00b00a555e98e7b3si6166348ejc.1004.2024.04.22.08.08.37 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 22 Apr 2024 08:08:37 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-153604-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="rzzItP2/"; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-153604-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-153604-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=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 am.mirrors.kernel.org (Postfix) with ESMTPS id B9BB11F21C51 for ; Mon, 22 Apr 2024 15:08:37 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id E0EA0152DF7; Mon, 22 Apr 2024 15:07:37 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="rzzItP2/" 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 0B518152521; Mon, 22 Apr 2024 15:07:36 +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=1713798457; cv=none; b=jNrg5daMbtr018uc5thzZp3PUaWueheWBVUu+8SXpPJMAsq9uYM7wfc3R06vhLNdlb2zYJNGHiGBzg22cbRwYDDJCIY4Icif4j6XsSCyts4R02/m205ugmGlN1GogdWqgsfRHxkeib/+jpSG0TuyiQ6WLdoZUGzmnKWAd1H3bL4= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713798457; c=relaxed/simple; bh=9gL/4UlZA/kW/pnMl559dwLrf9AiXozcEdYa08TOlpQ=; h=Date:From:To:Cc:Subject:Message-Id:In-Reply-To:References: Mime-Version:Content-Type; b=ezmJv5YO8C8So5BHPQmxzDFjimqd6lXs6r+lZRFkATuTyVolfjPM/UqvaF0wp4qIBraqW1nfpzNn5lmofvb1npp7SYsCSrBsdPjPiWeOyt+rWAaxfKZhxJWHG0xUvExVjKPkxJMOp+EztLK3J9jkkSMwBr4SzoJ3pODQdaN75Xg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=rzzItP2/; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id EDCF3C32781; Mon, 22 Apr 2024 15:07:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1713798456; bh=9gL/4UlZA/kW/pnMl559dwLrf9AiXozcEdYa08TOlpQ=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=rzzItP2/R0evw0aSPWMiigg9UGmnBkw8ZN6K7fvAQlb2QKa3Ce12lBg44agS4ncDu sraKypj4jLlWkgwF1Emb9sVIW/0dfDIAJuKwOjqZG4xRzLt2cjqrBwT3ohLq2Gbcy1 AFRTgCS/yEhQoGVaSyGzEXaNbMVF2l0KN94ZRqhH1b0Fxthlr/Fg5CZpKSu4yApjGA momJjKpTW+5egCrYP8fR9ejr4e+ZzVKkavsyULLZprL8JgJDvebd7TztooGnRiB0EW MLjAYgjtDVfuoMMUKBI9bzdmjVr/FkzK3LDArEpGLsK/Pp5+PZeGC018nMgRKKIHOk ndDr6bUXYGtpA== Date: Tue, 23 Apr 2024 00:07:29 +0900 From: Masami Hiramatsu (Google) To: Jiri Olsa Cc: Steven Rostedt , Oleg Nesterov , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , linux-kernel@vger.kernel.org, linux-trace-kernel@vger.kernel.org, linux-api@vger.kernel.org, x86@kernel.org, bpf@vger.kernel.org, Song Liu , Yonghong Song , John Fastabend , Peter Zijlstra , Thomas Gleixner , "Borislav Petkov (AMD)" , Ingo Molnar , Andy Lutomirski Subject: Re: [PATCH 7/7] man2: Add uretprobe syscall page Message-Id: <20240423000729.f1d58443100c3994afca0a7f@kernel.org> In-Reply-To: <20240421194206.1010934-8-jolsa@kernel.org> References: <20240421194206.1010934-1-jolsa@kernel.org> <20240421194206.1010934-8-jolsa@kernel.org> X-Mailer: Sylpheed 3.7.0 (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 Sun, 21 Apr 2024 21:42:06 +0200 Jiri Olsa wrote: > Adding man page for new uretprobe syscall. > > Signed-off-by: Jiri Olsa > --- > man2/uretprobe.2 | 40 ++++++++++++++++++++++++++++++++++++++++ > 1 file changed, 40 insertions(+) > create mode 100644 man2/uretprobe.2 > > diff --git a/man2/uretprobe.2 b/man2/uretprobe.2 > new file mode 100644 > index 000000000000..c0343a88bb57 > --- /dev/null > +++ b/man2/uretprobe.2 > @@ -0,0 +1,40 @@ > +.\" Copyright (C) 2024, Jiri Olsa > +.\" > +.\" SPDX-License-Identifier: Linux-man-pages-copyleft > +.\" > +.TH uretprobe 2 (date) "Linux man-pages (unreleased)" > +.SH NAME > +uretprobe \- execute pending return uprobes > +.SH SYNOPSIS > +.nf > +.B int uretprobe(void) > +.fi > +.SH DESCRIPTION > +On x86_64 architecture the kernel is using uretprobe syscall to trigger > +uprobe return probe consumers instead of using standard breakpoint instruction. > +The reason is that it's much faster to do syscall than breakpoint trap > +on x86_64 architecture. Do we specify the supported architecture as this? Currently it is supported only on x86-64, but it could be extended later, right? This should be just noted as NOTES. Something like "This syscall is initially introduced on x86-64 because a syscall is faster than a breakpoint trap on it. But this will be extended to the architectures whose syscall is faster than breakpoint trap." Thank you, > + > +The uretprobe syscall is not supposed to be called directly by user, it's allowed > +to be invoked only through user space trampoline provided by kernel. > +When called from outside of this trampoline, the calling process will receive > +.BR SIGILL . > + > +.SH RETURN VALUE > +.BR uretprobe() > +return value is specific for given architecture. > + > +.SH VERSIONS > +This syscall is not specified in POSIX, > +and details of its behavior vary across systems. > +.SH STANDARDS > +None. > +.SH NOTES > +.BR uretprobe() > +exists only to allow the invocation of return uprobe consumers. > +It should > +.B never > +be called directly. > +Details of the arguments (if any) passed to > +.BR uretprobe () > +and the return value are specific for given architecture. > -- > 2.44.0 > -- Masami Hiramatsu (Google)