From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46327) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WWXYJ-00063B-6s for qemu-devel@nongnu.org; Sat, 05 Apr 2014 16:51:04 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WWXYD-0007mk-GM for qemu-devel@nongnu.org; Sat, 05 Apr 2014 16:50:59 -0400 Message-ID: <53406C7D.7040404@reactos.org> Date: Sat, 05 Apr 2014 22:50:05 +0200 From: =?UTF-8?B?SGVydsOpIFBvdXNzaW5lYXU=?= MIME-Version: 1.0 References: <1395272166-687-1-git-send-email-andreas.faerber@web.de> <1395272166-687-3-git-send-email-andreas.faerber@web.de> <53402437.7030400@web.de> <53406704.7060705@reactos.org> <6E25F26C-1559-464E-8443-F10777A65472@suse.de> In-Reply-To: <6E25F26C-1559-464E-8443-F10777A65472@suse.de> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PULL for-2.0 2/7] raven: Implement non-contiguous I/O region List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Alexander Graf Cc: paolo bonzini , =?UTF-8?B?QW5kcmVhcyBGw6RyYmVy?= , qemu-ppc@nongnu.org, qemu-devel@nongnu.org Le sam. 05 avril 2014 22:34:38 CEST, Alexander Graf a =C3=A9crit : > > On 05.04.2014, at 22:26, Herv=C3=A9 Poussineau w= rote: > >> Hi Andreas, >> >> Le sam. 05 avril 2014 17:41:43 CEST, Andreas F=C3=A4rber a =C3=A9crit = : >>> Hi Herv=C3=A9, >>> >>> Am 20.03.2014 00:36, schrieb Andreas F=C3=A4rber: >>>> From: Herv=C3=A9 Poussineau >>>> >>>> Remove now duplicated code from prep board. >>>> >>>> Signed-off-by: Herv=C3=A9 Poussineau >>>> Signed-off-by: Andreas F=C3=A4rber >>>> --- >>>> hw/pci-host/prep.c | 85 ++++++++++++++++++++++++++++++++++++++++++= ++++++ >>>> hw/ppc/prep.c | 94 ++----------------------------------------= ------------ >>>> 2 files changed, 88 insertions(+), 91 deletions(-) >>> >>> I'm facing endianness-test failures in -rc1 on both openSUSE ppc/ppc6= 4 >>> and OSX ppc64 (below) as well as "broken pipe" on OSX ppc. >>> >>> $ make check-qtest-ppc V=3D1 >>> [...] >>> /ppc/endianness/prep: = ** >>> ERROR:/Users/andreas/QEMU/tests/endianness-test.c:131:test_endianness= : >>> assertion failed (isa_inw(test, 0xe2) =3D=3D 0x8765): (0x00004321 =3D= =3D 0x00008765) >>> FAIL >>> [...] >>> /ppc/endianness/split/prep: = ** >>> ERROR:/Users/andreas/QEMU/tests/endianness-test.c:206:test_endianness= _split: >>> assertion failed (isa_inw(test, 0xe2) =3D=3D 0x8765): (0x00004321 =3D= =3D 0x00008765) >>> FAIL >>> [...] >>> /ppc/endianness/combine/prep: = ** >>> ERROR:/Users/andreas/QEMU/tests/endianness-test.c:253:test_endianness= _combine: >>> assertion failed (isa_inw(test, 0xea) =3D=3D 0x8765): (0x00004321 =3D= =3D 0x00008765) >>> FAIL >>> [...] >>> FAIL: tests/endianness-test >>> >>> On x86 everything is fine. git-bisect points to this commit. >>> >>> There is one "FIXME: handle endianness switch" in here, but I don't s= pot >>> such code where it's being moved from either. The FIXME here is only when we'll handle dynamic endianess switching of=20 the system (not of the CPU). It was not present in code moved in this=20 commit, and I only added the comment to tell where to place it. >>> >>> My suspect is the cpu_inw() -> ldl_p() change, but I'm unsure whether >>> the code or the test is wrong... >> >> Code removed in this commit was using DEVICE_NATIVE_ENDIAN, and then u= sing cpu_inl, which does a ldl_p. >> Code added in this commit is using DEVICE_LITTLE_ENDIAN, and then is u= sing ldl_p. >> So, yes, it seems that endianness of memory region does change things.= Native endian means native endian of the guest of of the host? > > It means "default endianness of the guest cpu" so that accesses coming = from the CPU get passed in the value they had in the CPU registers :). In that case, behaviour should be the same between x86 host and=20 openSUSE ppc/ppc64 and OSX ppc64 hosts. The culprit is elsewhere... Herv=C3=A9