lwip-devel
[Top][All Lists]
Advanced

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

Re: [lwip-devel] PPPOS and PBUF_POOL


From: Axel Lin
Subject: Re: [lwip-devel] PPPOS and PBUF_POOL
Date: Tue, 29 Aug 2017 23:43:05 +0800

2017-08-29 6:21 GMT+08:00 Joel Cunningham <address@hidden>:
> I’m getting more familiar with the PPPOS implementation in one of my projects 
> and was surprised to find that PBUF_POOL appears to be used in the transmit 
> pathway of PPPOS (i.e. pppos_write and pppos_netif_output). This doesn’t 
> match my understanding of PBUF_POOL which is that it should only be used for 
> RX.
>
> Also, if I look at pppoe.c and pppl2tp.c, both of those are using PBUF_RAM in 
> the their netif_output functions (pppoe_netif_output, pppoe_netif_output)
>
> Is this usage of PBUF_POOL intentional?

I think it's to avoid memory fragment.
The way pppos_write/pppos_netif_output using the PBUF_POOL is different from
other places because the pbuf is freed immediately by pppos_output_last().
It's just being used as a temporary buffer.

Regards,
Axel



reply via email to

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