Merge pull request #3851 from kaspar030/make_messaging_optional
core: make messaging optionalpr/gpio
commit
c09190b979
@ -1,3 +1,3 @@
|
||||
DEFAULT_MODULE += board cpu core sys
|
||||
DEFAULT_MODULE += board cpu core core_msg sys
|
||||
|
||||
DEFAULT_MODULE += auto_init
|
||||
|
@ -1,41 +0,0 @@
|
||||
/*
|
||||
* Copyright (C) 2015 Freie Universität Berlin
|
||||
*
|
||||
* This file is subject to the terms and conditions of the GNU Lesser
|
||||
* General Public License v2.1. See the file LICENSE in the top level
|
||||
* directory for more details.
|
||||
*/
|
||||
|
||||
/**
|
||||
* @{
|
||||
*
|
||||
* @file
|
||||
* @author Martine Lenders <mlenders@inf.fu-berlin.de>
|
||||
*/
|
||||
|
||||
#include <stdio.h>
|
||||
|
||||
#include "sched.h"
|
||||
#include "thread.h"
|
||||
|
||||
void thread_print_msg_queue(void)
|
||||
{
|
||||
volatile thread_t *thread = sched_active_thread;
|
||||
volatile cib_t *msg_queue = &thread->msg_queue;
|
||||
msg_t *msg_array = thread->msg_array;
|
||||
unsigned int i = msg_queue->read_count & msg_queue->mask;
|
||||
|
||||
printf("Message queue of thread %" PRIkernel_pid "\n", thread->pid);
|
||||
printf(" size: %u (avail: %d)\n", msg_queue->mask + 1,
|
||||
cib_avail((cib_t *)msg_queue));
|
||||
|
||||
for (; i != (msg_queue->write_count & msg_queue->mask);
|
||||
i = (i + 1) & msg_queue->mask) {
|
||||
msg_t *m = &msg_array[i];
|
||||
printf(" * %u: sender: %" PRIkernel_pid ", type: 0x%04" PRIu16
|
||||
", content: %" PRIu32 " (%p)\n", i, m->sender_pid, m->type,
|
||||
m->content.value, (void *)m->content.ptr);
|
||||
}
|
||||
}
|
||||
|
||||
/** @} */
|
@ -1,7 +1,12 @@
|
||||
APPLICATION = sizeof_tcb
|
||||
include ../Makefile.tests_common
|
||||
|
||||
# optional thread_t modifying modules:
|
||||
# othread_t modifying modules:
|
||||
#
|
||||
# disabled by default:
|
||||
# USEMODULE += core_thread_flags
|
||||
#
|
||||
# enabled by defaule:
|
||||
# DISABLE_MODULE += core_msg
|
||||
|
||||
include $(RIOTBASE)/Makefile.include
|
||||
|
Loading…
Reference in New Issue