Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756839AbbFPKF7 (ORCPT ); Tue, 16 Jun 2015 06:05:59 -0400 Received: from atrey.karlin.mff.cuni.cz ([195.113.26.193]:50698 "EHLO atrey.karlin.mff.cuni.cz" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750990AbbFPKFt (ORCPT ); Tue, 16 Jun 2015 06:05:49 -0400 Date: Tue, 16 Jun 2015 12:05:46 +0200 From: Pavel Machek To: Denys Vlasenko Cc: Ingo Molnar , Linus Torvalds , Steven Rostedt , Borislav Petkov , "H. Peter Anvin" , Andy Lutomirski , Oleg Nesterov , Frederic Weisbecker , Alexei Starovoitov , Will Drewry , Kees Cook , x86@kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 1/3] x86, acpi: Eliminate saved_eip Message-ID: <20150616100546.GA22928@amd> References: <1434288190-24993-1-git-send-email-dvlasenk@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1434288190-24993-1-git-send-email-dvlasenk@redhat.com> 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 Content-Length: 1159 Lines: 38 > diff --git a/arch/x86/kernel/acpi/wakeup_32.S b/arch/x86/kernel/acpi/wakeup_32.S > index 665c6b7..eef2bd3 100644 > --- a/arch/x86/kernel/acpi/wakeup_32.S > +++ b/arch/x86/kernel/acpi/wakeup_32.S > @@ -31,17 +31,11 @@ wakeup_pmode_return: > > movl %cs:saved_magic, %eax > cmpl $0x12345678, %eax > - jne bogus_magic > - > - # jump to place where we left off > - movl saved_eip, %eax > - jmp *%eax > - > + je ret_point > bogus_magic: Longjump is supposed to flush the prefetch, but hopefully nothing depends on that detail... ... no. https://en.wikibooks.org/wiki/X86_Assembly/Protected_Mode#Entering_Protected_Mode longjump is supposed to be there. Sorry about that. I guess indirect jump is not neccessary, and we should add a comment there. Thanks, Pavel -- (english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/