1,5 → 1,5 |
/* |
* Copyright (c) 2008 Lukas Mejdrech |
* Copyright (c) 2009 Lukas Mejdrech |
* All rights reserved. |
* |
* Redistribution and use in source and binary forms, with or without |
26,7 → 26,7 |
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
*/ |
|
/** @addtogroup net |
/** @addtogroup lo |
* @{ |
*/ |
|
73,7 → 73,7 |
ERROR_PROPAGATE( find_device( device_id, & device )); |
if( device->state != state ){ |
device->state = state; |
nil_message( device, NET_NIL_DEVICE_STATE, device->state, NULL, NULL, NULL, NULL ); |
nil_message( device, NET_NIL_DEVICE_STATE, device->state, NULL ); |
} |
return EOK; |
} |
93,7 → 93,7 |
( ** device ).state = NETIF_STOPPED; |
( ** device ).flags = NULL; |
( ** device ).mtu = DEFAULT_MTU; |
if( ERROR_OCCURED( device_map_add( & netif_globals.device_map, ( ** device ).device_id, * device ))){ |
if( ERROR_OCCURRED( device_map_add( & netif_globals.device_map, ( ** device ).device_id, * device ))){ |
free( * device ); |
* device = NULL; |
return ERROR_CODE; |
138,8 → 138,8 |
// get configuration |
message = async_send_2( netif_globals.networking_phone, NET_NET_GET_DEVICE_CONF, device->device_id, count, & answer ); |
// send names and get settings |
if( ERROR_OCCURED( measured_strings_send( netif_globals.networking_phone, configuration, count )) |
|| ERROR_OCCURED( measured_strings_return( netif_globals.networking_phone, & settings, & data, count ))){ |
if( ERROR_OCCURRED( measured_strings_send( netif_globals.networking_phone, configuration, count )) |
|| ERROR_OCCURRED( measured_strings_return( netif_globals.networking_phone, & settings, & data, count ))){ |
async_wait_for( message, NULL ); |
return ERROR_CODE; |
} |
178,9 → 178,9 |
++ device->stats.rx_dropped; |
return EOK; |
} |
async_msg_2( device->nil_phone, NET_NIL_RECEIVED, device_id, packet_get_id( received )); |
nil_message( device, NET_NIL_RECEIVED, packet_get_id( received ), NULL ); |
// message = async_send_1( device->nil_phone, NET_NIL_RECEIVED, ( device_id ), & answer ); |
// if( ERROR_OCCURED( packet_send( received, device->nil_phone ))){ |
// if( ERROR_OCCURRED( packet_send( received, device->nil_phone ))){ |
// ++ device->stats.rx_dropped; |
// } |
// if( result != EOK ) ++ device->stats.rx_dropped; |