Implements user requests for raw protocols.
| Item | Description | 
|---|---|
| so | Identifies the address of a raw socket. | 
| req | Specifies the request command. | 
| m | Specifies the address of an mbuf structure containing data. | 
| nam | Specifies the address of an mbuf structure containing the sockaddr structure. | 
| control | This parameter should be set to a null value. | 
The raw_usrreq kernel service implements user requests for the raw protocol.
The raw_usrreq service supports the following commands:
| Command | Description | 
|---|---|
| PRU_ABORT | Aborts (fast DISCONNECT, DETACH). | 
| PRU_ACCEPT | Accepts connection from peer. | 
| PRU_ATTACH | Attaches protocol to up. | 
| PRU_BIND | Binds socket to address. | 
| PRU_CONNECT | Establishes connection to peer. | 
| PRU_CONNECT2 | Connects two sockets. | 
| PRU_CONTROL | Controls operations on protocol. | 
| PRU_DETACH | Detaches protocol from up. | 
| PRU_DISCONNECT | Disconnects from peer. | 
| PRU_LISTEN | Listens for connection. | 
| PRU_PEERADDR | Fetches peer's address. | 
| PRU_RCVD | Have taken data; more room now. | 
| PRU_RCVOOB | Retrieves out of band data. | 
| PRU_SEND | Sends this data. | 
| PRU_SENDOOB | Sends out of band data. | 
| PRU_SENSE | Returns status into m. | 
| PRU_SOCKADDR | Fetches socket's address. | 
| PRU_SHUTDOWN | Will not send any more data. | 
Any unrecognized command causes the panic kernel service to be called.
The raw_userreq kernel service can be called from either the process or interrupt environment.
| Item | Description | 
|---|---|
| EOPNOTSUPP | Indicates an unsupported command. | 
| EINVAL | Indicates a parameter error. | 
| EACCES | Indicates insufficient authority to support the PRU_ATTACH command. | 
| ENOTCONN | Indicates an attempt to detach when not attached. | 
| EISCONN | Indicates that the caller tried to connect while already connected. |