Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp23482ybi; Tue, 16 Jul 2019 15:28:59 -0700 (PDT) X-Google-Smtp-Source: APXvYqxwDLgB6rLnvqsfD2FBeNaiQZhDT35sku0achwp5pFiH9bvimT2291NGawXDHsXO0QUvZN5 X-Received: by 2002:a65:63c4:: with SMTP id n4mr36496211pgv.44.1563316138777; Tue, 16 Jul 2019 15:28:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1563316138; cv=none; d=google.com; s=arc-20160816; b=SPHLlRuBkt5RsufHl0V6AjxTtlKfi+S8+xQfhpLzurEBxiutkDx8d4M3qPGnZ67adF NKpAVt8Xk278Ei36lItOopl1LL3ys7VjtwqG71XSXU6cGoTuSIHdx0OvLHihq1owGz5P lqRI49vf83iLaGaRlYAM4b1jHhB+sBHlC2swip69B9vftJdWx02bZhTcQCj0iTNFlyhk cAsLkqdCdNm+otk9lXthTKGkmF7Om0GLBRksCuNFlUBXF17tbzxiAXipYm09n5xjUPWN 9LFk5qi0XwurbKzBVZ5xOvguHmmGu2VOU9cMQ0iSb8PUbRjjB5v0yLol0ay9bZqJUJDe lkPQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=hcjV9uH9o/Tpwbd+n48l2oD9yyltFtf5hW/1E21RjyU=; b=ffEqYQ5CWdWdkRrDtcfaNVmIsmBPbUREYCGrg85BZdwmnZnH+MYJ77MM4nMRdmgUAK vvSBKF7+Un8ThHSBJDNtay07PJLaQqt5+tW04q4Uz2NjzbIA5jJur7+VNLKvIaOrcopj PVirwnJEGCPbFbQ5o2vxY+Byt14Kdz5StByb+kSN5vaHkGyKJ0drpy2o4iwYWRdQTLuL gM1iS/yRUc+tkm4I8B2VJUJZzdzroCxCY6WOu1a6sgf6cNKWNUQU9AdO03k4uP/chCe6 o4EaPL81c4Q3upxEs2CBAMXKt00+0rGKK+MsrvkrLTonKWLaXof8eWDghciUMuvfbpCA F4EQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=Ymf6xo4N; 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 c127si21114367pfc.191.2019.07.16.15.28.42; Tue, 16 Jul 2019 15:28:58 -0700 (PDT) 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=Ymf6xo4N; 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 S2388322AbfGPW05 (ORCPT + 99 others); Tue, 16 Jul 2019 18:26:57 -0400 Received: from mail-pl1-f194.google.com ([209.85.214.194]:45716 "EHLO mail-pl1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728434AbfGPW04 (ORCPT ); Tue, 16 Jul 2019 18:26:56 -0400 Received: by mail-pl1-f194.google.com with SMTP id y8so10826809plr.12; Tue, 16 Jul 2019 15:26:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=hcjV9uH9o/Tpwbd+n48l2oD9yyltFtf5hW/1E21RjyU=; b=Ymf6xo4NrjW2SIVOsZOOqSvetHWupjVmlYrmElXDyHBKCX8ks4YgoT7Anv5Qpom3GA qnP5F7jnSEy+ilw9DoY72QKUnhDhBtQlhoBpsgip8PfmUHXc2eEKy/Yfm0ax8OXHa0Yb MIoHxh045on0dY/ZFz0VdDKW+zMNgxe+lYfouF865NoJ9R4vBJG1R3l14IEacMupMwyA t77qcoozBWRaZlVop7hqq3X3DTIbqnGOvpG9prSTXDu1cc2vYN1NxzhGv/F5OvJZfmBH utVEaG7rHNqfd45NSI7jCq6f9bYsfmufbe6w5OeAJccc6jN6ccfcLte3It6Yh9VJ4ytv 5RFw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=hcjV9uH9o/Tpwbd+n48l2oD9yyltFtf5hW/1E21RjyU=; b=TnjCOu2x/K4ATt6NfCFpCzWPu2n+VRiU1eeu/bTY0ff83Kgu9rm0nflvxFZbtLAXbL ceLBJgQmNyiOIh2vRFntrElA4Dxw5nxd0pWUPhQATJkWUqvlP836vvch813hAJ/ClNjh DIP9PBUhU2FF9mp8ceOFdcuzcEVUmkIsng8R8SJKkLD+plXTWLO4QudVTQdy/fNqjW1H g4TY7Jf1/JR4xL+HkN4bfbBciGnJZE6wS5c6xy3hlQDrmCC54I9MVFhnaKV4s373bh9P eW9/4K3jk0myTQ0lkDlxpAqIM3i3cYhMH5UqGvXupJ0DCfJgetVCwnyxs1sLIUwWFwdb dU/g== X-Gm-Message-State: APjAAAXHlDpLWnQsaVtpx91CqGJxesY7koe2i4Zf6hgZWu0S78fiHcla IEhpZXxNPwjJZXYtsUmhg0I= X-Received: by 2002:a17:902:7894:: with SMTP id q20mr37225250pll.339.1563316015990; Tue, 16 Jul 2019 15:26:55 -0700 (PDT) Received: from ast-mbp.dhcp.thefacebook.com ([2620:10d:c090:200::c7d4]) by smtp.gmail.com with ESMTPSA id l15sm21540039pgf.5.2019.07.16.15.26.53 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 16 Jul 2019 15:26:54 -0700 (PDT) Date: Tue, 16 Jul 2019 15:26:52 -0700 From: Alexei Starovoitov To: Joel Fernandes Cc: linux-kernel@vger.kernel.org, Adrian Ratiu , Alexei Starovoitov , bpf@vger.kernel.org, Brendan Gregg , connoro@google.com, Daniel Borkmann , duyuchao , Ingo Molnar , jeffv@google.com, Karim Yaghmour , kernel-team@android.com, linux-kselftest@vger.kernel.org, Manali Shukla , Manjo Raja Rao , Martin KaFai Lau , Masami Hiramatsu , Matt Mullins , Michal Gregorczyk , Michal Gregorczyk , Mohammad Husain , namhyung@google.com, namhyung@kernel.org, netdev@vger.kernel.org, paul.chaignon@gmail.com, primiano@google.com, Qais Yousef , Shuah Khan , Song Liu , Srinivas Ramana , Steven Rostedt , Tamir Carmeli , Yonghong Song Subject: Re: [PATCH RFC 0/4] Add support to directly attach BPF program to ftrace Message-ID: <20190716222650.tk2coihjtsxszarf@ast-mbp.dhcp.thefacebook.com> References: <20190710141548.132193-1-joel@joelfernandes.org> <20190716205455.iimn3pqpvsc3k4ry@ast-mbp.dhcp.thefacebook.com> <20190716213050.GA161922@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190716213050.GA161922@google.com> User-Agent: NeoMutt/20180223 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jul 16, 2019 at 05:30:50PM -0400, Joel Fernandes wrote: > > I also thought about the pinning idea before, but we also want to add support > for not just raw tracepoints, but also regular tracepoints (events if you > will). I am hesitant to add a new BPF API just for creating regular > tracepoints and then pinning those as well. and they should be done through the pinning as well. > I don't see why a new bpf node for a trace event is a bad idea, really. See the patches for kprobe/uprobe FD-based api and the reasons behind it. tldr: text is racy, doesn't scale, poor security, etc. > tracefs is how we deal with trace events on Android. android has made mistakes in the past as well. > This is a natural extension to that and fits with the security model > well. I think it's the opposite. I'm absolutely against text based apis.