Tried rtl 8139 driver under QEmu and it worked but there were strange download pauses when trying to download something in OWB.
Source has a TODO comment about wrapped buffer/frame stuff. I did this change:
diff --git a/workbench/devs/networks/rtl8139/rtl8139.c b/workbench/devs/networks/rtl8139/rtl8139.c
index bee3096a8f..8fea0f31a6 100644
--- a/workbench/devs/networks/rtl8139/rtl8139.c
+++ b/workbench/devs/networks/rtl8139/rtl8139.c
@@ -554,7 +554,11 @@ static int rtl8139nic_open(struct net_device *unit)
np->rx_buffer = HIDD_PCIDriver_AllocPCIMem(
unit->rtl8139u_PCIDriver,
+#if 1 //stegerg: double size so wrapped-over data can be appended at end
+ (np->rx_buf_len * 2 + 16 + (TX_BUF_SIZE * NUM_TX_DESC))
+#else
(np->rx_buf_len + 16 + (TX_BUF_SIZE * NUM_TX_DESC))
+#endif
);
if (np->rx_buffer != NULL)
diff --git a/workbench/devs/networks/rtl8139/unit.c b/workbench/devs/networks/rtl8139/unit.c
index a1a575b78b..78e933e267 100644
--- a/workbench/devs/networks/rtl8139/unit.c
+++ b/workbench/devs/networks/rtl8139/unit.c
@@ -212,8 +212,14 @@ RTLD(bug("[%s] RTL8139_RX_Process: frame @ %p, len=%d\n", unit->rtl8139u_name, f
{
overspill = (ring_offset + rx_size) - np->rx_buf_len;
RTLD(bug("[%s] RTL8139_RX_Process: WRAPPED Frame! (%d bytes overspill)\n", unit->rtl8139u_name, overspill))
+#if 1
+ CopyMem(np->rx_buffer, np->rx_buffer + np->rx_buf_len, overspill);
+#else
len = len - overspill;
+
/* TODO: We need to copy the wrapped buffer into a temp buff to pass to listeners! */
+#endif
}
RTLD( int j;
and I'm not sure if this is how it should be done, but it seemed to help.