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

Re: [Xen-devel] [PATCH 36/38] libxc: add ARM support to xc_dom (PV domain building)



On 23/07/12 15:11, Ian Campbell wrote:
> 
>>>> diff --git a/tools/libxc/xc_dom_armzimageloader.c 
>>>> b/tools/libxc/xc_dom_armzimageloader.c
>>>> new file mode 100644
>>>> index 0000000..220176d
>>>> --- /dev/null
>>>> +++ b/tools/libxc/xc_dom_armzimageloader.c
>> [...]
>>>> +#include "xg_private.h"
>>>> +#include "xc_dom.h"
>>>> +
>>>> +#include <arpa/inet.h> /* XXX ntohl is not the right function... */
>>>
>>> Yes, you are right, we should write a be32_to_cpu (the ones in Xen, QEMU
>>> and Linux are GPLv2 rather than LGLPv2).
>>
>> I wonder if we can/should just declare that we handle only native endian
>> zImages.
> 
> Except this is used with the DTB and that is what it is. :-(
> 
> We have ./tools/blktap2/drivers/bswap.h already which maybe we can make
> more generic?
> 
> TBH, given this is internal to this one loader I'm very tempted to just
> keep using ntohl and friends.

You will likely need to link to libfdt in the future and you will need
to provide cpu_to_fdt32() and fdt32_to_cpu() etc. implementations (like
include/xen/libfdt/libfdt_env.h for Xen itself).

David

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.