m_adj Kernel Service

Purpose

Adjusts the size of an mbuf chain.

Syntax

#include <sys/types.h>
#include <sys/errno.h>
#include <sys/mbuf.h>

void m_adj ( m,  diff)
struct mbuf *m;
int diff;

Parameters

Item Description
m Specifies the mbuf chain to be adjusted.
diff Specifies the number of bytes to be removed.

Description

The m_adj kernel service adjusts the size of an mbuf chain by the number of bytes specified by the diff parameter. If the number specified by the diff parameter is nonnegative, the bytes are removed from the front of the chain. If this number is negative, the alteration is done from back to front.

Execution Environment

The m_adj kernel service can be called from either the process or interrupt environment.

Return Values

The m_adj service has no return values.