On Mon, Nov 14, 2011 at 11:09:31AM +0000, Stefano Stabellini wrote:
> On Fri, 11 Nov 2011, Konrad Rzeszutek Wilk wrote:
> > > > > + hw_error("Internal error: Invalid write emulation "
> > > > > + "return value[%d]. I/O emulator exit.\n",
> > > > > rc);
> > > >
> > > > Oh. I hadn't realized this, but you are using hw_error. Which is
> > > > calling 'abort'! Yikes. Is there no way to recover from this? Say
> > > > return 0xfffff?
> > >
> > > In qemu-xen-traditionnal, it was an exit(1). I do not know the
> > > consequence of a bad write, and I can not return anythings. So I suppose
> > > that the guest would know that somethings wrong only on the next read.
> > >
> > > Instead of abort();, I can just do nothing and return. Or we could unplug
> > > the device from QEMU.
> > >
> > > Any preference?
> > I think this calls for an experiment. If Linux still functions if you
> > completly
> > unplug the device, then I would say unplug it (b/c in most likelyhood the
> > reason
> > you can't write is b/c the host has unplugged the device).
> It would make sense to try to PCI hot-unplug the device, however
> considering that it requires guest support, it cannot be used to safely
> handle an error like this one. Also it requires some interactions that
> might not be possible anymore at this point.
> I would destroy the domain instead, using a graceful shutdown if
> possible. Something similar to libxl_domain_shutdown.
Sounds good, and we should also print something prudent to the log _why_
we just killed the guest.
Xen-devel mailing list