[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [lwip-users] Help,about pbuf_free
From: |
Leon Woestenberg |
Subject: |
Re: [lwip-users] Help,about pbuf_free |
Date: |
Tue, 10 Aug 2004 15:27:24 +0200 |
Hello,
On Fri, 2004-08-06 at 12:56, tao meng wrote:
> Hi,everyone:
> when I run lwip0.7.2 + ucos_ii 2.70 on ADI-BF532,it shows that
> "p->ref < = 0",but what make it happened,I have already use mutex as a lock
> to protect the p->ref from being changed by others at the same time!And
>
An interrupt can pre-empt the mutex lock.
So check your interrupt handler. If it runs in interrupt context you do
not have mutexes available (the call will probably fail without a lock
acquired).
Creating a late/deferred/bottom half/task based interrupt handler can
solve this; it must acquire the lock out of interrupt context.
Regards,
Leon.