Subversion Repositories HelenOS

Compare Revisions

Ignore whitespace Rev 4755 → Rev 4756

/branches/network/uspace/srv/net/app/nettest2/nettest2.c
60,8 → 60,8
 
/** Module entry point.
* Starts testing.
* @param argc The number of command line parameters. Input parameter.
* @param argv The command line parameters. Input parameter.
* @param[in] argc The number of command line parameters.
* @param[in] argv The command line parameters.
* @returns EOK on success.
*/
int main( int argc, char * argv[] );
71,7 → 71,7
void print_help( void );
 
/** Translates the character string to the protocol family number.
* @param name The protocol family name. Input parameter.
* @param[in] name The protocol family name.
* @returns The corresponding protocol family number.
* @returns EPFNOSUPPORTED if the protocol family is not supported.
*/
78,7 → 78,7
int parse_protocol_family( const char * name );
 
/** Translates the character string to the socket type number.
* @param name The socket type name. Input parameter.
* @param[in] name The socket type name.
* @returns The corresponding socket type number.
* @returns ESOCKNOSUPPORTED if the socket type is not supported.
*/
86,17 → 86,17
 
/** Refreshes the data.
* Fills the data block with the NETTEST1_TEXT pattern.
* @param data The data block. Output parameter.
* @param size The data block size in bytes. Input parameter
* @param[out] data The data block.
* @param[in] size The data block size in bytes.
*/
void refresh_data( char * data, size_t size );
 
/** Creates new sockets.
* @param verbose A value indicating whether to print out verbose information. Input parameter.
* @param socket_ids A field to store the socket identifiers. Output parameter.
* @param sockets The number of sockets to create. Should be at most the size of the field. Input parameter.
* @param family The socket address family. Input parameter.
* @param type The socket type. Input parameter.
* @param[in] verbose A value indicating whether to print out verbose information.
* @param[out] socket_ids A field to store the socket identifiers.
* @param[in] sockets The number of sockets to create. Should be at most the size of the field.
* @param[in] family The socket address family.
* @param[in] type The socket type.
* @returns EOK on success.
* @returns Other error codes as defined for the socket() function.
*/
103,9 → 103,9
int sockets_create( int verbose, int * socket_ids, int sockets, int family, sock_type_t type );
 
/** Closes sockets.
* @param verbose A value indicating whether to print out verbose information. Input parameter.
* @param socket_ids A field of stored socket identifiers. Input parameter.
* @param sockets The number of sockets in the field. Should be at most the size of the field. Input parameter.
* @param[in] verbose A value indicating whether to print out verbose information.
* @param[in] socket_ids A field of stored socket identifiers.
* @param[in] sockets The number of sockets in the field. Should be at most the size of the field.
* @returns EOK on success.
* @returns Other error codes as defined for the closesocket() function.
*/
112,11 → 112,11
int sockets_close( int verbose, int * socket_ids, int sockets );
 
/** Connects sockets.
* @param verbose A value indicating whether to print out verbose information. Input parameter.
* @param socket_ids A field of stored socket identifiers. Input parameter.
* @param sockets The number of sockets in the field. Should be at most the size of the field. Input parameter.
* @param address The destination host address to connect to. Input parameter.
* @param addrlen The length of the destination address in bytes. Input parameter.
* @param[in] verbose A value indicating whether to print out verbose information.
* @param[in] socket_ids A field of stored socket identifiers.
* @param[in] sockets The number of sockets in the field. Should be at most the size of the field.
* @param[in] address The destination host address to connect to.
* @param[in] addrlen The length of the destination address in bytes.
* @returns EOK on success.
* @returns Other error codes as defined for the connect() function.
*/
123,14 → 123,14
int sockets_connect( int verbose, int * socket_ids, int sockets, struct sockaddr * address, socklen_t addrlen );
 
