Lines Matching refs:offset

210   u16_t offset;
214 /* determine header offset */
218 offset = PBUF_LINK_HLEN + PBUF_IP_HLEN + PBUF_TRANSPORT_HLEN;
222 offset = PBUF_LINK_HLEN + PBUF_IP_HLEN;
226 offset = PBUF_LINK_HLEN;
229 offset = 0;
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)));
255 p->len = LWIP_MIN(length, PBUF_POOL_BUFSIZE_ALIGNED - LWIP_MEM_ALIGN_SIZE(offset));
260 (PBUF_POOL_BUFSIZE_ALIGNED - LWIP_MEM_ALIGN_SIZE(offset)) > 0 );
308 p = (struct pbuf*)mem_malloc(LWIP_MEM_ALIGN_SIZE(SIZEOF_STRUCT_PBUF + offset) + LWIP_MEM_ALIGN_SIZE(length));
313 p->payload = LWIP_MEM_ALIGN((void *)((u8_t *)p + SIZEOF_STRUCT_PBUF + offset));
370 u16_t offset;
373 /* determine header offset */
377 offset = PBUF_LINK_HLEN + PBUF_IP_HLEN + PBUF_TRANSPORT_HLEN;
381 offset = PBUF_LINK_HLEN + PBUF_IP_HLEN;
385 offset = PBUF_LINK_HLEN;
388 offset = 0;
395 if (LWIP_MEM_ALIGN_SIZE(offset) + length > payload_mem_len) {
402 p->pbuf.payload = (u8_t *)payload_mem + LWIP_MEM_ALIGN_SIZE(offset);
914 * @param offset offset into the packet buffer from where to begin copying len bytes
918 pbuf_copy_partial(struct pbuf *buf, void *dataptr, u16_t len, u16_t offset)
936 if ((offset != 0) && (offset >= p->len)) {
938 offset -= p->len;
941 buf_copy_len = p->len - offset;
945 MEMCPY(&((char*)dataptr)[left], &((char*)p->payload)[offset], buf_copy_len);
949 offset = 0;
1034 * @param start_offset offset of p->payload where to copy the data to
1070 * WARNING: returns zero for offset >= p->tot_len
1073 * @param offset offset into p of the byte to return
1074 * @return byte at an offset into p OR ZERO IF 'offset' >= p->tot_len
1077 pbuf_get_at(struct pbuf* p, u16_t offset)
1079 u16_t copy_from = offset;
1094 /** Compare pbuf contents at specified offset with memory s2, both of length n
1097 * @param offset offset into p at wich to start comparing
1104 pbuf_memcmp(struct pbuf* p, u16_t offset, const void* s2, u16_t n)
1106 u16_t start = offset;
1129 /** Find occurrence of mem (with length mem_len) in pbuf p, starting at offset
1136 * @param start_offset offset into p at which to start searching
1157 /** Find occurrence of substr with length substr_len in pbuf p, start at offset