lwip-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lwip-users] PBUFS + LWIP 1.3.0 + memory allocation


From: Jeff Barber
Subject: Re: [lwip-users] PBUFS + LWIP 1.3.0 + memory allocation
Date: Wed, 10 Feb 2010 12:42:16 -0500

There is a version of mem_realloc in mem.h that is marked 'static' but
not 'static inline'.  This version is activated only with certain
lwipopts settings.  Any source file that includes mem.h gets a new
version of the code compiled within it.  If the source file doesn't
reference mem_realloc, that code is unreachable (hence the warning).
So you'd expect to get this warning in any file that included mem.h
*except* for pbuf.c (since pbuf_realloc actually references the
function).

For a gcc user, it would be better if it were declared 'static inline'
because then gcc doesn't complain (and doesn't generate any code
unless it's referenced).  I don't know how that translates to other
compilers.

Jeff

On Wed, Feb 10, 2010 at 12:04 PM, Bill Auerbach
<address@hidden> wrote:
> This warning is harmless.  It simply means that there is a function (in
> mem.c) that is defined but unused by your build.  It is only referenced by
> pbuf_realloc, which indicates that pbuf_realloc isn't used either.  Why no
> warning for pbuf_realloc?  I don't know and find this peculiar.  Maybe
> someone else with AVR32 experience will understand this better, but I still
> am almost certain the warning can be ignored.
>
> Bill
>
>>-----Original Message-----
>>From: address@hidden
>>[mailto:address@hidden On
>>Behalf Of Sirjee Rooplall
>>Sent: Wednesday, February 10, 2010 9:30 AM
>>To: Mailing list for lwIP users
>>Subject: Re: [lwip-users] PBUFS + LWIP 1.3.0 + memory allocation
>>Importance: High
>>
>>Hi, I have port to LWIP 1.3.2, and now I get this warning!
>>mem_realloc defined but not used.
>>
>>How do I get rid of this warning, rather what has changed from 1.3.0 to
>>1.3.2 that would cause this warning to surface after the port?
>>
>>Kind Regards, Sirjee Rooplall Figment Design laboratories (Pty) Ltd
>>mailto:
>>address@hidden Mobile: +27 (0)83 230 8466
>>----- Original Message -----
>>From: "Bill Auerbach" <address@hidden>
>>To: "'Mailing list for lwIP users'" <address@hidden>
>>Sent: Wednesday, February 10, 2010 3:58 PM
>>Subject: RE: [lwip-users] PBUFS + LWIP 1.3.0 + memory allocation
>>
>>
>>> >Hi, what were the problems, that warrant me to move to 1.3.2
>>>>
>>>>I am using the AVR32 UC3 port of LWIP 1.3.0 which was done by ATMEL.
>>>>
>>>>I just cannot move to 1.3.2 because I am not sure whats involved to
>>>>produce
>>>>a new port for the AVR32 UC3 device.
>>>
>>> Before you decide you cannot move from 1.3.0 to 1.3.2 because you are
>>not
>>> sure what's involved with the port, why not find out what is involved
>>with
>>> the port and *then* decide that you cannot move.  From the standpoint
>>of
>>> the
>>> Ethernet driver interface there should be no problems.  The rest of
>>lwIP
>>> is
>>> not hardware specific and can be replaced.  Create a new folder with a
>>> copy
>>> of your 1.3.0 and replace the lwIP sources from 1.3.2 - I'm betting it
>>> works
>>> without problems.  It has for me on 3 platforms.
>>>
>>> Bill
>>>
>>>
>>>
>>>
>>>
>>>
>>> _______________________________________________
>>> lwip-users mailing list
>>> address@hidden
>>> http://lists.nongnu.org/mailman/listinfo/lwip-users
>>>
>>
>>
>>
>>_______________________________________________
>>lwip-users mailing list
>>address@hidden
>>http://lists.nongnu.org/mailman/listinfo/lwip-users
>
>
>
> _______________________________________________
> lwip-users mailing list
> address@hidden
> http://lists.nongnu.org/mailman/listinfo/lwip-users
>




reply via email to

[Prev in Thread] Current Thread [Next in Thread]