]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commit
x86/mm/pat: Emulate PAT when it is disabled
authorBorislav Petkov <bp@suse.de>
Thu, 4 Jun 2015 16:55:10 +0000 (18:55 +0200)
committerIngo Molnar <mingo@kernel.org>
Sun, 7 Jun 2015 13:28:52 +0000 (15:28 +0200)
commit9cd25aac1f44f269de5ecea11f7d927f37f1d01c
tree00d865f9811556a50b0ece6d840d55ab08fb0ecf
parent9dac6290945142e6b87d9f027edfee676dcfbfda
x86/mm/pat: Emulate PAT when it is disabled

In the case when PAT is disabled on the command line with
"nopat" or when virtualization doesn't support PAT (correctly) -
see

  9d34cfdf4796 ("x86: Don't rely on VMWare emulating PAT MSR correctly").

we emulate it using the PWT and PCD cache attribute bits. Get
rid of boot_pat_state while at it.

Based on a conglomerate patch from Toshi Kani.

Signed-off-by: Borislav Petkov <bp@suse.de>
Reviewed-by: Toshi Kani <toshi.kani@hp.com>
Acked-by: Juergen Gross <jgross@suse.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Andy Lutomirski <luto@amacapital.net>
Cc: Elliott@hp.com
Cc: H. Peter Anvin <hpa@zytor.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Luis R. Rodriguez <mcgrof@suse.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: arnd@arndb.de
Cc: hch@lst.de
Cc: hmh@hmh.eng.br
Cc: konrad.wilk@oracle.com
Cc: linux-mm <linux-mm@kvack.org>
Cc: linux-nvdimm@lists.01.org
Cc: stefan.bader@canonical.com
Cc: yigal@plexistor.com
Link: http://lkml.kernel.org/r/1433436928-31903-3-git-send-email-bp@alien8.de
Signed-off-by: Ingo Molnar <mingo@kernel.org>
arch/x86/include/asm/pat.h
arch/x86/mm/init.c
arch/x86/mm/pat.c
arch/x86/xen/enlighten.c