From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755867AbdKBQgl (ORCPT ); Thu, 2 Nov 2017 12:36:41 -0400 Received: from mga05.intel.com ([192.55.52.43]:19781 "EHLO mga05.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755760AbdKBQgk (ORCPT ); Thu, 2 Nov 2017 12:36:40 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.44,335,1505804400"; d="scan'208";a="168478387" Subject: Re: KAISER memory layout (Re: [PATCH 06/23] x86, kaiser: introduce user-mapped percpu areas) To: Andy Lutomirski References: Cc: "linux-kernel@vger.kernel.org" , "linux-mm@kvack.org" , moritz.lipp@iaik.tugraz.at, Daniel Gruss , michael.schwarz@iaik.tugraz.at, Linus Torvalds , Kees Cook , Hugh Dickins , X86 ML , Borislav Petkov , Josh Poimboeuf From: Dave Hansen Message-ID: <606e6084-baf7-fc45-b2f3-92b78ea7fcad@linux.intel.com> Date: Thu, 2 Nov 2017 09:36:37 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.4.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 11/02/2017 02:41 AM, Andy Lutomirski wrote: > > - The GDT array. > - The IDT. > - The vsyscall page. We can make this be _PAGE_USER. > - The TSS. > - The per-cpu entry stack. Let's make it one page with guard pages > on either side. This can replace rsp_scratch. > - cpu_current_top_of_stack. This could be in the same page as the TSS. > - The entry text. > - The percpu IST (aka "EXCEPTION") stacks. > > That's it. The PEBS/BTS buffers need it too, I think: https://git.kernel.org/pub/scm/linux/kernel/git/daveh/x86-kaiser.git/commit/?h=kaiser-414rc6-20171031&id=97a334906d7853a8109b295ef94f3991418d0c07