Lines Matching refs:payload

183  * @param length size of the pbuf's payload
248 /* make the payload pointer point 'offset' bytes into pbuf data memory */
249 p->payload = LWIP_MEM_ALIGN((void *)((u8_t *)p + (SIZEOF_STRUCT_PBUF + offset)));
250 LWIP_ASSERT("pbuf_alloc: pbuf p->payload properly aligned",
251 ((mem_ptr_t)p->payload % MEM_ALIGNMENT) == 0);
256 LWIP_ASSERT("check p->payload + p->len does not overflow pbuf",
257 ((u8_t*)p->payload + p->len <=
290 q->payload = (void *)((u8_t *)q + SIZEOF_STRUCT_PBUF);
291 LWIP_ASSERT("pbuf_alloc: pbuf q->payload properly aligned",
292 ((mem_ptr_t)q->payload % MEM_ALIGNMENT) == 0);
293 LWIP_ASSERT("check p->payload + p->len does not overflow pbuf",
294 ((u8_t*)p->payload + p->len <=
313 p->payload = LWIP_MEM_ALIGN((void *)((u8_t *)p + SIZEOF_STRUCT_PBUF + offset));
318 LWIP_ASSERT("pbuf_alloc: pbuf->payload properly aligned",
319 ((mem_ptr_t)p->payload % MEM_ALIGNMENT) == 0);
321 /* pbuf references existing (non-volatile static constant) ROM payload? */
323 /* pbuf references existing (externally allocated) RAM payload? */
334 p->payload = NULL;
355 * @param length size of the pbuf's payload
359 * @param payload_mem pointer to the buffer that is used for payload and headers,
402 p->pbuf.payload = (u8_t *)payload_mem + LWIP_MEM_ALIGN_SIZE(offset);
404 p->pbuf.payload = NULL;
473 q = (struct pbuf *)mem_trim(q, (u16_t)((u8_t *)q->payload - (u8_t *)q) + rem_len);
491 * Adjusts the payload pointer to hide or reveal headers in the payload.
493 * Adjusts the ->payload pointer so that space for a header
494 * (dis)appears in the pbuf payload.
496 * The ->payload, ->tot_len and ->len fields are adjusted.
506 * not move the payload pointer in front of the start of the buffer.
514 void *payload;
535 LWIP_ASSERT("p->payload - increment_magnitude >= p + SIZEOF_STRUCT_PBUF",
536 (u8_t *)p->payload - increment_magnitude >= (u8_t *)p + SIZEOF_STRUCT_PBUF);
541 /* remember current payload pointer */
542 payload = p->payload;
546 /* set new payload pointer */
547 p->payload = (u8_t *)p->payload - header_size_increment;
549 if ((u8_t *)p->payload < (u8_t *)p + SIZEOF_STRUCT_PBUF) {
552 (void *)p->payload, (void *)(p + 1)));
553 /* restore old payload pointer */
554 p->payload = payload;
560 /* hide a header in the payload? */
562 /* increase payload pointer */
563 p->payload = (u8_t *)p->payload - header_size_increment;
565 /* cannot expand payload to front (yet!)
579 (void *)payload, (void *)p->payload, header_size_increment));
874 MEMCPY((u8_t*)p_to->payload + offset_to, (u8_t*)p_from->payload + offset_from, len);
934 /* Note some systems use byte copy if dataptr or one of the pbuf payload pointers are unaligned. */
945 MEMCPY(&((char*)dataptr)[left], &((char*)p->payload)[offset], buf_copy_len);
980 /* Note some systems use byte copy if dataptr or one of the pbuf payload pointers are unaligned. */
989 MEMCPY(p->payload, &((char*)dataptr)[copied_total], buf_copy_len);
1034 * @param start_offset offset of p->payload where to copy the data to
1057 dst_ptr = ((char*)p->payload) + start_offset;
1089 return ((u8_t*)q->payload)[copy_from];