Hi,

For PBUF_RAM type, LwIP mentions that "struct pbuf and its payload are
allocated in one piece of contiguous memory (so the first payload byte can
be calculated from struct pbuf)."

What If the pbuf structure is in place and the payload is in another place
(non-contiguous)? Is there any issue if I allocate the pbuf structure from
the pools and I set p->payload to point to the data in the frame memory?

In the SoC, we have data memory and frame memory. and we have our own
memory management unit (MMU). I updated pbuf_alloc(), when the type is
PBUF_RAM, to allocate a pbuf stucture only from the lwIP pools, and calls
the MMU to allocate memory to the frame, then I set p->payload to the frame
pointer.

I am able to send and receive ARPs, pings, and DHCP messeages.

Are there specific cases where this procedure will not work correctly?

Thanks,
Amena
-- 

Amena El-Homsi
Computer & Communication Engineer
Dipl. Eng,  M.S.
_______________________________________________
lwip-users mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/lwip-users

Reply via email to