Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 56C5FECE58E for ; Thu, 17 Oct 2019 17:26:04 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 3826220872 for ; Thu, 17 Oct 2019 17:26:04 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2440722AbfJQR0E (ORCPT ); Thu, 17 Oct 2019 13:26:04 -0400 Received: from shards.monkeyblade.net ([23.128.96.9]:39068 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728639AbfJQR0D (ORCPT ); Thu, 17 Oct 2019 13:26:03 -0400 Received: from localhost (unknown [IPv6:2603:3023:50c:85e1:5314:1b70:2a53:887e]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) (Authenticated sender: davem-davemloft) by shards.monkeyblade.net (Postfix) with ESMTPSA id E492813AE684A; Thu, 17 Oct 2019 10:26:02 -0700 (PDT) Date: Thu, 17 Oct 2019 13:26:02 -0400 (EDT) Message-Id: <20191017.132602.1403118968555353816.davem@davemloft.net> To: daniel@iogearbox.net Cc: bigeasy@linutronix.de, bpf@vger.kernel.org, tglx@linutronix.de, ast@kernel.org, kafai@fb.com, songliubraving@fb.com, yhs@fb.com, peterz@infradead.org Subject: Re: [PATCH] BPF: Disable on PREEMPT_RT From: David Miller In-Reply-To: <20191017145358.GA26267@pc-63.home> References: <20191017090500.ienqyium2phkxpdo@linutronix.de> <20191017145358.GA26267@pc-63.home> X-Mailer: Mew version 6.8 on Emacs 26.2 Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.5.12 (shards.monkeyblade.net [149.20.54.216]); Thu, 17 Oct 2019 10:26:03 -0700 (PDT) Sender: bpf-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: bpf@vger.kernel.org From: Daniel Borkmann Date: Thu, 17 Oct 2019 16:53:58 +0200 > On Thu, Oct 17, 2019 at 11:05:01AM +0200, Sebastian Andrzej Siewior wrote: >> Disable BPF on PREEMPT_RT because >> - it allocates and frees memory in atomic context >> - it uses up_read_non_owner() >> - BPF_PROG_RUN() expects to be invoked in non-preemptible context > > For the latter you'd also need to disable seccomp-BPF and everything > cBPF related as they are /all/ invoked via BPF_PROG_RUN() ... +1 Right, we can't do this, no way.