net/gnrc/netif: Move GNRC_NETIF_MSG_QUEUE_SIZE to 'CONFIG_' namespace
This commit is contained in:
parent
b28a586702
commit
724d58b074
@ -26,7 +26,7 @@
|
|||||||
#include "cc110x_params.h"
|
#include "cc110x_params.h"
|
||||||
#include "log.h"
|
#include "log.h"
|
||||||
#include "msg.h"
|
#include "msg.h"
|
||||||
#include "net/gnrc/netif/conf.h" /* <- GNRC_NETIF_MSG_QUEUE_SIZE */
|
#include "net/gnrc/netif/conf.h" /* <- CONFIG_GNRC_NETIF_MSG_QUEUE_SIZE */
|
||||||
#define ENABLE_DEBUG (0)
|
#define ENABLE_DEBUG (0)
|
||||||
#include "debug.h"
|
#include "debug.h"
|
||||||
|
|
||||||
@ -34,11 +34,11 @@
|
|||||||
/**
|
/**
|
||||||
* @brief Additional stack size required by the driver
|
* @brief Additional stack size required by the driver
|
||||||
*
|
*
|
||||||
* With increasing of GNRC_NETIF_MSG_QUEUE_SIZE the required stack size
|
* With increasing of CONFIG_GNRC_NETIF_MSG_QUEUE_SIZE the required stack size
|
||||||
* increases as well. A queue size of 8 messages works with default stack size,
|
* increases as well. A queue size of 8 messages works with default stack size,
|
||||||
* so we increase the stack by `sizeof(msg_t)` for each additional element
|
* so we increase the stack by `sizeof(msg_t)` for each additional element
|
||||||
*/
|
*/
|
||||||
#define CC110X_EXTRA_STACKSIZE ((GNRC_NETIF_MSG_QUEUE_SIZE - 8) * sizeof(msg_t))
|
#define CC110X_EXTRA_STACKSIZE ((CONFIG_GNRC_NETIF_MSG_QUEUE_SIZE - 8) * sizeof(msg_t))
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@ -53,8 +53,8 @@ extern "C" {
|
|||||||
* the thread's stack size might need to be adapted if this is
|
* the thread's stack size might need to be adapted if this is
|
||||||
* changed.
|
* changed.
|
||||||
*/
|
*/
|
||||||
#ifndef GNRC_NETIF_MSG_QUEUE_SIZE
|
#ifndef CONFIG_GNRC_NETIF_MSG_QUEUE_SIZE
|
||||||
#define GNRC_NETIF_MSG_QUEUE_SIZE (16U)
|
#define CONFIG_GNRC_NETIF_MSG_QUEUE_SIZE (16U)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@ -1342,7 +1342,7 @@ static void *_gnrc_netif_thread(void *args)
|
|||||||
netdev_t *dev;
|
netdev_t *dev;
|
||||||
int res;
|
int res;
|
||||||
msg_t reply = { .type = GNRC_NETAPI_MSG_TYPE_ACK };
|
msg_t reply = { .type = GNRC_NETAPI_MSG_TYPE_ACK };
|
||||||
msg_t msg, msg_queue[GNRC_NETIF_MSG_QUEUE_SIZE];
|
msg_t msg, msg_queue[CONFIG_GNRC_NETIF_MSG_QUEUE_SIZE];
|
||||||
|
|
||||||
DEBUG("gnrc_netif: starting thread %i\n", sched_active_pid);
|
DEBUG("gnrc_netif: starting thread %i\n", sched_active_pid);
|
||||||
netif = args;
|
netif = args;
|
||||||
@ -1350,7 +1350,7 @@ static void *_gnrc_netif_thread(void *args)
|
|||||||
dev = netif->dev;
|
dev = netif->dev;
|
||||||
netif->pid = sched_active_pid;
|
netif->pid = sched_active_pid;
|
||||||
/* setup the link-layer's message queue */
|
/* setup the link-layer's message queue */
|
||||||
msg_init_queue(msg_queue, GNRC_NETIF_MSG_QUEUE_SIZE);
|
msg_init_queue(msg_queue, CONFIG_GNRC_NETIF_MSG_QUEUE_SIZE);
|
||||||
/* register the event callback with the device driver */
|
/* register the event callback with the device driver */
|
||||||
dev->event_callback = _event_cb;
|
dev->event_callback = _event_cb;
|
||||||
dev->context = netif;
|
dev->context = netif;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user