x86/ldt: Make LDT pgtable free conditional
authorThomas Gleixner <tglx@linutronix.de>
Sun, 31 Dec 2017 15:52:15 +0000 (16:52 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 2 Jan 2018 19:31:17 +0000 (20:31 +0100)
commit57849de13c7da3385611a1b9aca5c6040ef7dfe2
treefcaad1b687171d4579d137cd155b55d8313387f7
parent3e133155f22d59b0085ef63cbcbcfbd96c4d0b70
x86/ldt: Make LDT pgtable free conditional

commit 7f414195b0c3612acd12b4611a5fe75995cf10c7 upstream.

Andy prefers to be paranoid about the pagetable free in the error path of
write_ldt(). Make it conditional and warn whenever the installment of a
secondary LDT fails.

Requested-by: Andy Lutomirski <luto@amacapital.net>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/x86/kernel/ldt.c