skb_dst_is_noref (9) Linux Manual Page
skb_dst_is_noref – Test if skb dst isn’t refcounted Synopsis bool skb_dst_is_noref(const struct sk_buff * skb); Arguments skb buffer Copyright
The Linux Manuals (man pages) document is an important part of Linux documents. Linux Manuals are organized as several sections. Each section has a group of commands for a specific area in Linux usage, administration or development.
skb_dst_is_noref – Test if skb dst isn’t refcounted Synopsis bool skb_dst_is_noref(const struct sk_buff * skb); Arguments skb buffer Copyright
skb_dst – returns skb dst_entry Synopsis struct dst_entry *skb_dst(const struct sk_buff *skb); Arguments skb buffer Description Returns skb dst_entry, regardless of reference taken or not. Copyright
skb_dequeue_tail – remove from the tail of the queue Synopsis struct sk_buff *skb_dequeue_tail(struct sk_buff_head *list); Arguments list list to dequeue from Description Remove the tail of the list. The list lock is taken so the function may be used safely with other locking list functions. The tail item is returned or NULL if the list…
skb_dequeue – remove from the head of the queue Synopsis struct sk_buff *skb_dequeue(struct sk_buff_head *list); Arguments list list to dequeue from Description Remove the head of the list. The list lock is taken so the function may be used safely with other locking list functions. The head item is returned or NULL if the list…
skb_cow_head – skb_cow but only making the head writable Synopsis int skb_cow_head(struct sk_buff *skb, unsigned int headroom); Arguments skb buffer to cow headroom needed headroom Description This function is identical to skb_cow except that we replace the skb_cloned check by skb_header_cloned. It should be used when you only need to push on some header and…
skb_cow_data – Check that a socket buffer’s data buffers are writable Synopsis int skb_cow_data(struct sk_buff *skb, int tailbits, struct sk_buff **trailer); Arguments skb The socket buffer to check. tailbits Amount of trailing space to be added trailer Returned pointer to the skb where the tailbits space begins Description Make sure that the data buffers attached…
skb_cow – copy header of skb when it is required Synopsis int skb_cow(struct sk_buff *skb, unsigned int headroom); Arguments skb buffer to cow headroom needed headroom Description If the skb passed lacks sufficient headroom or its data part is shared, data is reallocated. If reallocation fails, an error is returned and original skb is not…
skb_copy_ubufs – copy userspace skb frags buffers to kernel Synopsis int skb_copy_ubufs(struct sk_buff *skb, gfp_t gfp_mask); Arguments skb the skb to modify gfp_mask allocation priority Description This must be called on SKBTX_DEV_ZEROCOPY skb. It will copy all frags into kernel and drop the reference to userspace pages. If this function is called from an interrupt…
skb_copy_expand – copy and expand sk_buff Synopsis struct sk_buff *skb_copy_expand(const struct sk_buff *skb, int newheadroom, int newtailroom, gfp_t gfp_mask); Arguments skb buffer to copy newheadroom new free bytes at head newtailroom new free bytes at tail gfp_mask allocation priority Description Make a copy of both an sk_buff and its data and while doing so allocate…
skb_copy_datagram_iter – Copy a datagram to an iovec iterator. Synopsis int skb_copy_datagram_iter(const struct sk_buff *skb, int offset, struct iov_iter *to, int len); Arguments skb buffer to copy offset offset in the buffer to start copying from to iovec iterator to copy to len amount of data to copy from buffer to iovec Copyright
skb_copy_datagram_from_iter – Copy a datagram from an iov_iter. Synopsis int skb_copy_datagram_from_iter(struct sk_buff *skb, int offset, struct iov_iter *from, int len); Arguments skb buffer to copy offset offset in the buffer to start copying to from the copy source len amount of data to copy to buffer from iovec Description Returns 0 or -EFAULT. Copyright
skb_copy_bits – copy bits from skb to kernel buffer Synopsis int skb_copy_bits(const struct sk_buff *skb, int offset, void *to, int len); Arguments skb source skb offset offset in source to destination buffer len number of bytes to copy Description Copy the specified number of bytes from the source skb to the destination buffer. CAUTION !…
skb_copy_and_csum_datagram_msg – Copy and checksum skb to user iovec. Synopsis int skb_copy_and_csum_datagram_msg(struct sk_buff *skb, int hlen, struct msghdr *msg); Arguments skb skbuff hlen hardware length msg destination Description Caller _must_ check that skb will fit to this iovec. Return 0 – success. -EINVAL – checksum failure. -EFAULT – fault during copy. Copyright
skb_copy – create private copy of an sk_buff Synopsis struct sk_buff *skb_copy(const struct sk_buff *skb, gfp_t gfp_mask); Arguments skb buffer to copy gfp_mask allocation priority Description Make a copy of both an sk_buff and its data. This is used when the caller wishes to modify the data and needs a private copy of the data…
skb_cloned – is the buffer a clone Synopsis int skb_cloned(const struct sk_buff *skb); Arguments skb buffer to check Description Returns true if the buffer was generated with skb_clone and is one of multiple shared copies of the buffer. Cloned buffers are shared data so must not be written to under normal circumstances. Copyright
skb_clone_writable – is the header of a clone writable Synopsis int skb_clone_writable(const struct sk_buff *skb, unsigned int len); Arguments skb buffer to check len length up to which to write Description Returns true if modifying the header part of the cloned buffer does not requires the data to be copied. Copyright
skb_clone_sk – create clone of skb, and take reference to socket Synopsis struct sk_buff *skb_clone_sk(struct sk_buff *skb); Arguments skb the skb to clone Description This function creates a clone of a buffer that holds a reference on sk_refcnt. Buffers created via this function are meant to be returned using sock_queue_err_skb, or free via kfree_skb. When…
skb_clone – duplicate an sk_buff Synopsis struct sk_buff *skb_clone(struct sk_buff *skb, gfp_t gfp_mask); Arguments skb buffer to clone gfp_mask allocation priority Description Duplicate an sk_buff. The new one is not owned by a socket. Both copies share the same packet data but not structure. The new buffer has a reference count of 1. If the…
skb_checksum_trimmed – validate checksum of an skb Synopsis struct sk_buff *skb_checksum_trimmed(struct sk_buff *skb, unsigned int transport_len, __sum16 (*skb_chkf)(struct sk_buff *skb)); Arguments skb the skb to check transport_len the data length beyond the network header skb_chkf checksum function to use Description Applies the given checksum function skb_chkf to the provided skb. Returns a checked and maybe…
skb_checksum_setup – set up partial checksum offset Synopsis int skb_checksum_setup(struct sk_buff *skb, bool recalculate); Arguments skb the skb to set up recalculate if true the pseudo-header checksum will be recalculated Copyright