diff --git a/cpu/native/include/native_internal.h b/cpu/native/include/native_internal.h index 902d9e1fd6..54c38e15d8 100644 --- a/cpu/native/include/native_internal.h +++ b/cpu/native/include/native_internal.h @@ -65,6 +65,7 @@ extern int (*real_fork)(void); extern int (*real_dup2)(int, int); extern int (*real_unlink)(const char *); extern int (*real_execve)(const char *, char *const[], char *const[]); +extern int (*real_pause)(void); /** * data structures diff --git a/cpu/native/lpm_cpu.c b/cpu/native/lpm_cpu.c index 106fb4bf79..244911c79a 100644 --- a/cpu/native/lpm_cpu.c +++ b/cpu/native/lpm_cpu.c @@ -80,7 +80,7 @@ void _native_lpm_sleep(void) /* otherwise select was interrupted because of a signal, continue below */ #else _native_in_syscall++; // no switching here - pause(); + real_pause(); _native_in_syscall--; #endif diff --git a/cpu/native/startup.c b/cpu/native/startup.c index e7cb1eb921..ef72f42105 100644 --- a/cpu/native/startup.c +++ b/cpu/native/startup.c @@ -205,6 +205,7 @@ __attribute__((constructor)) static void startup(int argc, char **argv) *(void **)(&real_dup2) = dlsym(RTLD_NEXT, "dup2"); *(void **)(&real_unlink) = dlsym(RTLD_NEXT, "unlink"); *(void **)(&real_execve) = dlsym(RTLD_NEXT, "execve"); + *(void **)(&real_pause) = dlsym(RTLD_NEXT, "pause"); _native_argv = argv; _progname = argv[0]; diff --git a/cpu/native/syscalls.c b/cpu/native/syscalls.c index d784b8b2b9..2f407bac62 100644 --- a/cpu/native/syscalls.c +++ b/cpu/native/syscalls.c @@ -60,6 +60,7 @@ int (*real_fork)(void); int (*real_dup2)(int, int); int (*real_unlink)(const char *); int (*real_execve)(const char *, char *const[], char *const[]); +int (*real_pause)(void); void _native_syscall_enter(void) { diff --git a/examples/rpl_udp/helper.c b/examples/rpl_udp/helper.c index 1288ca87c7..93b4c7d7de 100644 --- a/examples/rpl_udp/helper.c +++ b/examples/rpl_udp/helper.c @@ -98,6 +98,8 @@ void rpl_udp_monitor(void) if (ipv6_buf->nextheader == IPV6_PROTO_NUM_ICMPV6) { DEBUG("\t ICMP type: %02X ", icmp_type); DEBUG("\t ICMP code: %02X ", icmp_code); + (void) icmp_type; + (void) icmp_code; } printf("\n"); diff --git a/sys/net/ccn_lite/ccnl-ext-frag.c b/sys/net/ccn_lite/ccnl-ext-frag.c index 0582613e9d..b6aa2b6371 100644 --- a/sys/net/ccn_lite/ccnl-ext-frag.c +++ b/sys/net/ccn_lite/ccnl-ext-frag.c @@ -707,5 +707,8 @@ Bail: return -1; } -#endif // USE_FRAG -// eof +#else // USE_FRAG + +static int dummy __attribute__((unused)); + +#endif diff --git a/sys/net/include/destiny/types.h b/sys/net/include/destiny/types.h index b9966b099f..1b168e0920 100644 --- a/sys/net/include/destiny/types.h +++ b/sys/net/include/destiny/types.h @@ -55,9 +55,9 @@ typedef struct __attribute__((packed)) { uint16_t dst_port; ///< destination port uint32_t seq_nr; ///< sequence number uint32_t ack_nr; ///< acknowledgement number - uint8_t flag_ns :1; ///< ECN-nonce concealment protection (since RFC 3540). - uint8_t reserved :3; ///< for future use - set to zero - uint8_t data_offset :4; + unsigned flag_ns :1; ///< ECN-nonce concealment protection (since RFC 3540). + unsigned reserved :3; ///< for future use - set to zero + unsigned data_offset :4; uint8_t reserved_flags; ///< TODO: break this down into another bitfield: flag_fin, flag_syn, etc uint16_t window; ///< receiver window /** diff --git a/sys/net/network_layer/sixlowpan/icmp.c b/sys/net/network_layer/sixlowpan/icmp.c index 7622a4fe5f..0168e63244 100644 --- a/sys/net/network_layer/sixlowpan/icmp.c +++ b/sys/net/network_layer/sixlowpan/icmp.c @@ -1144,6 +1144,8 @@ void recv_nbr_sol(void) } } } + + (void) aro_state; } break; diff --git a/sys/net/routing/rpl/rpl.c b/sys/net/routing/rpl/rpl.c index ad90b00ce3..669ce66f19 100644 --- a/sys/net/routing/rpl/rpl.c +++ b/sys/net/routing/rpl/rpl.c @@ -985,6 +985,7 @@ void rpl_send(ipv6_addr_t *destination, uint8_t *payload, uint16_t p_len, uint8_ ipv6_send_packet(ipv6_send_buf); } + (void) packet_length; } ipv6_addr_t *rpl_get_next_hop(ipv6_addr_t *addr) diff --git a/tests/test_posix_semaphore/main.c b/tests/test_posix_semaphore/main.c index cbef1ff748..15a160160d 100644 --- a/tests/test_posix_semaphore/main.c +++ b/tests/test_posix_semaphore/main.c @@ -160,4 +160,5 @@ int main(void) puts("#########################"); test2(); puts("#########################"); + return 0; } diff --git a/tests/test_posix_sleep/main.c b/tests/test_posix_sleep/main.c index a8ea9b0299..b83d668527 100644 --- a/tests/test_posix_sleep/main.c +++ b/tests/test_posix_sleep/main.c @@ -40,4 +40,5 @@ int main(void) } puts("done"); + return 0; } diff --git a/tests/test_pthread_barrier/main.c b/tests/test_pthread_barrier/main.c index 792a9da825..7dc26ad8c8 100644 --- a/tests/test_pthread_barrier/main.c +++ b/tests/test_pthread_barrier/main.c @@ -43,7 +43,7 @@ static void *run(void *id_) pthread_barrier_wait(&barrier); uint32_t timeout_us = genrand_uint32() % 2500000; - printf("Child %i sleeps for % 8" PRIu32 " µs.\n", id, timeout_us); + printf("Child %i sleeps for %8" PRIu32 " µs.\n", id, timeout_us); vtimer_usleep(timeout_us); } diff --git a/tests/test_thread_basic/main.c b/tests/test_thread_basic/main.c index 582ef6c454..4f5b5d3fa9 100644 --- a/tests/test_thread_basic/main.c +++ b/tests/test_thread_basic/main.c @@ -36,4 +36,5 @@ int main(void) { (void) thread_create(t2_stack, STACK_SIZE, PRIORITY_MAIN - 1, CREATE_WOUT_YIELD | CREATE_STACKTEST, second_thread, "nr2"); puts("first thread\n"); + return 0; } diff --git a/tests/test_thread_exit/main.c b/tests/test_thread_exit/main.c index 482414d8ee..eadfe173af 100644 --- a/tests/test_thread_exit/main.c +++ b/tests/test_thread_exit/main.c @@ -86,4 +86,5 @@ int main(void) } puts("main: exiting"); + return 0; } diff --git a/tests/test_thread_msg/main.c b/tests/test_thread_msg/main.c index f8c27d3538..b6f9f8fb94 100644 --- a/tests/test_thread_msg/main.c +++ b/tests/test_thread_msg/main.c @@ -82,4 +82,5 @@ int main(void) p3 = thread_create(t3_stack, KERNEL_CONF_STACKSIZE_PRINTF, PRIORITY_MAIN - 1, CREATE_WOUT_YIELD | CREATE_STACKTEST, thread3, "nr3"); puts("THREADS CREATED\n"); + return 0; } diff --git a/tests/test_thread_msg_block_w_queue/main.c b/tests/test_thread_msg_block_w_queue/main.c index b39ee2125b..74110e63fc 100644 --- a/tests/test_thread_msg_block_w_queue/main.c +++ b/tests/test_thread_msg_block_w_queue/main.c @@ -62,4 +62,5 @@ int main(void) msg_receive(&msg); printf("MAIN THREAD %u ALIVE!\n", p_main); + return 0; } diff --git a/tests/test_thread_msg_block_wo_queue/main.c b/tests/test_thread_msg_block_wo_queue/main.c index 1c239d3581..17998c691e 100644 --- a/tests/test_thread_msg_block_wo_queue/main.c +++ b/tests/test_thread_msg_block_wo_queue/main.c @@ -59,4 +59,5 @@ int main(void) msg_receive(&msg); printf("MAIN THREAD %u ALIVE!\n", p_main); + return 0; }