Received: by 2002:a25:c205:0:0:0:0:0 with SMTP id s5csp4143798ybf; Tue, 3 Mar 2020 21:15:27 -0800 (PST) X-Google-Smtp-Source: ADFU+vuiioQCY0vVj+3vtYBycAohbEO29nd/CxKssBi808WeLrERB7uUx0cyrIq/WL5tS8usUq7T X-Received: by 2002:a9d:8b5:: with SMTP id 50mr1012579otf.362.1583298927503; Tue, 03 Mar 2020 21:15:27 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1583298927; cv=none; d=google.com; s=arc-20160816; b=CnS8tritCAqvDPSSA1dQsAJ59HasUuLZmNuZjF+Ox8Q2PazNcCGnp1piOdY2Y8/+Sq URndLdNVuJFWd/C4uymVxNVKVLuTM0i6/qI+8g+9jTFG3hyeeTcxUqKXznsCNU0vx/Fz q6xTQS2Q7KdDvqnzKRvizM9WGnbRbuSiRjHDBfrNItXD2pRmtl60cAkwDhM22zmqC2NA VbDDXzAYdTN31d6JQl11/i4rU9uIu8feeVRCbg2jPy3GJTKY1uz7R+oaLV6AwU9gMJ7W TmtAamYyAD6IxGNEl3rDK0I7sHShJWwbjMZ/nQOZ04LSYpSUKAj6ZkoqFd/rOQfrMCm+ z/qQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=AW1It91eB41MJO8tcBMXkpdl3fk8Ujf8yzHplhBGqgE=; b=K6gzYQ43VR5a+APXV/owbbOWpM4AMQYZbwGH/8xZJFljj4f0fBTKQhDv63PlRefkyj eaaT/AaAljFDgEjS8cCc3Dp1X7MG7BHI6NYTmgEcab6n5naVvhR7fzTex4aSO7p6cmpC K9YFiqRoc/y5Wzl+AIpjxFPqfHX1gQAcMh3m0WB/tH5IERPyl47yJGCJ6NymG2117eaF 7zaqPfWtF0Yh6YmgJc2T40WVKGW/CfPKt2ZmUO3ieN2Y9qXYngLVq0ZLdFqasjopkn5N re5daqh98dAgZxer3vK4a3vqH+m95qaAMfaP9IP1c2UDz3HzB6/zhnPQiNyB4FXuvGCA 2rWQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=KPNpz7cv; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id j80si536327oib.144.2020.03.03.21.15.07; Tue, 03 Mar 2020 21:15:27 -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; dkim=pass header.i=@gmail.com header.s=20161025 header.b=KPNpz7cv; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1725825AbgCDFPC (ORCPT + 99 others); Wed, 4 Mar 2020 00:15:02 -0500 Received: from mail-qv1-f67.google.com ([209.85.219.67]:35603 "EHLO mail-qv1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725271AbgCDFPC (ORCPT ); Wed, 4 Mar 2020 00:15:02 -0500 Received: by mail-qv1-f67.google.com with SMTP id u10so266473qvi.2; Tue, 03 Mar 2020 21:15:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=AW1It91eB41MJO8tcBMXkpdl3fk8Ujf8yzHplhBGqgE=; b=KPNpz7cvO23TdqYA/PVi4Bl5I351QFJV4eyXzQmEmMtC/AyQ+OduXCd3sHguKmPKKU LxYp/fPEB5OTW3c31Hb4u2BI3vLUSIIGgspwGCnXB3EfLHZxqGG79XUVBhKgc8zo40Wa IrjyPFvv8rGzOluGbd+tD+J6PRXXX+Ylg+VfJ64PPif0ZiA8IkMQfzxwDHMzsSDlh98F v0w5IN66vUtdYAKFR9LOfEwiksV8tnFxiTg+du+/5Fq3F+iQBHzM8BwEMjiLWZ3wfkgn fbrl4uzw2W+/ohzZsvqv1cESwFa3Z4VMVRxOycGn0eoaPxFReAqrVo7/SSNvV02CSswS H8iQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=AW1It91eB41MJO8tcBMXkpdl3fk8Ujf8yzHplhBGqgE=; b=Vc2ADQdVoGJf0HIpglOmMS6+G6SyAgJhdibxWv5ld5h1wMbGbWBzLbPX5kjONNFqW+ ZBSNfwHxUX5Vb6vUwz/VXGhJu4E9EVIUvzx5fc6rKCn9EKV8vSVaVSoO07okCEhA3Gxg 1dcgcAmLR5RO1uQluN4qsx+tIj9PEL0gKJL5SYusjy3fVCHk3kb2n6zRGQn6+W/UlGuh wL2spZzM5PRg2Lg/OT0lcwtbPVxdNqgYrKTo5PGciEhmmf7HzrRMJmqBMgu5nWruUYLl w5hevchcRsVdTaH8bY0w9Mn4QnhCSuwx7JAz0nC/z5RLakvSoKy7aalXRFLOUZ7jkBW7 WoIQ== X-Gm-Message-State: ANhLgQ14hBGovBcT5bJWr24gOUVRHlQ2OJpf7wi/cjo+HFJQNtvP9aad Xpw9OuRWSl3n7VNjG4g1OXshQmeh+cx0MOuINLo= X-Received: by 2002:a05:6214:8cb:: with SMTP id da11mr733937qvb.228.1583298901139; Tue, 03 Mar 2020 21:15:01 -0800 (PST) MIME-Version: 1.0 References: <20200304015528.29661-1-kpsingh@chromium.org> <20200304015528.29661-7-kpsingh@chromium.org> In-Reply-To: <20200304015528.29661-7-kpsingh@chromium.org> From: Andrii Nakryiko Date: Tue, 3 Mar 2020 21:14:50 -0800 Message-ID: Subject: Re: [PATCH bpf-next v2 6/7] bpf: Add test ops for BPF_PROG_TYPE_TRACING To: KP Singh Cc: linux-security-module@vger.kernel.org, open list , bpf , Alexei Starovoitov , Daniel Borkmann , Paul Turner , Jann Horn , Florent Revest , Brendan Jackman Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Mar 3, 2020 at 5:56 PM KP Singh wrote: > > From: KP Singh > > The current fexit and fentry tests rely on a different program to > exercise the functions they attach to. Instead of doing this, implement > the test operations for tracing which will also be used for > BPF_MODIFY_RETURN in a subsequent patch. > > Also, clean up the fexit test to use the generated skeleton. > > Signed-off-by: KP Singh > --- Acked-by: Andrii Nakryiko > include/linux/bpf.h | 10 +++ > kernel/trace/bpf_trace.c | 1 + > net/bpf/test_run.c | 37 +++++++--- > .../selftests/bpf/prog_tests/fentry_fexit.c | 12 +--- > .../selftests/bpf/prog_tests/fentry_test.c | 14 ++-- > .../selftests/bpf/prog_tests/fexit_test.c | 69 ++++++------------- > 6 files changed, 67 insertions(+), 76 deletions(-) > [...]