X-Git-Url: https://codewiz.org/gitweb?a=blobdiff_plain;f=bertos%2Fnet%2Flwip%2Fsrc%2Farch%2Fsys_arch.c;h=d626f0cfd09933c66d6d9c9e3462808fa95dfd5d;hb=e212073c5800b0f46fca2c1e35b0fbd8683af188;hp=a7feddbd19a795f0e2667128f7d9be4ade7c347b;hpb=08b11a3ad6e293343bfab98a7439a26079db5dea;p=bertos.git diff --git a/bertos/net/lwip/src/arch/sys_arch.c b/bertos/net/lwip/src/arch/sys_arch.c index a7feddbd..d626f0cf 100644 --- a/bertos/net/lwip/src/arch/sys_arch.c +++ b/bertos/net/lwip/src/arch/sys_arch.c @@ -1,4 +1,4 @@ -#include +#include "cfg/cfg_lwip.h" #define LOG_LEVEL 3 #define LOG_FORMAT 0 @@ -317,15 +317,6 @@ static struct sys_timeouts lwip_system_timeouts; // Default timeouts list for lw struct sys_timeouts *sys_arch_timeouts(void) { - ThreadNode *thread_node; - struct Process *curr_pid = proc_current(); - - FOREACH_NODE(thread_node, &used_thread) - { - if (thread_node->pid == curr_pid) - return &(thread_node->timeout); - } - return &lwip_system_timeouts; } @@ -348,7 +339,7 @@ static cpu_stack_t thread_stack[MAX_THREAD_CNT] static int last_stack; #endif -sys_thread_t sys_thread_new(char *name, void (* thread)(void *arg), +sys_thread_t sys_thread_new(const char *name, void (* thread)(void *arg), void *arg, int stacksize, int prio) { ThreadNode *thread_node; @@ -380,6 +371,9 @@ sys_thread_t sys_thread_new(char *name, void (* thread)(void *arg), #if CONFIG_KERN_PRI proc_setPri(thread_node->pid, prio); + #else + /* Avoid warnings when priorities are disabled */ + (void) prio; #endif return thread_node->pid;