Received: by 2002:a05:6358:1087:b0:cb:c9d3:cd90 with SMTP id j7csp6147519rwi; Tue, 18 Oct 2022 08:39:11 -0700 (PDT) X-Google-Smtp-Source: AMsMyM6/jw/HmSgjvnkrw9SfhFxjbchVZW/VkITp+rv6P1h4ZfbRSE5H0F4wMGcI/yPcdH769WLn X-Received: by 2002:a17:902:b94c:b0:178:336f:13d6 with SMTP id h12-20020a170902b94c00b00178336f13d6mr3807213pls.64.1666107551588; Tue, 18 Oct 2022 08:39:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666107551; cv=none; d=google.com; s=arc-20160816; b=msvz8+aMf0BRc9HV7KT3/wsiBG8YjaTE2j1V9g3j6/ns2yJK8Wcb3r5mPU5tSJhlrr GZ8bYTvH2T5foQONrrV47dbzhNhgCEpXGIMLnpBmgq3f/OiM/ZPBEFdmoyi/VtfEFcxq 6DSngL3BqH48kFACWkg560CV56w2HH/Wai6Ry5DsytdPEfOeS7bE5gE+puRyyLkuYBzW Mx3olXGar5+QYY+KABxqMPnwFBHSTz2Fb1ndzyPqKGqLgK41DxoPB28QkPcy3W7XraGB jQ2yNiYF/5Drf/M4EX0DN/NvjFFPsGMGSjU5vPS2YZwbK3P1+AG5rky4V5CT/I/oIlhE nHlw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=/Jc2iz9gJU8Se/iyDqwouPSA9IEWXlRJfXMRqzTgU9U=; b=Qh8aVwQQZdZQFAnOP8MEwx3LRW7MJCYxidU1mysopFNY988URagH4uYzaOsKu7el1o 3D7xFkEh4esm9UPxoky34dOvw9iDMGx9PrKKkY9tZK+7PEQcpDRzJo8B9HxMKz3dgSZ3 EXazsDjTDy5gCZXsSBO3TWe2rY2+YH00mVB6KgEwtetFw+b4r4Rv3g2K4hbEa7UxN+in aeQbvp40VJbCneugjNIcrSiKKxRNPR1iyBakYM2G9VJRSj83kZzYp4gzt8UA9kRSgAzf OatFD5xn5vJFyrV2d+WpSO5UGg13+EOeyFdl7QVyXibyKB+6YiYffB8sUZRzsxwfpC9n plLA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id t187-20020a632dc4000000b0045ec918ad38si16247510pgt.548.2022.10.18.08.38.57; Tue, 18 Oct 2022 08:39:11 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229917AbiJROud (ORCPT + 99 others); Tue, 18 Oct 2022 10:50:33 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39918 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230270AbiJROu0 (ORCPT ); Tue, 18 Oct 2022 10:50:26 -0400 Received: from verein.lst.de (verein.lst.de [213.95.11.211]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F2BF1CAE69 for ; Tue, 18 Oct 2022 07:50:24 -0700 (PDT) Received: by verein.lst.de (Postfix, from userid 2407) id EC75A68C4E; Tue, 18 Oct 2022 16:50:21 +0200 (CEST) Date: Tue, 18 Oct 2022 16:50:21 +0200 From: Christoph Hellwig To: Song Liu Cc: Christoph Hellwig , Song Liu , Linux-MM , lkml , Andrew Morton , X86 ML , Peter Zijlstra , Kernel Team , "Edgecombe, Rick P" , "Hansen, Dave" , "urezki@gmail.com" Subject: Re: [RFC v2 0/4] vmalloc_exec for modules and BPF programs Message-ID: <20221018145021.GC20131@lst.de> References: <20221007234315.2877365-1-song@kernel.org> <20221017072607.GA30977@lst.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.17 (2007-11-01) X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_NONE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Oct 17, 2022 at 04:23:52PM +0000, Song Liu wrote: > > Well, nothing explains what the method is to avoid having memory > > that is mapped writable and executable at the same time, which really > > could use some explanation here (and in the main patch as well). > > Thanks for the feedback. I will add this. > > Does the code look good to you? I personally think patch 1, 2, 4 could > ship with a little more work. I only took a quick look and I'm not sure how the W^X actually works. Yes, it alls into the text poke helpers, but how do these work on less than page sized allocations?