From mboxrd@z Thu Jan 1 00:00:00 1970 From: Olaf Hering Subject: Re: [PATCH 2/6] xen/hvm kexec: unregister shutdown+sysrq watches during reboot Date: Mon, 1 Aug 2011 15:01:38 +0200 Message-ID: <20110801130138.GD9956@aepfle.de> References: <20110728195029.GA18283@aepfle.de> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Return-path: Content-Disposition: inline In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Keir Fraser Cc: "xen-devel@lists.xensource.com" , Ian Campbell , Jan Beulich List-Id: xen-devel@lists.xenproject.org On Thu, Jul 28, Keir Fraser wrote: > > Unfortunately do_introduce() is not preprared for that. > > > > On enter, conn->id contains the domain_id, so it errors out early. > > Later it compares domain->conn != conn and does not enter the correct path. > > Oh of course you want to do it from *inside* the guest... > > > If I remove both checks the kexec appears to work ok. > > Is it save to remove both checks? > > Hmm, no. Attached patch would be safer, give it a try. > > And note that it is *dangerous* to reset the domain xenstore connection if > there could be any other concurrent activity on the connection that could > confuse the guest kernel. So doing the reset during kernel bringup might be > safest, there you can do it in the kernel before the whole xenbus subsystem > is fully up. I sent a different xenstored patch which takes DOMID_SELF into account. Olaf