Received: by 10.223.164.202 with SMTP id h10csp7786wrb; Fri, 10 Nov 2017 01:35:59 -0800 (PST) X-Google-Smtp-Source: ABhQp+TypS/X5hZkn33d8idQxBJijvHYWjV5geVV31lxkvT7NNzCPdusD4bHF0XvODrlJp9FXLv5 X-Received: by 10.159.242.1 with SMTP id t1mr3517962plr.411.1510306559370; Fri, 10 Nov 2017 01:35:59 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1510306559; cv=none; d=google.com; s=arc-20160816; b=vwCIVbFLHeTstm8UZw77oi30Kpx63DLpoR09QX4vYUV3i2yDWQmAtT+fvwM6r+MBxi 8lLW03TiG9ErRuH8dCw+uGrFk4BLlEoXOF0Gp66EAWUGr6r6LP3VPjGeV2tPNi4Hnhow QgSQgxJ9Zq/DHe54J8uEaH6xan0ZazImYu5HDHINmpd+EZy0FoQ9XgncT1KljvQxTiNv SLHrj3N78J//4Xf3U2Q1dNzgJParv6WNK/mSR28IBNbliRgn50xhBRZka1LrQX6Rnkgp OWcQzNoQAsT7fKURln93IGidyfqhHAxKD1HXyGzDVQY94o9Pv88dQ479swlqZMWkQMD6 APNA== 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:arc-authentication-results; bh=YQddCqH4ZPzQ7MR1ZIgc1qfIhNWZLlT8avi8Y6/oFJA=; b=bmUVNI5pWxaucoAw9HXbpX7v2mW99aB8sDEtJ/9TRlohbdQ7LKPUKFv+hCzJsBd4G5 K4rGq+hUajPTTE5ip+zp5xO6P8E4y0/z573IRgfd+JFPfHB0ug/TP/sN8lX6x09xMTMq 1wjXj8J0vx0HZfwIuRh0X7puSbQ2IeybTC+tQuaunA3ZkyUQx7D7saBXZU9RQNYhHSCy Jf68b3tneemsyKJGdIGwJJycuV30IZu14LpJvd7fbEldjEugE5QOi4VYYqfFXLh3a13f 1pP2L+vU5LQ/IrthYH+3/1CPr1vV2UjYSkP5l7+1OmTG6m6ikXoqocN9oP9/wcmdWP0U hRgA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=U1TWDupX; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n61si7093652plb.667.2017.11.10.01.35.46; Fri, 10 Nov 2017 01:35:59 -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=fail header.i=@gmail.com header.s=20161025 header.b=U1TWDupX; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751664AbdKJJfF (ORCPT + 81 others); Fri, 10 Nov 2017 04:35:05 -0500 Received: from mail-wr0-f195.google.com ([209.85.128.195]:47323 "EHLO mail-wr0-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751063AbdKJJfD (ORCPT ); Fri, 10 Nov 2017 04:35:03 -0500 Received: by mail-wr0-f195.google.com with SMTP id k61so8043272wrc.4; Fri, 10 Nov 2017 01:35:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=YQddCqH4ZPzQ7MR1ZIgc1qfIhNWZLlT8avi8Y6/oFJA=; b=U1TWDupXmWEFPu9IxMYxZLCeP621SppiPV5dWMLvnkl+Tg8cd8ULdDUviDwdrm+6Lz BwdbuuDMLFEmPouaMiDDvA/k9SxsU/ZFB/xTRYCqQVYtpL3rlaKNigQgVGdoUMC/shU3 xxbVqP5yNgc3TVdfgGNfKC8qi78pWUcq2K0CXfs1DCDLlP9YS20/oMhcgf1tWMe+OMZm kmGskIwNDcoLNVQfTE03VZumxELBSSWYCG/pOn092Oq7BXm9ySq9XXxsdXy7BPcEjLQ9 v9U2LNMB6Xch1FMG5m8aAMkXx8fZcNEhVL+Ae0/Gvkm8Zb6zPU7a0ZgNoGuDZRua1t/p XxaQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:date:from:to:cc:subject:message-id :references:mime-version:content-disposition:in-reply-to:user-agent; bh=YQddCqH4ZPzQ7MR1ZIgc1qfIhNWZLlT8avi8Y6/oFJA=; b=uCReYVhDbdHLn5SZH/RUXknHdFs2wUdpAKvcvnv8mdxevnXXtW0GaybmVO9btbg5pq 5QNLWdqP3Gah/HfsQ968V0kZx4CzYOmNINoYqPkGyaInfcuKYXbjVVg4ONs6fAys4A3b KWZjyx2h2wb7zXXBKhpAjuMn5IPTKfWL4xuqudnCooC0rk+kMuZASSxRT/j3dFF/gVOJ 3OjOSa5NnNq7xOBFxWlJIDIRyWl4PQN841vs2OF2CpKjRxzJB4WnjPHy27AsabysiDbT puSgMLENPIf2p33t2ShcX975HldQ+RcdNUSImFlwyjbOab3Qj+fZY9vk4JXfdy5RVqZG O/KA== X-Gm-Message-State: AJaThX4D/U381CF9XmGf3w+Wam7yZvD2+yBwTQeBINB15WnKQZ8asWnj IWRvMJsR9BGMCkQo2S7yvTw= X-Received: by 10.223.136.92 with SMTP id e28mr2771340wre.36.1510306502209; Fri, 10 Nov 2017 01:35:02 -0800 (PST) Received: from gmail.com (2E8B0CD5.catv.pool.telekom.hu. [46.139.12.213]) by smtp.gmail.com with ESMTPSA id f6sm2447279wre.66.2017.11.10.01.35.01 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 10 Nov 2017 01:35:01 -0800 (PST) Date: Fri, 10 Nov 2017 10:34:59 +0100 From: Ingo Molnar To: Josef Bacik Cc: rostedt@goodmis.org, mingo@redhat.com, davem@davemloft.net, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, ast@kernel.org, kernel-team@fb.com, daniel@iogearbox.net, Josef Bacik Subject: Re: [PATCH 1/2] bpf: add a bpf_override_function helper Message-ID: <20171110093459.w2pvo3ntkwbmgnha@gmail.com> References: <1510086523-8859-1-git-send-email-josef@toxicpanda.com> <1510086523-8859-2-git-send-email-josef@toxicpanda.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1510086523-8859-2-git-send-email-josef@toxicpanda.com> User-Agent: NeoMutt/20170609 (1.8.3) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org * Josef Bacik wrote: > @@ -551,6 +578,10 @@ static const struct bpf_func_proto *kprobe_prog_func_proto(enum bpf_func_id func > return &bpf_get_stackid_proto; > case BPF_FUNC_perf_event_read_value: > return &bpf_perf_event_read_value_proto; > + case BPF_FUNC_override_return: > + pr_warn_ratelimited("%s[%d] is installing a program with bpf_override_return helper that may cause unexpected behavior!", > + current->comm, task_pid_nr(current)); > + return &bpf_override_return_proto; So if this new functionality is used we'll always print this into the syslog? The warning is also a bit passive aggressive about informing the user: what unexpected behavior can happen, what is the worst case? Thanks, Ingo From 1583469275288674532@xxx Wed Nov 08 04:06:18 +0000 2017 X-GM-THRID: 1583463755336960738 X-Gmail-Labels: Inbox,Category Forums,HistoricalUnread