From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751242AbcEJF7B (ORCPT ); Tue, 10 May 2016 01:59:01 -0400 Received: from mail-wm0-f46.google.com ([74.125.82.46]:34958 "EHLO mail-wm0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751069AbcEJF67 (ORCPT ); Tue, 10 May 2016 01:58:59 -0400 Date: Tue, 10 May 2016 07:58:54 +0200 From: Ingo Molnar To: Yinghai Lu Cc: Kees Cook , Borislav Petkov , Baoquan He , Ingo Molnar , "H. Peter Anvin" , Borislav Petkov , Vivek Goyal , Andy Lutomirski , Lasse Collin , Andrew Morton , Dave Young , "kernel-hardening@lists.openwall.com" , LKML , Linus Torvalds Subject: Re: [PATCH v7 1/9] x86/KASLR: Initialize mapping_info every time Message-ID: <20160510055853.GA2293@gmail.com> References: <1462825332-10505-1-git-send-email-keescook@chromium.org> <1462825332-10505-2-git-send-email-keescook@chromium.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org * Yinghai Lu wrote: > On Mon, May 9, 2016 at 3:23 PM, Kees Cook wrote: > >> The exact reason to have assigning in functions. > >> > >> pgt_data address could be changed during kernel relocation. > >> so can not assigned during compiling time. > > > > Ah-ha, that explains why I had to keep it on the stack. Thanks for the > > clarification! > > My fault, I should put that comment in the code at first place. Ok, could you guys please update the code and the changelog as well, and also rename that horribly named prepare_level4() function? Also, since this code is multi-author, it would be nice to add explicit copyright notices to the new arch/x86/boot/compressed/pagetable.c file, it was originally written by you, then modified by Kees. Something like: /* * Copyright (C) 2015-2016 Yinghai Lu * Copyright (C) 2016 Kees Cook */ Thanks, Ingo