Move two #defines from acd.h to acd.c since they are only useful in there

This commit is contained in:
Dirk Ziegelmeier 2018-10-05 10:58:30 +02:00
parent 015cff75fd
commit a3cdf3c4cc
2 changed files with 4 additions and 3 deletions

View File

@ -71,6 +71,10 @@
#include "lwip/acd.h" #include "lwip/acd.h"
#include "lwip/prot/acd.h" #include "lwip/prot/acd.h"
#define ACD_FOREACH(acd, acd_list) for ((acd) = acd_list; (acd) != NULL; (acd) = (acd)->next)
#define ACD_TICKS_PER_SECOND (1000 / ACD_TMR_INTERVAL)
/* Define good random function (LWIP_RAND) in lwipopts.h */ /* Define good random function (LWIP_RAND) in lwipopts.h */
#define ACD_RANDOM_PROBE_WAIT (LWIP_RAND() % \ #define ACD_RANDOM_PROBE_WAIT (LWIP_RAND() % \
(PROBE_WAIT * ACD_TICKS_PER_SECOND)) (PROBE_WAIT * ACD_TICKS_PER_SECOND))

View File

@ -58,9 +58,6 @@ extern "C" {
* 1000, 500, 333, 250, 200, 166, 142, 125, 111, 100 .... * 1000, 500, 333, 250, 200, 166, 142, 125, 111, 100 ....
*/ */
#define ACD_TMR_INTERVAL 100 #define ACD_TMR_INTERVAL 100
#define ACD_TICKS_PER_SECOND (1000 / ACD_TMR_INTERVAL)
#define ACD_FOREACH(acd, acd_list) for ((acd) = acd_list; (acd) != NULL; (acd) = (acd)->next)
/** /**
* Callback function: Handle conflict information from ACD module * Callback function: Handle conflict information from ACD module