Lou,

This has been encountered before and there is a workaround: just define
the SYS_ARCH_PROTECT() and SYS_ARCH_UNPROTECT() macros in your
lwipopts.h. This avoids the sys_prot_t type being parsed altogether.

-------------------------------
#define NO_SYS 1

#include "ei_di_in.h"  // prototype for setintlvl() function

// using int masking (no mutexes, etc)
#define SYS_LIGHTWEIGHT_PROT 1   

#define SYS_ARCH_DECL_PROTECT(lev) int lev;
// Define SYS_ARCH_PROTECT to mask just ETH0 interrupts
#define SYS_ARCH_PROTECT(lev) lev = setintlvl(2); 
#define SYS_ARCH_UNPROTECT(lev) setintlvl(lev);
----------------------------------

See this thread in the archives for more background:

http://lists.gnu.org/archive/html/lwip-devel/2009-03/msg00017.html
  
Hope this helps!

- Jim
__

James M. Pettinato, Jr.
Software Engineer
E: [email protected] | P: 814 898 5250 

FMC Technologies Measurement Solutions Inc.
1602 Wagner Avenue | Erie PA | 16510 USA 
Phone: 814 898 5000 | Fax: 814 899-3414
www.fmctechnologies.com 

 

-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf
Of Lou Cypher
Sent: Friday, October 30, 2009 10:52 AM
To: Mailing list for lwIP users
Subject: Re: [lwip-users] lwIP 1.3.2-rc1 released

I'm pleased to see the updates, and the soon to be released 1.3.2;
recompiling with rc1 an application I have with 1.3.1 remembers me of a
tiny issue, that I faced even in previous releases (and kept being so
tiny I always forgot to report...).

I'm using
  #define  NO_SYS                       1
  #define  SYS_LIGHTWEIGHT_PROT         1
and in sys.h I always get complaints from the compiler about sys_prot_t,
as unknown symbol.
Delving into sources it looks like line 78, sys.h:
  #include "arch/sys_arch.h"
should be included anyway, not just when NO_SYS is undefined; with that
change in fact, my code gets compiled silently.
Did I spot the right thing, or am I possibly running with unexpected
#defines?

Lou

____________________________________________________________
FREE 3D MARINE AQUARIUM SCREENSAVER - Watch dolphins, sharks & orcas on
your desktop!
Check it out at http://www.inbox.com/marineaquarium


_______________________________________________
lwip-users mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/lwip-users


_______________________________________________
lwip-users mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/lwip-users

Reply via email to