qemu-devel
[Top][All Lists]
Advanced

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

Re: [PATCH 2/2] e1000e: make TX reentrant


From: Jason Wang
Subject: Re: [PATCH 2/2] e1000e: make TX reentrant
Date: Fri, 24 Jul 2020 12:00:05 +0800
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0


On 2020/7/23 下午6:36, Peter Maydell wrote:
On Wed, 22 Jul 2020 at 10:00, Jason Wang <jasowang@redhat.com> wrote:
In loopback mode, e1000e RX can DMA into TX doorbell which requires
TX to be reentrant. This patch make e1000e's TX routine reentrant by
introducing a per device boolean for recording whether or not a TX
rountine is being called and return early.

Signed-off-by: Jason Wang <jasowang@redhat.com>
---
This feels like a sticking-plaster fix that's not really in the
right place... It stops us from calling back into
e1000e_start_xmit(), but it doesn't prevent a DMA request
from touching other device registers that update state in
the E100ECore struct that the transmit code is not expecting
to change.


Right, so we can track the mr owner and fail the memory access if there's another mr transaction in memory core: memory_region_dispatch_read() and memory_region_dispatch_write().

But what's more interesting is that some device uses bh for the doorbell which may require more thought...

Thanks



thanks
-- PMM





reply via email to

[Prev in Thread] Current Thread [Next in Thread]