Transmits data using a communications device handler .
#include <sys/types.h> #include <sys/errno.h> #include <aixif/net_if.h>
int net_xmit (ifp, m, netfp, lngth, m_ext) struct ifnet *ifp; struct mbuf *m; struct file *netfp; int lngth; struct mbuf *m_ext;
ifp | Indicates an address of the ifnet structure for this interface. |
m | Specifies the address of an mbuf structure containing the data to transmit. |
netfp | Indicates the open file pointer obtained from the net_attach kernel service. |
lngth | Indicates the total length of the buffer being transmitted. |
m_ext | Indicates the address of an mbuf structure containing a write extension. |
The net_xmit kernel service builds a uio structure and then invokes the fp_rwuio service to transmit a packet. The net_xmit_trace kernel service is an alternative for network interfaces that choose not to use the net_xmit kernel service.
The net_xmit kernel service can be called from either the process or interrupt environment.
0 | Indicates that the packet was transmitted successfully. |
ENOBUFS | Indicates that buffer resources were not available. |
The net_xmit kernel service returns a value from the fp_rwuio service when an error occurs during a call to that service.
The net_xmit kernel service is part of Base Operating System (BOS) Runtime.
The fp_rwuio kernel service, net_xmit_trace kernel service.
Network Kernel Services in AIX Kernel Extensions and Device Support Programming Concepts.