qemu-devel
[Top][All Lists]
Advanced

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

[Qemu-devel] [PATCH] eepro100: fix simplified mode


From: initcrash
Subject: [Qemu-devel] [PATCH] eepro100: fix simplified mode
Date: Mon, 23 Jul 2012 11:25:44 +0200

From: Christian Schilling <address@hidden>

A driver using simplified mode that works on real hardware
did not work in qemu.

Signed-off-by: Christian Schilling <address@hidden>
---
 hw/eepro100.c |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)

diff --git a/hw/eepro100.c b/hw/eepro100.c
index 6279ae3..4a48372 100644
--- a/hw/eepro100.c
+++ b/hw/eepro100.c
@@ -774,6 +774,13 @@ static void tx_command(EEPRO100State *s)
 #if 0
         uint16_t tx_buffer_el = lduw_le_pci_dma(&s->dev, tbd_address + 6);
 #endif
+        if (tbd_array == 0xffffffff) {
+            /* In simpliyfied mode there is no tbd_array. Instead the packet 
data
+             * starts right after the tcb_bytes field, and the packet size is
+             * equal to tcb_bytes */
+            tx_buffer_size = tcb_bytes;
+            tx_buffer_address = tbd_address;
+        }
         tbd_address += 8;
         TRACE(RXTX, logout
             ("TBD (simplified mode): buffer address 0x%08x, size 0x%04x\n",
-- 
1.7.7.6




reply via email to

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