Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1363258

Re: [PATCH v2 1/6] x86/mm/pat: Change PAT to support non-default PAT MSR

From Borislav Petkov <bp@suse.de>
Newsgroups linux.kernel
Subject Re: [PATCH v2 1/6] x86/mm/pat: Change PAT to support non-default PAT MSR
Date 2016-03-23 09:50 +0100
Message-ID <rfMEj-Or-29@gated-at.bofh.it> (permalink)
References <rdtw7-7MK-23@gated-at.bofh.it> <rdtw7-7MK-21@gated-at.bofh.it> <rfxOW-7kp-1@gated-at.bofh.it> <rfze1-7c-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Tue, Mar 22, 2016 at 12:35:19PM -0600, Toshi Kani wrote:
> Right.  Will change to "Add support of non-default PAT MSR setting at
> handoff".

Please remove this "handoff" notion from the text. Every hw register is
being handed off to the OS once the kernel takes over so there's no need
to make it special here.

> I'd like to make it clear that this function does not set PAT MSR, unlike
> what pat_init() does.  When CPU supports PAT, it keeps PAT MSR in whatever
> the setting at handoff, and initializes PAT table to match with this
> setting.
> 
> I am open to a better name, but I am afraid that setup_pat() can be
> confusing as if it sets PAT MSR.

So call it init_cache_modes() and rename the current
pat_init_cache_modes() to __init_cache_modes() to denote it is a lower
level helper of the init_cache_modes() one. The init_cache_modes() one
deals with the higher level figuring out of whether PAT is enabled and
if not, preparing the attr bits for emulation. In the end, it calls
__init_cache_modes(). All nice and easy.

-- 
Regards/Gruss,
    Boris.

SUSE Linux GmbH, GF: Felix Imendörffer, Jane Smithard, Graham Norton, HRB 21284 (AG Nürnberg)
-- 

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Re: [PATCH v2 1/6] x86/mm/pat: Change PAT to support non-default PAT  MSR Borislav Petkov <bp@suse.de> - 2016-03-22 18:00 +0100
  Re: [PATCH v2 1/6] x86/mm/pat: Change PAT to support non-default  PAT MSR Toshi Kani <toshi.kani@hpe.com> - 2016-03-22 19:30 +0100
    Re: [PATCH v2 1/6] x86/mm/pat: Change PAT to support non-default PAT  MSR Borislav Petkov <bp@suse.de> - 2016-03-23 09:50 +0100
      Re: [PATCH v2 1/6] x86/mm/pat: Change PAT to support non-default  PAT MSR Toshi Kani <toshi.kani@hpe.com> - 2016-03-23 16:00 +0100
  Re: [PATCH v2 1/6] x86/mm/pat: Change PAT to support non-default  PAT MSR Thomas Gleixner <tglx@linutronix.de> - 2016-03-22 20:30 +0100

csiph-web