git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@1198 35acf78f-673a-0410-8e92-d51de3d6d3f4
parent
a1892b59a9
commit
48cf30f8ab
|
@ -27,11 +27,6 @@
|
|||
#include <ch.h>
|
||||
#include <mac.h>
|
||||
|
||||
/**
|
||||
* @brief Transmit descriptors counter semaphore.
|
||||
*/
|
||||
static Semaphore tdsem, rdsem;
|
||||
|
||||
/**
|
||||
* @brief MAC Driver initialization.
|
||||
*/
|
||||
|
@ -96,7 +91,7 @@ msg_t macWaitTransmitDescriptor(MACDriver *macp,
|
|||
(time > 0)) {
|
||||
chSysLock();
|
||||
systime_t now = chTimeNow();
|
||||
if ((msg = chSemWaitTimeoutS(&tdsem, time)) == RDY_TIMEOUT)
|
||||
if ((msg = chSemWaitTimeoutS(&macp->md_tdsem, time)) == RDY_TIMEOUT)
|
||||
break;
|
||||
if (time != TIME_INFINITE)
|
||||
time -= (chTimeNow() - now);
|
||||
|
@ -142,7 +137,7 @@ msg_t macWaitReceiveDescriptor(MACDriver *macp,
|
|||
(time > 0)) {
|
||||
chSysLock();
|
||||
systime_t now = chTimeNow();
|
||||
if ((msg = chSemWaitTimeoutS(&rdsem, time)) == RDY_TIMEOUT)
|
||||
if ((msg = chSemWaitTimeoutS(&macp->md_rdsem, time)) == RDY_TIMEOUT)
|
||||
break;
|
||||
if (time != TIME_INFINITE)
|
||||
time -= (chTimeNow() - now);
|
||||
|
|
Loading…
Reference in New Issue