Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp496024ybt; Fri, 19 Jun 2020 06:53:17 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzpT5Z6hA96jwR2r3umN9blGzyOx7RpWLTXXodp2ZUlyxUlYCmhcJ8o/KfRXEZH5ynIyMSt X-Received: by 2002:a50:f9cc:: with SMTP id a12mr3492321edq.227.1592574797497; Fri, 19 Jun 2020 06:53:17 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1592574797; cv=none; d=google.com; s=arc-20160816; b=hUINNhN2vgM95h3snzyha3FaJ2cdXTrqQr9Z1i0aPxT0WS4pqtLyg3GOXE6WMyOAoU K+vn3icLxaOUuiw01gsEvNWcwGeT1uWbL+ax/fZotiGojSEoUUdjRu1icFHvaHkbkj3x 1xlrWvlYrRxeH6JGve1TmASZda1/PoTMVrv0JDf+8/Gkt75FLlVHZSOOXBTbrUZ9kgtC 4lf0GrcoKJVNQS5GwYz6Hb5n3OcTQ2uHU3BwSQgj0pVUPkX03j033YITjwZBOG+MoMOz ADnQW1uAUqlGfLJiRaUfBLqOc4rVbjcKMMHejE2YmpYncO8oUNu41PSVF/zAkZRxTJLJ Jefw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=cs9rHN+ukMIaMJlUYaI39CwkiITSRhR5qkZwx/24CtA=; b=rIFhudFstey2wXnWFSaI7q6Kbft+054lCkBfOtnEqkaLIUbvzHwW5xkZ/u/5gdR8VG SOqqXJS/Uf+HOvwDlkFp0HJMqlw+4kkjLjwJWW77+84JbkS0Pqq5eDb5439tLEi1MofB bd8vQm9hrh7f6itY6YYBV80/dgiIbQyu/I5wsCTkX8fZpKEeYPtzEyMYnDzQqBQeDWZ5 VaMx8WVn1AKHOUSpXuUAF5ztrgVBitx00i2MMJp3njreb5JgO1wdsdkQzIAhLAviniJO qmhtDzDDDTIBBaNegBi33Z65uQ0cE7ebWn65MyMckYCuVStCsdq9KGySmSVsG5PC9HBE MB4Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=f4hvC2zg; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id g8si4096022edy.450.2020.06.19.06.52.55; Fri, 19 Jun 2020 06:53:17 -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=@gmail.com header.s=20161025 header.b=f4hvC2zg; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1733003AbgFSNuy (ORCPT + 99 others); Fri, 19 Jun 2020 09:50:54 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44924 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732996AbgFSNuw (ORCPT ); Fri, 19 Jun 2020 09:50:52 -0400 Received: from mail-vk1-xa43.google.com (mail-vk1-xa43.google.com [IPv6:2607:f8b0:4864:20::a43]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D94B0C06174E for ; Fri, 19 Jun 2020 06:50:51 -0700 (PDT) Received: by mail-vk1-xa43.google.com with SMTP id p187so2305450vkf.0 for ; Fri, 19 Jun 2020 06:50:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=cs9rHN+ukMIaMJlUYaI39CwkiITSRhR5qkZwx/24CtA=; b=f4hvC2zgvY/9Xm1sUqc4FA7w5Er1wnYUj1EeTMHfYU9puCuHxVqQH7WrSj7k3ufm5t cgagqX8+cUX2XNbdblQPQLhRScPrzxVRizVgSKIG3oAFX4UhuiWScrJd95vkJJ1MdpRm yZS0c39FT1PVKug2z7NsJn+qqrwkC9RA+Tm6gYKsuqgpuFX2ahdGVRzcryYFBtdKKVgt DQgMHPZmnq/ll189Oprw11+YkufOB9QBCal1Puh6e1wXZwI67wNJGgp/ucPEIAQheZRi mW+/C2rpQItGCItdBjqZeKN1Oko5lbX7eQbUGMjPb8mxN9JRZWuXCuFXXWPkWBfStHXH f3aw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=cs9rHN+ukMIaMJlUYaI39CwkiITSRhR5qkZwx/24CtA=; b=PTBmaeOnYCQG3h42t+tZbIeZi1dA8c7Tq56TEhydwuk8t0xsfz+riF4/d1kTVoJvR+ MJIqHvQ08a6hM1uf2X4rTB62Y/ejfd6X+O5aRdCu34uG/6FoealMWm6/DOWAIi9ANSbo 5s0t/uWEQAmhYIHssa28io8ZJor3gX+OttvUAIVD6Y/KlGfvz/sEDY96SfTL2USQHWGl AXdLXi7d+W7jqlf3ZJQ7aEb/aqevlKubWcTynRM60hHtHpMJx1A97NVnUtnlV6jrMA9D SE9D+Ii8QPXaw1bXDfyX+SuUzf1uiv2LPq8sbyXq6J0DLWxIHPq7h58i6u5WHN5Kzoe8 qfLA== X-Gm-Message-State: AOAM533shpJLHdI0gFgWQFsCW/zSgKnVlOI2Zg2OlZdu4KX7BpghihlT 4LJ2SnEjpougeMlXt71oN5nAShxW6EDW7AOgVsE= X-Received: by 2002:ac5:ccf0:: with SMTP id k16mr7343756vkn.95.1592574650355; Fri, 19 Jun 2020 06:50:50 -0700 (PDT) MIME-Version: 1.0 References: <20200618210215.23602-1-daniel.gutson@eclypsium.com> <589c89ae-620e-36f8-2be5-4afc727c2911@intel.com> <20200618220139.GH27951@zn.tnic> <20200619074053.GA32683@zn.tnic> <20200619132243.GC32683@zn.tnic> <20200619134432.GE32683@zn.tnic> In-Reply-To: <20200619134432.GE32683@zn.tnic> From: Richard Hughes Date: Fri, 19 Jun 2020 14:50:39 +0100 Message-ID: Subject: Re: [PATCH] Ability to read the MKTME status from userspace To: Borislav Petkov Cc: Daniel Gutson , Dave Hansen , Thomas Gleixner , Ingo Molnar , x86@kernel.org, "H. Peter Anvin" , Arnd Bergmann , Greg Kroah-Hartman , Peter Zijlstra , "David S. Miller" , Rob Herring , Tony Luck , Rahul Tanwar , Xiaoyao Li , Sean Christopherson , Dave Hansen , linux-kernel Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 19 Jun 2020 at 14:44, Borislav Petkov wrote: > Yes, this is what I'm proposing with clearing the flag in /proc/cpuinfo. > The needed information is there: > 1. TME in CPUID > 2. TME *not* in /proc/cpuinfo No, it's not a boolean at all. If the platform disable is a BIOS configuration we don't know if TME isn't available because the CPU doesn't support it or because the firmware has disabled it. In the latter case, a firmware update or firmware configuration change might actually enable it. If the user installs a CPU with TME support and then we tell the user "your system doesn't support TME" then we're going to have some very confused users unless we can differentiate the two cases. > Along with proper ABI definition, design, > documentation and all that belongs to a proper interface with userspace. I don't think Daniels patch was a "final version" and I'm sure follow-ups can add this kind of thing. At the moment it's just people telling him "you don't need this" when as a potential consumer I'm saying we really do. Richard.