32,6 → 32,8 |
|
/** @file |
* Network interface module skeleton. |
* The skeleton has to be part of each network interface module. |
* The skeleton can be also part of the module bundled with the network interface layer. |
*/ |
|
#ifndef __NET_NETIF_H__ |
114,16 → 116,42 |
void null_device_stats( device_stats_ref stats ); |
|
// prepared for future optimalizations |
/** \todo |
/** Releases the given packet. |
* @param packet_id The packet identifier. Input parameter. |
*/ |
void netif_pq_release( packet_id_t packet ); |
void netif_pq_release( packet_id_t packet_id ); |
|
/** \todo |
/** Allocates new packet to handle the given content size. |
* @param content The minimum content size. Input parameter. |
* @returns The allocated packet. |
* @returns NULL if there is an error. |
*/ |
packet_t netif_packet_get_1( size_t content ); |
|
/** Processes the netif module messages. |
* @param callid The message identifier. Input parameter. |
* @param call The message parameters. Input parameter. |
* @param answer The message answer parameters. Output parameter. |
* @param answer_count The last parameter for the actual answer in the answer parameter. Output parameter. |
* @returns EOK on success. |
* @returns ENOTSUP if the message is not known. |
* @returns Other error codes as defined for each specific module message function. |
* @see netif_interface.h |
* @see IS_NET_NETIF_MESSAGE() |
*/ |
int netif_message( ipc_callid_t callid, ipc_call_t * call, ipc_call_t * answer, int * answer_count ); |
|
/** Initializes the netif module. |
* The function has to be defined in each module. |
* @param client_connection The client connection functio to be registered. Input parameter. |
* @returns EOK on success. |
* @returns Other error codes as defined for each specific module message function. |
*/ |
int netif_init_module( async_client_conn_t client_connection ); |
|
/** Starts and maintains the netif module until terminated. |
* @returns EOK after the module is terminated. |
*/ |
int netif_run_module( void ); |
|
#endif |