lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <efe79c9e-1e31-adb9-8f93-962249bf01bb@suse.com>
Date:   Wed, 31 May 2023 16:20:08 +0200
From:   Juergen Gross <jgross@...e.com>
To:     Borislav Petkov <bp@...en8.de>
Cc:     linux-kernel@...r.kernel.org, x86@...nel.org,
        linux-hyperv@...r.kernel.org, linux-doc@...r.kernel.org,
        mikelley@...rosoft.com, Thomas Gleixner <tglx@...utronix.de>,
        Ingo Molnar <mingo@...hat.com>,
        Dave Hansen <dave.hansen@...ux.intel.com>,
        "H. Peter Anvin" <hpa@...or.com>,
        "K. Y. Srinivasan" <kys@...rosoft.com>,
        Haiyang Zhang <haiyangz@...rosoft.com>,
        Wei Liu <wei.liu@...nel.org>, Dexuan Cui <decui@...rosoft.com>,
        Boris Ostrovsky <boris.ostrovsky@...cle.com>,
        xen-devel@...ts.xenproject.org, Jonathan Corbet <corbet@....net>,
        Andy Lutomirski <luto@...nel.org>,
        Peter Zijlstra <peterz@...radead.org>
Subject: Re: [PATCH v6 00/16] x86/mtrr: fix handling with PAT but without MTRR

On 31.05.23 10:35, Borislav Petkov wrote:
> [    0.018357] MTRR default type: uncachable
> [    0.022347] MTRR fixed ranges enabled:
> [    0.026085]   00000-9FFFF write-back
> [    0.029650]   A0000-BFFFF uncachable
> [    0.033214]   C0000-FFFFF write-protect
> [    0.037039] MTRR variable ranges enabled:
> [    0.041038]   0 base 000000000000000 mask 0003FFC00000000 write-back
> [    0.047383]   1 base 000000400000000 mask 0003FFFC0000000 write-back
> [    0.053730]   2 base 000000440000000 mask 0003FFFF0000000 write-back
> [    0.060076]   3 base 0000000AE000000 mask 0003FFFFE000000 uncachable
> [    0.066421]   4 base 0000000B0000000 mask 0003FFFF0000000 uncachable
> [    0.072768]   5 base 0000000C0000000 mask 0003FFFC0000000 uncachable
> [    0.079114]   6 disabled
> [    0.081635]   7 disabled
> [    0.084156]   8 disabled
> [    0.086677]   9 disabled
> [    0.089203] total RAM covered: 16352M
> [    0.093023] Found optimal setting for mtrr clean up
> [    0.097734]  gran_size: 64K 	chunk_size: 64M 	num_reg: 8  	lose cover RAM: 0G

One other note: why does mtrr_cleanup() think that using 8 instead of 6
variable MTRRs would be an "optimal setting"?

IMO it should replace the original setup only in case it is using _less_
MTRRs than before.

Additionally I believe mtrr_cleanup() would make much more sense if it
wouldn't be __init, but being usable when trying to add additional MTRRs
in the running system in case we run out of MTRRs.

It should probably be based on the new MTRR map anyway...


Juergen

Download attachment "OpenPGP_0xB0DE9DD628BF132F.asc" of type "application/pgp-keys" (3099 bytes)

Download attachment "OpenPGP_signature" of type "application/pgp-signature" (496 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