From: Avi Kivity Subject: Question re do_switch_stack() Date: Thu, 09 Jun 2005 17:41:53 +0300 Message-ID: <1118328113.15004.28.camel@blast.qumranet.com> Mime-Version: 1.0 Content-Type: text/plain Content-Transfer-Encoding: 7bit Return-path: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org looking at do_stack_switch() (x86-32), I see that the switch is effected by moving the new stack pointer into current->arch.kernel_sp. however, entry.S only looks at kernel_sp in create_bounce_frame, but only if we're not returning into ring 1. how then is the switch caused? obviously the call to do_stack_switch came from ring 1. confused, Avi