Skip to content

Commit

Permalink
net/gnrc/netif:GNRC_NETIF_MIN_WAIT_AFTER_SEND_US to 'CONFIG_' namespace
Browse files Browse the repository at this point in the history
  • Loading branch information
PeterKietzmann committed Jan 13, 2020
1 parent 9e83d12 commit fb71ccc
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions sys/include/net/gnrc/netif/conf.h
Original file line number Diff line number Diff line change
Expand Up @@ -144,8 +144,8 @@ extern "C" {
*
* This is purely meant as a debugging feature to slow down a radios sending.
*/
#ifndef GNRC_NETIF_MIN_WAIT_AFTER_SEND_US
#define GNRC_NETIF_MIN_WAIT_AFTER_SEND_US (0U)
#ifndef CONFIG_GNRC_NETIF_MIN_WAIT_AFTER_SEND_US
#define CONFIG_GNRC_NETIF_MIN_WAIT_AFTER_SEND_US (0U)
#endif

#ifdef __cplusplus
Expand Down
8 changes: 4 additions & 4 deletions sys/net/gnrc/netif/gnrc_netif.c
Original file line number Diff line number Diff line change
Expand Up @@ -1376,7 +1376,7 @@ static void *_gnrc_netif_thread(void *args)
#endif
/* now let rest of GNRC use the interface */
gnrc_netif_release(netif);
#if (GNRC_NETIF_MIN_WAIT_AFTER_SEND_US > 0U)
#if (CONFIG_GNRC_NETIF_MIN_WAIT_AFTER_SEND_US > 0U)
xtimer_ticks32_t last_wakeup = xtimer_now();
#endif

Expand All @@ -1401,11 +1401,11 @@ static void *_gnrc_netif_thread(void *args)
netif->stats.tx_bytes += res;
}
#endif
#if (GNRC_NETIF_MIN_WAIT_AFTER_SEND_US > 0U)
#if (CONFIG_GNRC_NETIF_MIN_WAIT_AFTER_SEND_US > 0U)
xtimer_periodic_wakeup(&last_wakeup,
GNRC_NETIF_MIN_WAIT_AFTER_SEND_US);
CONFIG_GNRC_NETIF_MIN_WAIT_AFTER_SEND_US);
/* override last_wakeup in case last_wakeup +
* GNRC_NETIF_MIN_WAIT_AFTER_SEND_US was in the past */
* CONFIG_GNRC_NETIF_MIN_WAIT_AFTER_SEND_US was in the past */
last_wakeup = xtimer_now();
#endif
break;
Expand Down

0 comments on commit fb71ccc

Please sign in to comment.