|
From: | Peter Graf |
Subject: | Re: [lwip-users] sys_timeout |
Date: | Mon, 06 Mar 2006 23:27:10 +0100 |
User-agent: | Thunderbird 1.5 (Windows/20051201) |
Curt McDowell wrote:
The way sys_arch is implemented, timeouts can only fire when the main process is sleeping on a semaphore or mailbox using either sys_sem_wait() or sys_mbox_fetch() in src/core/sys.c. I think it's an architectural deficiency that any of sys_arch is implemented in the lwip core.
I found it a benefit.
> sys_timeout() and other sys_arch functionality with a native O/S implementation.The whole idea of sys_arch is to provide a system abstraction, but currently it's difficult to replace
I don't see a point in replacing sys_timeout(). Adam had moved this and other stuff which previously required architure specific implementation into the core, and thereby reached the goal of easier portability, in my case and many others. I don't see a proper multitasking O/S where the few system functions are hard to implement the way things are.
Worse, any application that wants to use lwip is forced to be based on lwip's sys_arch primitives.
If lwIP is intialized and the main+tcp+interface threads are active (this can be set up outside the application), the application just has to link itself into lwIP's thread list once. Afterwards it is free to call the lwIP networking API(s) or not, but it's not required to use the sys_arch primitives.
All the best Peter
[Prev in Thread] | Current Thread | [Next in Thread] |