WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] Re: Error reporting capabilities for libxc

To: Keir Fraser <Keir.Fraser@xxxxxxxxxxxx>
Subject: Re: [Xen-devel] Re: Error reporting capabilities for libxc
From: Gerd Hoffmann <kraxel@xxxxxxx>
Date: Tue, 24 Oct 2006 12:26:17 +0200
Cc: Ian Pratt <m+Ian.Pratt@xxxxxxxxxxxx>, Anthony Liguori <aliguori@xxxxxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxx, "Daniel P. Berrange" <berrange@xxxxxxxxxx>
Delivery-date: Tue, 24 Oct 2006 03:26:42 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <C1639666.33BA%Keir.Fraser@xxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <C1639666.33BA%Keir.Fraser@xxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Thunderbird 1.5.0.7 (X11/20060911)
Keir Fraser wrote:
> On 24/10/06 08:47, "Gerd Hoffmann" <kraxel@xxxxxxx> wrote:
> 
>> What number space we are talking about btw?  errno?  something else?
> 
> I think a separate numbering space, where each err number would have some
> number of auxiliary arguments is being suggested, probably with an
> xc_{get,set}_errnum() interface (since the 'errnum' would not be a simple
> scalar so would be a bit of a pain to pass around).

I somehow feel this is a bit overdesigned.  I've just walked through my
domain builder rewrite, trying to assign useful error codes.  After all
there are not that many different cases:

 (1) internal errors (all sorts of sanity checks which normally
     never ever fail except when coding new bugs ;) ).
 (2) out of memory.
 (3) reading some file failed (kernel / initrd / hvmloader / whatelse).
 (4) invalid kernel image (broken elf headers, truncated file, ...).
 (5) incompatible kernel image (pae vs. nonpae, ppc kernel on x86, ...).
 (6) some invalid parameter (such as asking for a feature not supported
     by hypervisor or guest kernel, ...)

And the is only one where a fixed set of parameters specifying in detail
what went wrong somehow makes sense: for #3 this would be the filename
and maybe the reason (EPERM, ENOENT, ...).  For the other ones IMHO only
free text makes sense as detailed description ...

cheers,
  Gerd

-- 
Gerd Hoffmann <kraxel@xxxxxxx>
http://www.suse.de/~kraxel/julika-dora.jpeg

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel