Re: [Qemu-devel] [PATCH v2] i.MX: Fix FEC/ENET receive funtions

2018-01-24 Thread Jean-Christophe DUBOIS
My guess is that with this patch, the "flush" feature that was added by Andrey in "imx_fec: Change queue flushing heuristics" (commit b2b012a) is not really necessary anymore. But it does not hurt (it might induce a little bit more processing). JC Le 22/01/2018 à 15:59, Peter Maydell a écrit 

Re: [Qemu-devel] [PATCH v2] i.MX: Fix FEC/ENET receive funtions

2018-01-22 Thread Peter Maydell
On 22 January 2018 at 14:54, Andrey Smirnov wrote: > On Mon, Jan 22, 2018 at 3:48 AM, Peter Maydell > wrote: >> On 13 January 2018 at 11:34, Jean-Christophe Dubois >> wrote: >>> The actual imx_eth_enable_rx() function is buggy. >>> >>> It updates s->regs[ENET_RDAR] after calling qemu_flush_que

Re: [Qemu-devel] [PATCH v2] i.MX: Fix FEC/ENET receive funtions

2018-01-22 Thread Andrey Smirnov
On Mon, Jan 22, 2018 at 3:48 AM, Peter Maydell wrote: > On 13 January 2018 at 11:34, Jean-Christophe Dubois > wrote: >> The actual imx_eth_enable_rx() function is buggy. >> >> It updates s->regs[ENET_RDAR] after calling qemu_flush_queued_packets(). >> >> qemu_flush_queued_packets() is going to c

Re: [Qemu-devel] [PATCH v2] i.MX: Fix FEC/ENET receive funtions

2018-01-22 Thread Peter Maydell
On 13 January 2018 at 11:34, Jean-Christophe Dubois wrote: > The actual imx_eth_enable_rx() function is buggy. > > It updates s->regs[ENET_RDAR] after calling qemu_flush_queued_packets(). > > qemu_flush_queued_packets() is going to call imx_XXX_receive() which itself > is going to call imx_eth_en

[Qemu-devel] [PATCH v2] i.MX: Fix FEC/ENET receive funtions

2018-01-13 Thread Jean-Christophe Dubois
The actual imx_eth_enable_rx() function is buggy. It updates s->regs[ENET_RDAR] after calling qemu_flush_queued_packets(). qemu_flush_queued_packets() is going to call imx_XXX_receive() which itself is going to call imx_eth_enable_rx(). By updating s->regs[ENET_RDAR] after calling qemu_flush_que