Re: [PATCH v5 29/32] x86/mm: Add support to encrypt the kernel in-place

2017-05-31 Thread Tom Lendacky
On 5/31/2017 4:51 AM, Borislav Petkov wrote: On Tue, May 30, 2017 at 11:39:07AM -0500, Tom Lendacky wrote: Yes, it's from objtool: arch/x86/mm/mem_encrypt_boot.o: warning: objtool: .text+0xd2: return instruction outside of a callable function Oh, well, let's make it a global symbol then. Who

Re: [PATCH v5 29/32] x86/mm: Add support to encrypt the kernel in-place

2017-05-31 Thread Borislav Petkov
On Tue, May 30, 2017 at 11:39:07AM -0500, Tom Lendacky wrote: > Yes, it's from objtool: > > arch/x86/mm/mem_encrypt_boot.o: warning: objtool: .text+0xd2: return > instruction outside of a callable function Oh, well, let's make it a global symbol then. Who knows, we might have to live-patch it

Re: [PATCH v5 29/32] x86/mm: Add support to encrypt the kernel in-place

2017-05-30 Thread Tom Lendacky
On 5/26/2017 11:25 AM, Borislav Petkov wrote: On Thu, May 25, 2017 at 05:24:27PM -0500, Tom Lendacky wrote: I guess I could do that, but this will probably only end up clearing a single PGD entry anyway since it's highly doubtful the address range would cross a 512GB boundary. Or you can

Re: [PATCH v5 29/32] x86/mm: Add support to encrypt the kernel in-place

2017-05-26 Thread Borislav Petkov
On Thu, May 25, 2017 at 05:24:27PM -0500, Tom Lendacky wrote: > I guess I could do that, but this will probably only end up clearing a > single PGD entry anyway since it's highly doubtful the address range > would cross a 512GB boundary. Or you can compute how many 512G-covering, i.e., PGD

Re: [PATCH v5 29/32] x86/mm: Add support to encrypt the kernel in-place

2017-05-25 Thread Tom Lendacky
On 5/18/2017 7:46 AM, Borislav Petkov wrote: On Tue, Apr 18, 2017 at 04:21:49PM -0500, Tom Lendacky wrote: Add the support to encrypt the kernel in-place. This is done by creating new page mappings for the kernel - a decrypted write-protected mapping and an encrypted mapping. The kernel is