- PBUF_RAM, /* pbuf data is stored in RAM */
- PBUF_ROM, /* pbuf data is stored in ROM */
- PBUF_REF, /* pbuf comes from the pbuf pool */
- PBUF_POOL /* pbuf payload refers to RAM */
+ /** pbuf data is stored in RAM, used for TX mostly, struct pbuf and its payload
+ are allocated in one piece of contiguous memory (so the first payload byte
+ can be calculated from struct pbuf)
+ pbuf_alloc() allocates PBUF_RAM pbufs as unchained pbufs (although that might
+ change in future versions) */
+ PBUF_RAM,
+ /** pbuf data is stored in ROM, i.e. struct pbuf and its payload are located in
+ totally different memory areas. Since it points to ROM, payload does not
+ have to be copied when queued for transmission. */
+ PBUF_ROM,
+ /** pbuf comes from the pbuf pool. Much like PBUF_ROM but payload might change
+ so it has to be duplicated when queued before transmitting, depending on
+ who has a 'ref' to it. */
+ PBUF_REF,
+ /** pbuf payload refers to RAM. This one comes from a pool and should be used
+ for RX. Payload can be chained (scatter-gather RX) but like PBUF_RAM, struct
+ pbuf and its payload are allocated in one piece of contiguous memory (so
+ the first payload byte can be calculated from struct pbuf) */
+ PBUF_POOL