Received: by 10.223.185.116 with SMTP id b49csp2425834wrg; Mon, 5 Mar 2018 02:39:11 -0800 (PST) X-Google-Smtp-Source: AG47ELvqxV05xCr2OThrr0WgF8sNCoa0MOXxMSXHT+MkOM87tDa9LIG5k/RfprDvpoDIr1cfm11i X-Received: by 10.101.93.73 with SMTP id e9mr12066522pgt.264.1520246350886; Mon, 05 Mar 2018 02:39:10 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1520246350; cv=none; d=google.com; s=arc-20160816; b=XCkUkJ+jFivD/2EgWX/f+inxsZJt+D3Q8XxjhJklvLtXPhmS7GFNUxdW/PKjhTOcnt RhZ9JuvI4wBU8lovU7dx9lhOUJVR2SUZMeVk+DVFDXHGUl4quo38rR/QNZbYG3zjfOBJ VGCTzlUAeAcYed1yB36IU1RSEHEhEwf8egIaYjRIXfLpkeVOf6b7c4KPVJ72t0GSpPtn OLEn9tmkImzlTEV8Pc43oFu327u++IczqdlH+FpM8quuYiVpTycblt9C3flkU8TnUlUV hC822OC945FFIdWl5z1HLkW7IcqqcHrwwBg8AuY6PKXEEKoO3y+TWafccA69XSiXBNzP uCfQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=JA4ft/zbEQyrYYEDRQTfooNSsNBYYyu6NoZlpHRNmDU=; b=FYaBTTL6cARoC3hFRQwe/iCYXqyBMcT2i9VhgfAsIqs+kfysFAIippfPQX/NEbSDpj /gyZ0xe2511qZCY2coc/YyP8jowzLTtZcTg7l0RJ0izcJ65SzX7yPsRUstYrEqFhnuMJ VdEuGJrDYIJF8UBlQwg7CyLnoBhBnGi/cfuTqg43j6DOIrf9x04pP3nLoJVeeC94rfUA U3gfCrar0RLcfd7O9XzT14ickqIgXWR/FCOTQX615+yJMXCVLT4adDAmKI/zDo9E/F6n +LrT/c/PDOBm+rCg16luMCKvSkZ/yZbQS96YISzWALkEPpfbLe7EjCWO//AEW7Hlw/Qt 61FQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail (test mode) header.i=@8bytes.org header.s=mail-1 header.b=m+NZHETk; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=8bytes.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r23si8140100pgv.368.2018.03.05.02.38.56; Mon, 05 Mar 2018 02:39:10 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail (test mode) header.i=@8bytes.org header.s=mail-1 header.b=m+NZHETk; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=8bytes.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933731AbeCEK0N (ORCPT + 99 others); Mon, 5 Mar 2018 05:26:13 -0500 Received: from 8bytes.org ([81.169.241.247]:54068 "EHLO theia.8bytes.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932868AbeCEK0J (ORCPT ); Mon, 5 Mar 2018 05:26:09 -0500 Received: by theia.8bytes.org (Postfix, from userid 1000) id 5601F241; Mon, 5 Mar 2018 11:26:05 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=8bytes.org; s=mail-1; t=1520245565; bh=kKXVqUUBaBi5kUHLLwCRA7vB0mWJ71gKMklmglDA7zE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=m+NZHETkqkFPvGNuyQ/i81uqrvGEM/bPDJulaw3UorpvATNXJSJq2W5uE/ytlM2lT LqHV9vjiUOaIuUMDOuvdnJ8TqH3Zf+AZ26R6v0CLbJ7Oin7JrJw79jCOYQwr3qbutz 5NYeATvH8cAIs6zi3qo13KduKFxxHv4jGf1QLbHoscamxbDAppLwbIjzgU/QKFpJEg KsQMtC1ciEd9BIBDMXb7RBzrFYUTDrK7/esK7iRpZ2KRLs0ogpWOS84eJlJAJwfTCH a7ehMrfXt5ppY3NDljoiMif/6W12ffBkXTVBbXGBExjIE+vgXTG2ALAHbNUy2lkKyW QST7pkpKh327w== From: Joerg Roedel To: Thomas Gleixner , Ingo Molnar , "H . Peter Anvin" Cc: x86@kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org, Linus Torvalds , Andy Lutomirski , Dave Hansen , Josh Poimboeuf , Juergen Gross , Peter Zijlstra , Borislav Petkov , Jiri Kosina , Boris Ostrovsky , Brian Gerst , David Laight , Denys Vlasenko , Eduardo Valentin , Greg KH , Will Deacon , aliguori@amazon.com, daniel.gruss@iaik.tugraz.at, hughd@google.com, keescook@google.com, Andrea Arcangeli , Waiman Long , Pavel Machek , jroedel@suse.de, joro@8bytes.org Subject: [PATCH 01/34] x86/asm-offsets: Move TSS_sp0 and TSS_sp1 to asm-offsets.c Date: Mon, 5 Mar 2018 11:25:30 +0100 Message-Id: <1520245563-8444-2-git-send-email-joro@8bytes.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1520245563-8444-1-git-send-email-joro@8bytes.org> References: <1520245563-8444-1-git-send-email-joro@8bytes.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Joerg Roedel These offsets will be used in 32 bit assembly code as well, so make them available for all of x86 code. Signed-off-by: Joerg Roedel --- arch/x86/kernel/asm-offsets.c | 4 ++++ arch/x86/kernel/asm-offsets_64.c | 2 -- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/arch/x86/kernel/asm-offsets.c b/arch/x86/kernel/asm-offsets.c index 76417a9..232152c 100644 --- a/arch/x86/kernel/asm-offsets.c +++ b/arch/x86/kernel/asm-offsets.c @@ -103,4 +103,8 @@ void common(void) { OFFSET(CPU_ENTRY_AREA_entry_trampoline, cpu_entry_area, entry_trampoline); OFFSET(CPU_ENTRY_AREA_entry_stack, cpu_entry_area, entry_stack_page); DEFINE(SIZEOF_entry_stack, sizeof(struct entry_stack)); + + /* Offset for sp0 and sp1 into the tss_struct */ + OFFSET(TSS_sp0, tss_struct, x86_tss.sp0); + OFFSET(TSS_sp1, tss_struct, x86_tss.sp1); } diff --git a/arch/x86/kernel/asm-offsets_64.c b/arch/x86/kernel/asm-offsets_64.c index bf51e51..d2eba73 100644 --- a/arch/x86/kernel/asm-offsets_64.c +++ b/arch/x86/kernel/asm-offsets_64.c @@ -65,8 +65,6 @@ int main(void) #undef ENTRY OFFSET(TSS_ist, tss_struct, x86_tss.ist); - OFFSET(TSS_sp0, tss_struct, x86_tss.sp0); - OFFSET(TSS_sp1, tss_struct, x86_tss.sp1); BLANK(); #ifdef CONFIG_CC_STACKPROTECTOR -- 2.7.4