Commit 3acca2c0 authored by John Ballance's avatar John Ballance
Browse files

Reduce TX retry timeout and re-read buffer status

Detail:
Under certain circumstances, especially iMx->iMx with sharefs, with its default
window value of 2, it was possible for all tx buffers to be left full.
The timeout loop failed to refresh the buffer status. Now resolved.
Admin:
tested iMx<->iMx

Version 0.27. Tagged as 'EtherTH-0_27'
parent 53c9647a
......@@ -11,13 +11,13 @@
GBLS Module_HelpVersion
GBLS Module_ComponentName
GBLS Module_ComponentPath
Module_MajorVersion SETS "0.26"
Module_Version SETA 26
Module_MajorVersion SETS "0.27"
Module_Version SETA 27
Module_MinorVersion SETS ""
Module_Date SETS "11 Mar 2017"
Module_ApplicationDate SETS "11-Mar-17"
Module_Date SETS "27 Apr 2017"
Module_ApplicationDate SETS "27-Apr-17"
Module_ComponentName SETS "EtherTH"
Module_ComponentPath SETS "mixed/RiscOS/Sources/Networking/Ethernet/EtherTH"
Module_FullVersion SETS "0.26"
Module_HelpVersion SETS "0.26 (11 Mar 2017)"
Module_FullVersion SETS "0.27"
Module_HelpVersion SETS "0.27 (27 Apr 2017)"
END
/* (0.26)
/* (0.27)
*
* This file is automatically maintained by srccommit, do not edit manually.
* Last processed by srccommit version: 1.1.
*
*/
#define Module_MajorVersion_CMHG 0.26
#define Module_MajorVersion_CMHG 0.27
#define Module_MinorVersion_CMHG
#define Module_Date_CMHG 11 Mar 2017
#define Module_Date_CMHG 27 Apr 2017
#define Module_MajorVersion "0.26"
#define Module_Version 26
#define Module_MajorVersion "0.27"
#define Module_Version 27
#define Module_MinorVersion ""
#define Module_Date "11 Mar 2017"
#define Module_Date "27 Apr 2017"
#define Module_ApplicationDate "11-Mar-17"
#define Module_ApplicationDate "27-Apr-17"
#define Module_ComponentName "EtherTH"
#define Module_ComponentPath "mixed/RiscOS/Sources/Networking/Ethernet/EtherTH"
#define Module_FullVersion "0.26"
#define Module_HelpVersion "0.26 (11 Mar 2017)"
#define Module_LibraryVersionInfo "0:26"
#define Module_FullVersion "0.27"
#define Module_HelpVersion "0.27 (27 Apr 2017)"
#define Module_LibraryVersionInfo "0:27"
......@@ -559,14 +559,15 @@ _kernel_oserror* device_transmit(device_t* d, dci_TransmitArgs_t* args)
{
/*
* Buffer full
* Wait up to 0.1 secs for a buffer to clear so that we don't have to
* Wait up to 0.015 secs for a buffer to clear so that we don't have to
* discard the packet and suffer a retry.
*/
device_setReg(d, ENET_TDAR, ENET_TDAR__TDAR); /* just in case its not set */
int i;
for (i = 10000; i; i--)
for (i = 150; i; i--)
{
utils_delay_us(10);
status = d->tx_ring_ptr->status;
if ((status & TXBD_STATUS__R) == 0) break;
}
if (i == 0) break; /* No use - will have to discard it */
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment