Browse Source

sys: adapted to renamed THREAD FLAGS

cc430
Hauke Petersen 7 years ago
parent
commit
41979b64cd
  1. 2
      sys/cpp11-compat/include/riot/thread.hpp
  2. 2
      sys/net/gnrc/application_layer/zep/gnrc_zep.c
  3. 2
      sys/net/gnrc/link_layer/netdev2/gnrc_netdev2.c
  4. 2
      sys/net/gnrc/link_layer/nomac/gnrc_nomac.c
  5. 2
      sys/net/gnrc/link_layer/slip/gnrc_slip.c
  6. 3
      sys/net/gnrc/nettest/gnrc_nettest.c
  7. 3
      sys/net/gnrc/network_layer/ipv6/gnrc_ipv6.c
  8. 2
      sys/net/gnrc/network_layer/sixlowpan/gnrc_sixlowpan.c
  9. 3
      sys/net/gnrc/pktdump/gnrc_pktdump.c
  10. 5
      sys/net/gnrc/routing/rpl/gnrc_rpl.c
  11. 2
      sys/net/gnrc/transport_layer/udp/gnrc_udp.c
  12. 4
      sys/net/routing/nhdp/nhdp.c
  13. 5
      sys/posix/pthread/pthread.c

2
sys/cpp11-compat/include/riot/thread.hpp

