Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp2664596ybt; Tue, 16 Jun 2020 11:42:25 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzChOJx7idygUWTOnsvCXGLwBvNwxlD+fWJq54kX6sFkg1YvtLlZGrrYqnu18ccygyUj3gr X-Received: by 2002:a17:906:805a:: with SMTP id x26mr4255813ejw.458.1592332945501; Tue, 16 Jun 2020 11:42:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1592332945; cv=none; d=google.com; s=arc-20160816; b=OWCxEUOgUM0/T/76HucKaHyulAtwBjburckgSW5XRY6W5yiOywmV2dpz0kroA86QKs M1+6+u6cd8XdMEMKoJLll8OGhqgZOJxGOQfSAoq4C/ciLi9IIlMUdOjioDuSwRPiBjZp kDjINynxE51fqTawfiuiVe2C1onnnuCile2dxUxZ2whnlQb+Muob5QoUgTquLJC6vQTD Po6SOgEwKf35ziQjefktnGjb+f7CEsZ/aYCuIQ8qd6aOUcK+O0wVAvjyO0+uF1W94pzL 72kR19cWfHHeX9Vq3tOGD5fUTX09A1LJ5SjV4YAt3pCMxGvoji1d49ZDyYSwwqTnNV3t zsFA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=LbWK89MuCvj1Sl4N39K4jNgkLJl8ySKC6ZW5gbfqTIE=; b=OW6euic/w4UfIvAx2241iESd2cgr24RdUsKf9gN+0zPif7vVIir41idC4eEmL8MlIP n+zrG510VJX5puyX/wiI4EXVCjJEdx4Io2bxHZyQplvCE2/0rDB4pfEeSmA060UtivH2 /xuH5SZgZAsvLOuN611ohhksD6BnV14a+oXv+mB10AVF5pRcS30r2p2WzD5MnxpPwHgm pjk+ErERYZIK9IXWimkoYgiE8u7ycrt2zrV0wEt0GCkOBfKVwljfPlj+rY4RQ0rpErsJ Ksy0AZU9mzIvH+fimKiWgxnI77bWUHZ9/jM4td3C+Te2sWGnquUtStJlJn4PrAFHirZl Bhng== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=Dgp70rXH; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id w23si11577157ejn.709.2020.06.16.11.42.02; Tue, 16 Jun 2020 11:42:25 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=Dgp70rXH; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729941AbgFPShw (ORCPT + 99 others); Tue, 16 Jun 2020 14:37:52 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44676 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728067AbgFPShv (ORCPT ); Tue, 16 Jun 2020 14:37:51 -0400 Received: from mail-pl1-x643.google.com (mail-pl1-x643.google.com [IPv6:2607:f8b0:4864:20::643]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 70DB6C06174E for ; Tue, 16 Jun 2020 11:37:51 -0700 (PDT) Received: by mail-pl1-x643.google.com with SMTP id d8so8761822plo.12 for ; Tue, 16 Jun 2020 11:37:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=LbWK89MuCvj1Sl4N39K4jNgkLJl8ySKC6ZW5gbfqTIE=; b=Dgp70rXHX7fnmUeMFYCfX+qP4dQ0ouFW9JvgEAXf8RQjWuosjN4K2kcoDDx3X6EGCd gqfzfT1evQX/H5CFii9INhsHzWc/0QRxoWNvDEje7IgWDjZAqzWwG4SFM5nnDGXrCvGq oYg/+EWEPEqiUnTNTUA8nUAAYg8FfdFtj7PQc= 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; bh=LbWK89MuCvj1Sl4N39K4jNgkLJl8ySKC6ZW5gbfqTIE=; b=uHxtgvrK9UdKM5NMz7i5EMSBchqEdoLCW7b2nzgB1B4BKNf5EjyfmSe3w025/vAmPd f6nBPJGjDCmX7VV1R9piTO+jpR+yOpPOCPseAYY4ai8mzUc/owXmpcf6blA67Li/+jTv SdClEbcz/USZvgqtPB1H5mjBNXC3sE5ICVmjoeB9rClxZqGOm3rMq9ZSKVYzB770Bohn Ae4uOFvbwYk6MXQ+HgINpa5UW/JGHszSclct2qXKAGyUPWxOIbojmWWxJ9BjoEIVP0PA Og94/6b+KIB2MS4SwHYSQMHtkhfm+CINKDxn+WUF+HqsSpdg6MliTVYYfowHVu/XQ1Bf 7Lrw== X-Gm-Message-State: AOAM531+IqfNf36Wu9hja4BOYYKM60tAh7CTB0rk1bEgjOAJm4EdPVw4 oDTNEaaGPAIQt119pTHBA7m9yg== X-Received: by 2002:a17:902:b58f:: with SMTP id a15mr3308489pls.106.1592332671017; Tue, 16 Jun 2020 11:37:51 -0700 (PDT) Received: from www.outflux.net (smtp.outflux.net. [198.145.64.163]) by smtp.gmail.com with ESMTPSA id a83sm17453213pfa.146.2020.06.16.11.37.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 16 Jun 2020 11:37:50 -0700 (PDT) Date: Tue, 16 Jun 2020 11:37:49 -0700 From: Kees Cook To: Andy Lutomirski Cc: LKML , Christian Brauner , Sargun Dhillon , Tycho Andersen , Jann Horn , "zhujianwei (C)" , Dave Hansen , Matthew Wilcox , Will Drewry , Shuah Khan , Matt Denton , Chris Palmer , Jeffrey Vander Stoep , Aleksa Sarai , Hehuazhen , X86 ML , Linux Containers , LSM List , Linux API Subject: Re: [PATCH 6/8] x86: Provide API for local kernel TLB flushing Message-ID: <202006161136.524AA1C@keescook> References: <20200616074934.1600036-1-keescook@chromium.org> <20200616074934.1600036-7-keescook@chromium.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jun 16, 2020 at 09:59:29AM -0700, Andy Lutomirski wrote: > On Tue, Jun 16, 2020 at 12:49 AM Kees Cook wrote: > > > > The seccomp constant action bitmap filter evaluation routine depends > > on being able to quickly clear the PTE "accessed" bit for a temporary > > allocation. Provide access to the existing CPU-local kernel memory TLB > > flushing routines. > > Can you write a better justification? Also, unless I'm just Er, dunno? That's the entire reason this series needs it. > incompetent this morning, I can't find anyone calling this in the > series. It's in patch 4, seccomp_update_bitmap(): https://lore.kernel.org/lkml/20200616074934.1600036-5-keescook@chromium.org/ -- Kees Cook