dp8393x: fix dp8393x_receive()
commitc744cf78791e7ddc903a46d6506f1a0cbcbb3387
authorLaurent Vivier <laurent@vivier.eu>
Wed, 6 Nov 2019 11:23:41 +0000 (6 12:23 +0100)
committerLaurent Vivier <laurent@vivier.eu>
Fri, 8 Nov 2019 20:32:31 +0000 (8 21:32 +0100)
treeeac78d23322b7f8267e7ffe4d6775a49e62e700f
parentaf9f0be36cd412442a801d25bd5dd9459d691d0b
dp8393x: fix dp8393x_receive()

RXpkt.in_use is always 16 bit wide, but when the bus access mode is 32bit
and the endianness is big, we must access the second word and not the
first. This patch adjusts the offset according to the size and endianness.

This fixes DHCP for Q800 guest.

Fixes: be9208419865 ("dp8393x: manage big endian bus")
Signed-off-by: Laurent Vivier <laurent@vivier.eu>
Tested-by: Hervé Poussineau <hpoussin@reactos.org>
Message-Id: <20191106112341.23735-3-laurent@vivier.eu>
hw/net/dp8393x.c