Port-xen archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Xen/Xentools 3.3 Domain-Unnamed



On Tue, 19 Aug 2008 16:52:18 +0200, Manuel Bouyer 
<bouyer%antioche.eu.org@localhost>
wrote:
>> Wouldn't it be easier to use linux compat code, like found in
>> sys/compat/linux/common/linux_errno.h , rather than hardcoding the
> values
>> inside the function?
> 
> This one is the other way round (BSD -> linux).

We could use it the other way around, no?

#include <compat/linux/common/linux_errno.h>

switch(-error) {
...
        case LINUX_ECHILD:
                return ECHILD;
        case LINUX_EAGAIN:
                return EAGAIN;
        case LINUX_ENOMEM:
                return ENOMEM;
...

-- 
Jean-Yves Migeon
jean-yves.migeon%espci.fr@localhost




Home | Main Index | Thread Index | Old Index