/** Sends data via sockets.
* @param verbose A value indicating whether to print out verbose information. Input parameter.
* @param socket_ids A field of stored socket identifiers. Input parameter.
* @param sockets The number of sockets in the field. Should be at most the size of the field. Input parameter.
* @param address The destination host address to send data to. Input parameter.
* @param addrlen The length of the destination address in bytes. Input parameter.
* @param data The data to be sent. Input parameter.
* @param size The data size in bytes. Input parameter
* @param messages The number of datagrams per socket to be sent. Input parameter.
* @param[in] verbose A value indicating whether to print out verbose information.
* @param[in] socket_ids A field of stored socket identifiers.
* @param[in] sockets The number of sockets in the field. Should be at most the size of the field.
* @param[in] address The destination host address to send data to.
* @param[in] addrlen The length of the destination address in bytes.
* @param[in] data The data to be sent.
* @param[in] size The data size in bytes.
* @param[in] messages The number of datagrams per socket to be sent.
* @returns EOK on success.
* @returns Other error codes as defined for the sendto() function.
*/
137,14 → 137,14
int sockets_sendto( int verbose, int * socket_ids, int sockets, struct sockaddr * address, socklen_t addrlen, char * data, int size, int messages );
 
/** Receives data via sockets.
* @param verbose A value indicating whether to print out verbose information. Input parameter.
* @param socket_ids A field of stored socket identifiers. Input parameter.
* @param sockets The number of sockets in the field. Should be at most the size of the field. Input parameter.
* @param address The source host address of received datagrams. Input parameter.
* @param addrlen The maximum length of the source address in bytes. The actual size of the source address is set instead. Input/output parameter.
* @param data The received data. Output parameter.
* @param size The maximum data size in bytes. Input parameter
* @param messages The number of datagrams per socket to be received. Input parameter.
* @param[in] verbose A value indicating whether to print out verbose information.
* @param[in] socket_ids A field of stored socket identifiers.
* @param[in] sockets The number of sockets in the field. Should be at most the size of the field.
* @param[in] address The source host address of received datagrams.
* @param[in,out] addrlen The maximum length of the source address in bytes. The actual size of the source address is set instead.
* @param[out] data The received data.
* @param[in] size The maximum data size in bytes.
* @param[in] messages The number of datagrams per socket to be received.
* @returns EOK on success.
* @returns Other error codes as defined for the recvfrom() function.
*/
153,14 → 153,14
/** Sends and receives data via sockets.
* Each datagram is sent and a reply read consequently.
* The next datagram is sent after the reply is received.
* @param verbose A value indicating whether to print out verbose information. Input parameter.
* @param socket_ids A field of stored socket identifiers. Input parameter.
* @param sockets The number of sockets in the field. Should be at most the size of the field. Input parameter.
* @param address The destination host address to send data to. The source host address of received datagrams is set instead. Input/output parameter.
* @param addrlen The length of the destination address in bytes. Input parameter.
* @param data The data to be sent. The received data are set instead. Input/output parameter.
* @param size The data size in bytes. Input parameter
* @param messages The number of datagrams per socket to be received. Input parameter.
* @param[in] verbose A value indicating whether to print out verbose information.
* @param[in] socket_ids A field of stored socket identifiers.
* @param[in] sockets The number of sockets in the field. Should be at most the size of the field.
* @param[in,out] address The destination host address to send data to. The source host address of received datagrams is set instead.
* @param[in] addrlen The length of the destination address in bytes.
* @param[in,out] data The data to be sent. The received data are set instead.
* @param[in] size The data size in bytes.
* @param[in] messages The number of datagrams per socket to be received.
* @returns EOK on success.
* @returns Other error codes as defined for the recvfrom() function.
*/
168,7 → 168,7
 
/** Prints a mark.
* If the index is a multiple of ten, a different mark is printed.
* @param index The index of the mark to be printed. Input parameter.
* @param[in] index The index of the mark to be printed.
*/
void print_mark( int index );