[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific
From: |
Cédric Le Goater |
Subject: |
Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific endianness |
Date: |
Wed, 5 Oct 2016 19:17:10 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.3.0 |
On 10/05/2016 04:20 PM, Peter Maydell wrote:
> On 5 October 2016 at 07:00, Cédric Le Goater <address@hidden> wrote:
>> On 10/05/2016 03:53 PM, Peter Maydell wrote:
>>> Which tswap? Last time I worked through the stack of
>>> what happens I thought that we had the right set of
>>> swaps in the right places.
>>
>> The one I am talking about are under qtest_process_command(),
>> see below.
>
> Those are correct and required, and they do not change
> the overall behaviour of the system depending on the host
> endianness. (They convert 32-bit values to "bag of
> bytes in guest order" which is what the cpu_physical_memory_*
> functions want.)
>
> https://lists.gnu.org/archive/html/qemu-arm/2016-07/msg00037.html
> is the explanation from last time around, I think.
>
> If your test is giving different answers on different
> host endiannesses, it is presumably because it is
> incorrectly issuing different readl/etc commands
> in the two cases.
OK. I think my brain is starting to see things from the right
angle.
Let's try that : my test is simulating a Little Endian CPU which
is writing a Big Endian value, so it *always* needs to bswap()
that value. cpu_to_be32 is incorrect as it implies the endianness
of the host which can be wrong (when running BE).
The qtest layer is a just fixing layer.
Thanks,
C.
- Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific endianness, (continued)
- Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific endianness, Laurent Vivier, 2016/10/04
- Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific endianness, Cédric Le Goater, 2016/10/04
- Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific endianness, Paolo Bonzini, 2016/10/04
- Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific endianness, David Gibson, 2016/10/04
- Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific endianness, Cédric Le Goater, 2016/10/05
- Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific endianness, Peter Maydell, 2016/10/05
- Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific endianness, Cédric Le Goater, 2016/10/05
- Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific endianness, Peter Maydell, 2016/10/05
- Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific endianness, Cédric Le Goater, 2016/10/05
- Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific endianness, Peter Maydell, 2016/10/05
- Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific endianness,
Cédric Le Goater <=
- Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific endianness, Peter Maydell, 2016/10/05
- Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific endianness, David Gibson, 2016/10/05
- Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific endianness, Paolo Bonzini, 2016/10/06
- Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific endianness, David Gibson, 2016/10/06
- Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific endianness, Paolo Bonzini, 2016/10/06
- Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific endianness, Cédric Le Goater, 2016/10/06
- Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific endianness, Peter Maydell, 2016/10/06
- Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific endianness, David Gibson, 2016/10/06
- Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific endianness, David Gibson, 2016/10/05
- Re: [Qemu-devel] [PATCH] qtest: add read/write accessors with a specific endianness, David Gibson, 2016/10/05