lwip-users
[Top][All Lists]
Advanced

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

Re: [lwip-users] Zero-copy TX


From: Simon Goldschmidt
Subject: Re: [lwip-users] Zero-copy TX
Date: Fri, 28 Oct 2011 18:05:00 +0200

Mason <address@hidden> wrote:

> I don't think it's possible to use mem_malloc as a packet
> buffer allocator, as there are other types of uses, e.g.
> 
>  dhcp = (struct dhcp *)mem_malloc(sizeof(struct dhcp));
>  autoip = (struct autoip *)mem_malloc(sizeof(struct autoip));

These can be avoided by calling the appropriate init function where you can 
pass a preallocated struct dhcp/autoip.

> What I'd like is to be able to "redirect" pbuf_alloc to use
> my buffer allocator, but the pbuf struct and the payload buffer
> would not be contiguous, which violates the implicit assumptions
> of PBUF_RAM pbufs, IIUC.

Well, that doesn't work, obviously. I thought you could place both the payload 
and the struct pbuf into your memory...

BTW: I can't get my old ARM board running, so unfortunately, I can't test 
zero-copy on any hardware right now. :-(

Simon



reply via email to

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