Cc'ing Jason.

On 1/25/20 12:20 AM, Richard Henderson wrote:
From: Helge Deller <[email protected]>

LASI is a built-in multi-I/O chip which supports serial, parallel,
network (Intel i82596 Apricot), sound and other functionalities.
LASI has been used in many HP PARISC machines.
This patch adds the necessary parts to allow Linux and HP-UX to detect
LASI and the network card.

Signed-off-by: Helge Deller <[email protected]>
Signed-off-by: Sven Schnelle <[email protected]>
Message-Id: <[email protected]>
Signed-off-by: Richard Henderson <[email protected]>
---
[...]
+int i82596_can_receive(NetClientState *nc)
+{
+    I82596State *s = qemu_get_nic_opaque(nc);
+
+    if (s->rx_status == RX_SUSPENDED) {
+        return 0;
+    }
+
+    if (!s->lnkst) {
+        return 0;
+    }
+
+    if (USE_TIMER && !timer_pending(s->flush_queue_timer)) {
+        return 1;

Something is odd here. Don't you want the opposite?

"if timer pending to flush the queue, do not receive more pkts"

    if (USE_TIMER && timer_pending(s->flush_queue_timer)) {
        return 0;
    }

+    }
+
+    return 1;
+}
[...]


Reply via email to