* [Qemu-devel] [PATCH net v1 1/1] net: xilinx_ethlite: Fix Rx-pong interrupt
@ 2014-05-06 4:39 Peter Crosthwaite
2014-05-06 12:13 ` Stefan Hajnoczi
0 siblings, 1 reply; 2+ messages in thread
From: Peter Crosthwaite @ 2014-05-06 4:39 UTC (permalink / raw)
To: qemu-devel; +Cc: edgar.iglesias, stefanha
There is no CTRL_I bit in the pong buffer control register. The
CTRL_I bit from the ping buffer masks both ping and pong buffers.
Fix.
Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>
---
hw/net/xilinx_ethlite.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/hw/net/xilinx_ethlite.c b/hw/net/xilinx_ethlite.c
index 3a2a6c2..dbd1cdd 100644
--- a/hw/net/xilinx_ethlite.c
+++ b/hw/net/xilinx_ethlite.c
@@ -196,8 +196,9 @@ static ssize_t eth_rx(NetClientState *nc, const uint8_t *buf, size_t size)
memcpy(&s->regs[rxbase + R_RX_BUF0], buf, size);
s->regs[rxbase + R_RX_CTRL0] |= CTRL_S;
- if (s->regs[rxbase + R_RX_CTRL0] & CTRL_I)
+ if (s->regs[R_RX_CTRL0] & CTRL_I) {
eth_pulse_irq(s);
+ }
/* If c_rx_pingpong was set flip buffers. */
s->rxbuf ^= s->c_rx_pingpong;
--
1.9.2.1.g06c4abd
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [Qemu-devel] [PATCH net v1 1/1] net: xilinx_ethlite: Fix Rx-pong interrupt
2014-05-06 4:39 [Qemu-devel] [PATCH net v1 1/1] net: xilinx_ethlite: Fix Rx-pong interrupt Peter Crosthwaite
@ 2014-05-06 12:13 ` Stefan Hajnoczi
0 siblings, 0 replies; 2+ messages in thread
From: Stefan Hajnoczi @ 2014-05-06 12:13 UTC (permalink / raw)
To: Peter Crosthwaite; +Cc: edgar.iglesias, qemu-devel
On Mon, May 05, 2014 at 09:39:38PM -0700, Peter Crosthwaite wrote:
> There is no CTRL_I bit in the pong buffer control register. The
> CTRL_I bit from the ping buffer masks both ping and pong buffers.
> Fix.
>
> Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>
> ---
>
> hw/net/xilinx_ethlite.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
Unfamiliar with the device but the patch itself looks clean. I'll drop
it from my queue if there are comments.
Thanks, applied to my net tree:
https://github.com/stefanha/qemu/commits/net
Stefan
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-05-06 12:14 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-05-06 4:39 [Qemu-devel] [PATCH net v1 1/1] net: xilinx_ethlite: Fix Rx-pong interrupt Peter Crosthwaite
2014-05-06 12:13 ` Stefan Hajnoczi
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).