Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp994639ybt; Fri, 19 Jun 2020 20:57:31 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz8Czfh7qP+u7rtDPczGZ7uzhtbPIiF0OPOxOxcEWWFrlpM5wNhizXwxgGji9lxSae4a/x2 X-Received: by 2002:a17:906:9a02:: with SMTP id ai2mr6317484ejc.97.1592625451368; Fri, 19 Jun 2020 20:57:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1592625451; cv=none; d=google.com; s=arc-20160816; b=Yfw4mvsv054lXYBQWUnUB/AYofFWgjqrlJQUpu8atIyoyCPzDyUsadAIKOtm9kUBfj 3tYD91A9JtO1CCAC+pYMBniDCbJVZmWDVQy6RkBUT1f4hhuj5L9Nsv276gjsfl0guZfQ Jt9GCw7Q8QCa/0hHHoMBIfZR2h0LX8M996BN0rQPM6p4rBorJqBsJpbo+tuR562pAv5r PqFDsYtYxprRnI175YRovou3bqfmvsLKM7xdag1ydbqboorKXc0PRuCQiPnmVPy+0PxB 0SjGrX/+E8gJdhVp3b+3UzLpukR+DzRAXPB6XJNdPtrK2eMkDC6dDQTNhYV9A+9YyN24 yUqw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:to:in-reply-to:cc:references:message-id :date:subject:mime-version:from:content-transfer-encoding :dkim-signature; bh=jpB5wP3PIwE7dFDxzA5CoClVFh2E2ceSqx2mQLiEpAM=; b=OsJILMTIohjtT1vxZbZciEjcPsfXg6SN740rPZBUavnCEFXYBPMj4VugQhheYEy9vS 1XSIoLdw6F1f66Sz0amFx9rloXJDTHUnVavZ9fFvMd4oFbYWx7xec6hzov1qo8hPX+/O dzziIeuoiyL5u0+qwvqfbmRmozRLZfbSSYJkIcpd72vlZRwm9cwKHU9u2E8UpmNm2L2t XVthKCs3E+Lc+IJtW7VZrLqDAdu0jBJocYGccrdxcaL1II8SLM84WnNoUoTp3QMCCPGW 0VOYgLTbYY4SAYLvCyIC93ANz7CFt64dmwNAq2gVTArRIxRr4nDA/7UNWSV1jY4AiPOC Cvhw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amacapital-net.20150623.gappssmtp.com header.s=20150623 header.b=q6KwgYq2; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id c18si5229657edt.202.2020.06.19.20.57.09; Fri, 19 Jun 2020 20:57:31 -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=@amacapital-net.20150623.gappssmtp.com header.s=20150623 header.b=q6KwgYq2; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2390486AbgFSQ2d (ORCPT + 99 others); Fri, 19 Jun 2020 12:28:33 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40990 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2394919AbgFSQ2G (ORCPT ); Fri, 19 Jun 2020 12:28:06 -0400 Received: from mail-pj1-x1042.google.com (mail-pj1-x1042.google.com [IPv6:2607:f8b0:4864:20::1042]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CD365C06174E for ; Fri, 19 Jun 2020 09:28:06 -0700 (PDT) Received: by mail-pj1-x1042.google.com with SMTP id jz3so4273712pjb.0 for ; Fri, 19 Jun 2020 09:28:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amacapital-net.20150623.gappssmtp.com; s=20150623; h=content-transfer-encoding:from:mime-version:subject:date:message-id :references:cc:in-reply-to:to; bh=jpB5wP3PIwE7dFDxzA5CoClVFh2E2ceSqx2mQLiEpAM=; b=q6KwgYq2vJOzzV4VWWfYDK11E4HZJbayuZOECWOWVrLf2XcwA/z8IQbFCYxno5VfOK 0l4z1k7x95m+biDZW25sxSwp7Mtv0jgFM0woNZ0PSlX1hE416H8DkB8v63U0DQhaguxN WrYgoKF9xIWJCSVoC9u4whW5+1fGB1OnaHYoHh0+PLKLTmMYlZCCMAKa0N7BGZ7ymNeB XYBbx5godAom4qRjt6gxwrvmOweFAW6zq1spjDhV046ar6wKQNrhWPhDkHoxVwabXRpW 1aXFiofSt2N5/GnL9eNGFuMpGWIiEl2YRK1kUyz6O2scaIoKHZb5UcRv+grUUhFTQNdv cP6Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:content-transfer-encoding:from:mime-version :subject:date:message-id:references:cc:in-reply-to:to; bh=jpB5wP3PIwE7dFDxzA5CoClVFh2E2ceSqx2mQLiEpAM=; b=jbOUQ3JXay3dXgxAyKcZVFPpxHawjaCo6OWbkCOngjeWaGTS34lQ+u4K84nEJ21cic KZlOtg1X2lADBH6c3S8jxUm1ePw/yKXG3J9g2Lf2mPMre6J0AQXFiw1yBToz7VvZ0Txf hCSw709H7cdY54L4huwZ7yt4op7X6Qx+XRt44F044muBDqkn2FVM+aX2xSQEGNss3Y9c CsDYvmjrb1H2LCRVZ2skUPF/IZh5Td0mUY5MM+31KCpGeBEBHlfAxNGzsnDacQEds/OO GTpLbl7WCpgTJrvMa6CDjG4QlqeEBPjnXmfJDr8i+NOLkPhcG2oPThgzG8I4IPmkc4PO KSlQ== X-Gm-Message-State: AOAM532jLg1HZC1Qw8GfLnn7dvYo2WuYRXhom43AwTUmewRTWBWmZeBH /ghuJTdQH8CVMuikt0ud6ZW4NA== X-Received: by 2002:a17:90a:aa88:: with SMTP id l8mr4376953pjq.145.1592584086180; Fri, 19 Jun 2020 09:28:06 -0700 (PDT) Received: from ?IPv6:2601:646:c200:1ef2:ac67:5f51:c66e:4fa6? ([2601:646:c200:1ef2:ac67:5f51:c66e:4fa6]) by smtp.gmail.com with ESMTPSA id c1sm5982052pfo.197.2020.06.19.09.28.05 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 19 Jun 2020 09:28:05 -0700 (PDT) Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable From: Andy Lutomirski Mime-Version: 1.0 (1.0) Subject: Re: [PATCH] Ability to read the MKTME status from userspace Date: Fri, 19 Jun 2020 09:28:03 -0700 Message-Id: <7D245565-78D4-4587-AD5E-3D4E945D5A94@amacapital.net> References: <20200619161752.GG32683@zn.tnic> Cc: Richard Hughes , 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 In-Reply-To: <20200619161752.GG32683@zn.tnic> To: Borislav Petkov X-Mailer: iPhone Mail (17F80) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > On Jun 19, 2020, at 9:17 AM, Borislav Petkov wrote: >=20 > =EF=BB=BFOn Fri, Jun 19, 2020 at 08:48:47AM -0700, Andy Lutomirski wrote: >> Boris, it wouldn=E2=80=99t be totally crazy for cpuinfo to learn to >> distinguish between =E2=80=9Cyour platform has this feature but Linux >> isn=E2=80=99t using it=E2=80=9D and =E2=80=9Cyour platform doesn=E2=80=99= t have this feature >> in the first place=E2=80=9D. And I suppose there=E2=80=99s this extra sil= ly state >> =E2=80=9Cyour platform has this feature, but your firmware didn=E2=80=99t= enable >> it=E2=80=9D. This would be a big job. >=20 > Well, I believe all the kernel can do is supply bits of information - > just like MSRs - and depending on the settings of those bits, userspace > can decide what the situation is. For example: >=20 > bit 0 - CPUID support > bit 1 - BIOS enabled > bit 2 - quirk applied > bit 3 - microcode fixes present > ... >=20 > and so on. >=20 Indeed. > It needs a proper definition though and userspace to say, yes, we want > that and that is useful for us. Maybe the right approach is to just keep this kind of use in mind for when w= e inevitably redo cpu features when Intel ships their hybrid Atom/Core machi= nes. >=20 > Where it ends up is then beside the point - /proc/cpuinfo, > /sys/devices/system/cpu, whatever... >=20 > --=20 > Regards/Gruss, > Boris. >=20 > https://people.kernel.org/tglx/notes-about-netiquette