Subversion Repositories HelenOS

Rev

Rev 4351 | Rev 4574 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 4351 Rev 4505
Line 78... Line 78...
78
    ERROR_PROPAGATE( add_module( NULL, & net_globals.modules, ETHERNET_NAME, ETHERNET_FILENAME, SERVICE_ETHERNET, 0, connect_to_service ));
78
    ERROR_PROPAGATE( add_module( NULL, & net_globals.modules, ETHERNET_NAME, ETHERNET_FILENAME, SERVICE_ETHERNET, 0, connect_to_service ));
79
 
79
 
80
    task_id = spawn( "/srv/ip" );
80
    task_id = spawn( "/srv/ip" );
81
    if( ! task_id ) return EINVAL;
81
    if( ! task_id ) return EINVAL;
82
    ERROR_PROPAGATE( add_module( NULL, & net_globals.modules, IP_NAME, IP_FILENAME, SERVICE_IP, task_id, ip_connect_module ));
82
    ERROR_PROPAGATE( add_module( NULL, & net_globals.modules, IP_NAME, IP_FILENAME, SERVICE_IP, task_id, ip_connect_module ));
83
//  if( ! spawn( "/srv/udp" )) return EINVAL;
83
    if( ! spawn( "/srv/udp" )) return EINVAL;
84
//  if( ! spawn( "/srv/tcp" )) return EINVAL;
84
    if( ! spawn( "/srv/tcp" )) return EINVAL;
85
//  if( ! spawn( "/srv/socket" )) return EINVAL;
85
//  if( ! spawn( "/srv/socket" )) return EINVAL;
86
//  not always necesssary
86
//  not always necesssary
87
//  if( ! spawn( "/srv/arp" )) return EINVAL;
87
//  if( ! spawn( "/srv/arp" )) return EINVAL;
88
//  if( ! spawn( "/srv/rarp" )) return EINVAL;
88
//  if( ! spawn( "/srv/rarp" )) return EINVAL;
89
//  if( ! spawn( "/srv/icmp" )) return EINVAL;
89
//  if( ! spawn( "/srv/icmp" )) return EINVAL;
Line 98... Line 98...
98
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "NETIF", LO_NAME ));
98
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "NETIF", LO_NAME ));
99
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "IL", IP_NAME ));
99
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "IL", IP_NAME ));
100
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "IP_CONFIG", "static" ));
100
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "IP_CONFIG", "static" ));
101
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "IP_ADDR", "127.0.0.1" ));
101
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "IP_ADDR", "127.0.0.1" ));
102
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "NETMASK", "255.0.0.0" ));
102
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "NETMASK", "255.0.0.0" ));
-
 
103
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "MTU", "15535" ));
103
    }else if( str_lcmp( name, "ne2k", 4 ) == 0 ){
104
    }else if( str_lcmp( name, "ne2k", 4 ) == 0 ){
104
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "NAME", "eth0" ));
105
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "NAME", "eth0" ));
105
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "NETIF", DP8390_NAME ));
106
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "NETIF", DP8390_NAME ));
106
        // standalone ethernet
107
        // standalone ethernet
107
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "NIL", ETHERNET_NAME ));
108
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "NIL", ETHERNET_NAME ));
108
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "ETH_MODE", "DIX" )); //8023_2_LSAP( not supported ), 8023_2_SNAP
109
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "ETH_MODE", "DIX" )); //8023_2_LSAP( not supported ), 8023_2_SNAP
109
//      ERROR_PROPAGATE( add_configuration( & netif->configuration, "ETH_DUMMY", "yes" )); //anything else not starting with 'y'
110
//      ERROR_PROPAGATE( add_configuration( & netif->configuration, "ETH_DUMMY", "yes" )); //anything else not starting with 'y'
110
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "IL", IP_NAME ));
111
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "IL", IP_NAME ));
111
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "IRQ", "9" ));
112
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "IRQ", "9" ));
112
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "IO", "300" ));
113
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "IO", "300" ));
113
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "MTU", "1492" ));
114
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "MTU", "576" ));
114
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "IP_CONFIG", "static" ));
115
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "IP_CONFIG", "static" ));
115
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "IP_ADDR", "10.0.2.15" ));
116
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "IP_ADDR", "10.0.2.15" ));
116
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "NETMASK", "255.255.255.0" ));
117
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "NETMASK", "255.255.255.240" ));
117
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "BROADCAST", "10.0.2.255" ));
118
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "BROADCAST", "10.0.2.255" ));
118
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "GATEWAY", "10.0.2.2" ));
119
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "GATEWAY", "10.0.2.2" ));
119
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "DNS1", "10.0.2.2" ));
120
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "DNS1", "10.0.2.2" ));
120
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "DNS2", "10.0.2.2" ));
121
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "DNS2", "10.0.2.2" ));
121
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "ARP", "arp" ));
122
        ERROR_PROPAGATE( add_configuration( & netif->configuration, "ARP", "arp" ));