@ -228,7 +228,7 @@ thread::thread(F&& f, Args&&... args)
std::unique_ptr<func_and_args> p(
new func_and_args(m_data.get(), forward<F>(f), forward<Args>(args)...));
m_handle = thread_create(
m_data->stack, stack_size, THREAD_PRIORITY_MAIN - 1, 0, // CREATE_WOUT_YIELD
m_data->stack, stack_size, THREAD_PRIORITY_MAIN - 1, 0,
&thread_proxy<func_and_args>, p.get(), "riot_cpp_thread");
if (m_handle >= 0) {
p.release();

2
sys/net/gnrc/application_layer/zep/gnrc_zep.c

@ -163,7 +163,7 @@ kernel_pid_t gnrc_zep_init(gnrc_zep_t *dev, uint16_t src_port, ipv6_addr_t *dst,
dev->lqi_mode = 1;
_pid = thread_create(_rx_stack, GNRC_ZEP_STACK_SIZE, GNRC_ZEP_PRIO,
CREATE_STACKTEST, _event_loop, dev, "zep_app");
THREAD_CREATE_STACKTEST, _event_loop, dev, "zep_app");
DEBUG("zep: started thread with PID %" PRIkernel_pid "\n", _pid);

2
sys/net/gnrc/link_layer/netdev2/gnrc_netdev2.c

@ -186,7 +186,7 @@ kernel_pid_t gnrc_netdev2_init(char *stack, int stacksize, char priority,
}
/* create new gnrc_netdev2 thread */
res = thread_create(stack, stacksize, priority, CREATE_STACKTEST,
res = thread_create(stack, stacksize, priority, THREAD_CREATE_STACKTEST,
_gnrc_netdev2_thread, (void *)gnrc_netdev2, name);
if (res <= 0) {
return -EINVAL;

2
sys/net/gnrc/link_layer/nomac/gnrc_nomac.c

@ -138,7 +138,7 @@ kernel_pid_t gnrc_nomac_init(char *stack, int stacksize, char priority,
return -ENODEV;
}
/* create new NOMAC thread */
res = thread_create(stack, stacksize, priority, CREATE_STACKTEST,
res = thread_create(stack, stacksize, priority, THREAD_CREATE_STACKTEST,
_nomac_thread, (void *)dev, name);
if (res <= 0) {
return -EINVAL;

2
sys/net/gnrc/link_layer/slip/gnrc_slip.c

@ -268,7 +268,7 @@ kernel_pid_t gnrc_slip_init(gnrc_slip_dev_t *dev, uart_t uart, uint32_t baudrate
/* start SLIP thread */
DEBUG("slip: starting SLIP thread\n");
pid = thread_create(stack, stack_size, priority, CREATE_STACKTEST,
pid = thread_create(stack, stack_size, priority, THREAD_CREATE_STACKTEST,
_slip, dev, _SLIP_NAME);
if (pid < 0) {
DEBUG("slip: unable to create SLIP thread\n");

3
sys/net/gnrc/nettest/gnrc_nettest.c

@ -187,7 +187,8 @@ int gnrc_nettest_init(void)
{
if (_pid <= KERNEL_PID_UNDEF) {
_pid = thread_create(_stack, sizeof(_stack), GNRC_NETTEST_PRIO,
CREATE_STACKTEST, _event_loop, NULL, "nettest");
THREAD_CREATE_STACKTEST,
_event_loop, NULL, "nettest");
}
return _pid;

3
sys/net/gnrc/network_layer/ipv6/gnrc_ipv6.c

@ -85,7 +85,8 @@ kernel_pid_t gnrc_ipv6_init(void)
{
if (gnrc_ipv6_pid == KERNEL_PID_UNDEF) {
gnrc_ipv6_pid = thread_create(_stack, sizeof(_stack), GNRC_IPV6_PRIO,
CREATE_STACKTEST, _event_loop, NULL, "ipv6");
THREAD_CREATE_STACKTEST,
_event_loop, NULL, "ipv6");
}
#ifdef MODULE_FIB

2
sys/net/gnrc/network_layer/sixlowpan/gnrc_sixlowpan.c

@ -55,7 +55,7 @@ kernel_pid_t gnrc_sixlowpan_init(void)
}
_pid = thread_create(_stack, sizeof(_stack), GNRC_SIXLOWPAN_PRIO,
CREATE_STACKTEST, _event_loop, NULL, "6lo");
THREAD_CREATE_STACKTEST, _event_loop, NULL, "6lo");
return _pid;
}

3
sys/net/gnrc/pktdump/gnrc_pktdump.c

@ -164,7 +164,8 @@ kernel_pid_t gnrc_pktdump_init(void)
{
if (_pid == KERNEL_PID_UNDEF) {
_pid = thread_create(_stack, sizeof(_stack), GNRC_PKTDUMP_PRIO,
CREATE_STACKTEST, _eventloop, NULL, "pktdump");
THREAD_CREATE_STACKTEST,
_eventloop, NULL, "pktdump");
}
return _pid;
}

5
sys/net/gnrc/routing/rpl/gnrc_rpl.c

@ -49,8 +49,9 @@ kernel_pid_t gnrc_rpl_init(kernel_pid_t if_pid)
if (gnrc_rpl_pid == KERNEL_PID_UNDEF) {
_instance_id = 0;
/* start the event loop */
gnrc_rpl_pid = thread_create(_stack, sizeof(_stack), GNRC_RPL_PRIO, CREATE_STACKTEST,
_event_loop, NULL, "RPL");
gnrc_rpl_pid = thread_create(_stack, sizeof(_stack), GNRC_RPL_PRIO,
THREAD_CREATE_STACKTEST,
_event_loop, NULL, "RPL");
if (gnrc_rpl_pid == KERNEL_PID_UNDEF) {
DEBUG("RPL: could not start the event loop\n");

2
sys/net/gnrc/transport_layer/udp/gnrc_udp.c

@ -277,7 +277,7 @@ int gnrc_udp_init(void)
if (_pid == KERNEL_PID_UNDEF) {
/* start UDP thread */
_pid = thread_create(_stack, sizeof(_stack), GNRC_UDP_PRIO,
CREATE_STACKTEST, _event_loop, NULL, "udp");
THREAD_CREATE_STACKTEST, _event_loop, NULL, "udp");
}
return _pid;
}

4
sys/net/routing/nhdp/nhdp.c

@ -94,7 +94,7 @@ kernel_pid_t nhdp_start(void)
/* Start the NHDP thread */
nhdp_pid = thread_create(nhdp_stack, sizeof(nhdp_stack), THREAD_PRIORITY_MAIN - 1,
CREATE_STACKTEST, _nhdp_runner, NULL, "NHDP");
THREAD_CREATE_STACKTEST, _nhdp_runner, NULL, "NHDP");
#if (NHDP_METRIC_NEEDS_TIMER)
/* Configure periodic timer message to refresh metric values */
@ -193,7 +193,7 @@ int nhdp_register_if(kernel_pid_t if_pid, uint8_t *addr, size_t addr_size, uint8
/* Start the receiving thread */
nhdp_rcv_pid = thread_create(nhdp_rcv_stack, sizeof(nhdp_rcv_stack), THREAD_PRIORITY_MAIN - 1,
CREATE_STACKTEST, _nhdp_receiver, NULL, "nhdp_rcv_thread");
THREAD_CREATE_STACKTEST, _nhdp_receiver, NULL, "nhdp_rcv_thread");
/* Start sending periodic HELLO */
signal_msg.type = MSG_TIMER;

5
sys/posix/pthread/pthread.c

@ -143,7 +143,7 @@ int pthread_create(pthread_t *newthread, const pthread_attr_t *attr, void *(*sta
volatile kernel_pid_t pid = thread_create(pthread_reaper_stack,
PTHREAD_REAPER_STACKSIZE,
0,
CREATE_STACKTEST,
THREAD_CREATE_STACKTEST,
pthread_reaper,
NULL,
"pthread-reaper");
@ -155,7 +155,8 @@ int pthread_create(pthread_t *newthread, const pthread_attr_t *attr, void *(*sta
pt->thread_pid = thread_create(stack,
stack_size,
THREAD_PRIORITY_MAIN,
CREATE_WOUT_YIELD | CREATE_STACKTEST,
THREAD_CREATE_WOUT_YIELD |
THREAD_CREATE_STACKTEST,
pthread_start_routine,
pt,
"pthread");

Loading…
Cancel
Save