Linux Kernel Network Programming - struct sk_buff data-structure - skb_push() API
Linux Kernel Network Programming - struct sk_buff data-structure - skb_push() API

Refer:
skb_push() – add data to the start of a buffer ↗

And here is the copy paste of skb_push() API (/net/core/skbuff.c) from the Kernel-source version 6.5.8 for quick reference:

/**
 *	skb_push - add data to the start of a buffer
 *	@skb: buffer to use
 *	@len: amount of data to add
 *
 *	This function extends the used data area of the buffer at the buffer
 *	start. If this would exceed the total buffer headroom the kernel will
 *	panic. A pointer to the first byte of the extra data is returned.
 */
void *skb_push(struct sk_buff *skb, unsigned int len)
{
	skb->data -= len;
	skb->len  += len;
	if (unlikely(skb->data < skb->head))
		skb_under_panic(skb, len, __builtin_return_address(0));
	return skb->data;
}
EXPORT_SYMBOL(skb_push);