Changeset 7bdcc45 in mainline for uspace/srv/net
- Timestamp:
- 2010-12-16T16:38:49Z (15 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 7837101
- Parents:
- 8e58f94 (diff), eb221e5 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)links above to see all the changes relative to each parent. - Location:
- uspace/srv/net
- Files:
-
- 16 edited
-
il/arp/arp.c (modified) (4 diffs)
-
il/arp/arp_module.c (modified) (1 diff)
-
il/ip/ip.c (modified) (5 diffs)
-
il/ip/ip_module.c (modified) (1 diff)
-
net/net.c (modified) (3 diffs)
-
netif/lo/lo.c (modified) (2 diffs)
-
nil/eth/eth.c (modified) (6 diffs)
-
nil/eth/eth_module.c (modified) (1 diff)
-
nil/nildummy/nildummy.c (modified) (6 diffs)
-
nil/nildummy/nildummy_module.c (modified) (1 diff)
-
tl/icmp/icmp.c (modified) (4 diffs)
-
tl/icmp/icmp_module.c (modified) (1 diff)
-
tl/tcp/tcp.c (modified) (5 diffs)
-
tl/tcp/tcp_module.c (modified) (1 diff)
-
tl/udp/udp.c (modified) (4 diffs)
-
tl/udp/udp_module.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/net/il/arp/arp.c
r8e58f94 r7bdcc45 320 320 /* Bind the new one */ 321 321 device->phone = nil_bind_service(device->service, 322 ( ipcarg_t) device->device_id, SERVICE_ARP,322 (sysarg_t) device->device_id, SERVICE_ARP, 323 323 arp_globals.client_connection); 324 324 if (device->phone < 0) { … … 421 421 device->packet_dimension.content = mtu; 422 422 fibril_mutex_unlock(&arp_globals.lock); 423 printf("arp - device %d changed mtu to % d\n\n", device_id, mtu);423 printf("arp - device %d changed mtu to %zu\n\n", device_id, mtu); 424 424 return EOK; 425 425 } … … 695 695 696 696 *answer_count = 0; 697 switch (IPC_GET_ METHOD(*call)) {697 switch (IPC_GET_IMETHOD(*call)) { 698 698 case IPC_M_PHONE_HUNGUP: 699 699 return EOK; … … 815 815 * result. 816 816 */ 817 if ((IPC_GET_ METHOD(call) == IPC_M_PHONE_HUNGUP) ||817 if ((IPC_GET_IMETHOD(call) == IPC_M_PHONE_HUNGUP) || 818 818 (res == EHANGUP)) 819 819 return; -
uspace/srv/net/il/arp/arp_module.c
r8e58f94 r7bdcc45 65 65 int il_module_start_standalone(async_client_conn_t client_connection) 66 66 { 67 ipcarg_t phonehash;67 sysarg_t phonehash; 68 68 int rc; 69 69 -
uspace/srv/net/il/ip/ip.c
r8e58f94 r7bdcc45 430 430 // binds the netif service which also initializes the device 431 431 ip_netif->phone = nil_bind_service(ip_netif->service, 432 ( ipcarg_t) ip_netif->device_id, SERVICE_IP,432 (sysarg_t) ip_netif->device_id, SERVICE_IP, 433 433 ip_globals.client_connection); 434 434 if (ip_netif->phone < 0) { … … 461 461 462 462 if (ip_netif->packet_dimension.content < IP_MIN_CONTENT) { 463 printf("Maximum transmission unit % dbytes is too small, at "463 printf("Maximum transmission unit %zu bytes is too small, at " 464 464 "least %d bytes are needed\n", 465 465 ip_netif->packet_dimension.content, IP_MIN_CONTENT); … … 502 502 fibril_rwlock_write_unlock(&ip_globals.netifs_lock); 503 503 504 printf("%s: Device %d changed MTU to % d\n", NAME, device_id, mtu);504 printf("%s: Device %d changed MTU to %zu\n", NAME, device_id, mtu); 505 505 506 506 return EOK; … … 1902 1902 1903 1903 *answer_count = 0; 1904 switch (IPC_GET_ METHOD(*call)) {1904 switch (IPC_GET_IMETHOD(*call)) { 1905 1905 case IPC_M_PHONE_HUNGUP: 1906 1906 return EOK; … … 2025 2025 * result. 2026 2026 */ 2027 if ((IPC_GET_ METHOD(call) == IPC_M_PHONE_HUNGUP) ||2027 if ((IPC_GET_IMETHOD(call) == IPC_M_PHONE_HUNGUP) || 2028 2028 (res == EHANGUP)) { 2029 2029 return; -
uspace/srv/net/il/ip/ip_module.c
r8e58f94 r7bdcc45 66 66 int il_module_start_standalone(async_client_conn_t client_connection) 67 67 { 68 ipcarg_t phonehash;68 sysarg_t phonehash; 69 69 int rc; 70 70 -
uspace/srv/net/net/net.c
r8e58f94 r7bdcc45 322 322 static int net_module_start(async_client_conn_t client_connection) 323 323 { 324 ipcarg_t phonehash;324 sysarg_t phonehash; 325 325 int rc; 326 326 … … 632 632 633 633 *answer_count = 0; 634 switch (IPC_GET_ METHOD(*call)) {634 switch (IPC_GET_IMETHOD(*call)) { 635 635 case IPC_M_PHONE_HUNGUP: 636 636 return EOK; … … 697 697 698 698 /* End if told to either by the message or the processing result */ 699 if ((IPC_GET_ METHOD(call) == IPC_M_PHONE_HUNGUP) || (res == EHANGUP))699 if ((IPC_GET_IMETHOD(call) == IPC_M_PHONE_HUNGUP) || (res == EHANGUP)) 700 700 return; 701 701 -
uspace/srv/net/netif/lo/lo.c
r8e58f94 r7bdcc45 164 164 int netif_initialize(void) 165 165 { 166 ipcarg_t phonehash;166 sysarg_t phonehash; 167 167 168 168 return REGISTER_ME(SERVICE_LO, &phonehash); … … 262 262 * result. 263 263 */ 264 if ((IPC_GET_ METHOD(call) == IPC_M_PHONE_HUNGUP) ||264 if ((IPC_GET_IMETHOD(call) == IPC_M_PHONE_HUNGUP) || 265 265 (res == EHANGUP)) 266 266 return; -
uspace/srv/net/nil/eth/eth.c
r8e58f94 r7bdcc45 238 238 239 239 while (true) { 240 switch (IPC_GET_ METHOD(*icall)) {240 switch (IPC_GET_IMETHOD(*icall)) { 241 241 case NET_NIL_DEVICE_STATE: 242 242 nil_device_state_msg_local(0, IPC_GET_DEVICE(icall), … … 251 251 IPC_GET_DEVICE(icall), packet, 0); 252 252 } 253 ipc_answer_0(iid, ( ipcarg_t) rc);253 ipc_answer_0(iid, (sysarg_t) rc); 254 254 break; 255 255 default: 256 ipc_answer_0(iid, ( ipcarg_t) ENOTSUP);256 ipc_answer_0(iid, (sysarg_t) ENOTSUP); 257 257 } 258 258 … … 315 315 device->mtu = ETH_MAX_TAGGED_CONTENT(device->flags); 316 316 317 printf("Device %d already exists:\tMTU\t= % d\n",317 printf("Device %d already exists:\tMTU\t= %zu\n", 318 318 device->device_id, device->mtu); 319 319 fibril_rwlock_write_unlock(ð_globals.devices_lock); … … 407 407 } 408 408 409 printf("%s: Device registered (id: %d, service: %d: mtu: % d, "409 printf("%s: Device registered (id: %d, service: %d: mtu: %zu, " 410 410 "mac: %x:%x:%x:%x:%x:%x, flags: 0x%x)\n", 411 411 NAME, device->device_id, device->service, device->mtu, … … 849 849 850 850 *answer_count = 0; 851 switch (IPC_GET_ METHOD(*call)) {851 switch (IPC_GET_IMETHOD(*call)) { 852 852 case IPC_M_PHONE_HUNGUP: 853 853 return EOK; … … 926 926 * result. 927 927 */ 928 if ((IPC_GET_ METHOD(call) == IPC_M_PHONE_HUNGUP) ||928 if ((IPC_GET_IMETHOD(call) == IPC_M_PHONE_HUNGUP) || 929 929 (res == EHANGUP)) 930 930 return; -
uspace/srv/net/nil/eth/eth_module.c
r8e58f94 r7bdcc45 52 52 int nil_module_start_standalone(async_client_conn_t client_connection) 53 53 { 54 ipcarg_t phonehash;54 sysarg_t phonehash; 55 55 int rc; 56 56 -
uspace/srv/net/nil/nildummy/nildummy.c
r8e58f94 r7bdcc45 110 110 111 111 while (true) { 112 switch (IPC_GET_ METHOD(*icall)) {112 switch (IPC_GET_IMETHOD(*icall)) { 113 113 case NET_NIL_DEVICE_STATE: 114 114 rc = nil_device_state_msg_local(0, 115 115 IPC_GET_DEVICE(icall), IPC_GET_STATE(icall)); 116 ipc_answer_0(iid, ( ipcarg_t) rc);116 ipc_answer_0(iid, (sysarg_t) rc); 117 117 break; 118 118 … … 124 124 IPC_GET_DEVICE(icall), packet, 0); 125 125 } 126 ipc_answer_0(iid, ( ipcarg_t) rc);126 ipc_answer_0(iid, (sysarg_t) rc); 127 127 break; 128 128 129 129 default: 130 ipc_answer_0(iid, ( ipcarg_t) ENOTSUP);130 ipc_answer_0(iid, (sysarg_t) ENOTSUP); 131 131 } 132 132 … … 175 175 device->mtu = NET_DEFAULT_MTU; 176 176 177 printf("Device %d already exists:\tMTU\t= % d\n",177 printf("Device %d already exists:\tMTU\t= %zu\n", 178 178 device->device_id, device->mtu); 179 179 fibril_rwlock_write_unlock(&nildummy_globals.devices_lock); … … 232 232 } 233 233 234 printf("%s: Device registered (id: %d, service: %d, mtu: % d)\n",234 printf("%s: Device registered (id: %d, service: %d, mtu: %zu)\n", 235 235 NAME, device->device_id, device->service, device->mtu); 236 236 fibril_rwlock_write_unlock(&nildummy_globals.devices_lock); … … 386 386 387 387 *answer_count = 0; 388 switch (IPC_GET_ METHOD(*call)) {388 switch (IPC_GET_IMETHOD(*call)) { 389 389 case IPC_M_PHONE_HUNGUP: 390 390 return EOK; … … 466 466 * result. 467 467 */ 468 if ((IPC_GET_ METHOD(call) == IPC_M_PHONE_HUNGUP) ||468 if ((IPC_GET_IMETHOD(call) == IPC_M_PHONE_HUNGUP) || 469 469 (res == EHANGUP)) 470 470 return; -
uspace/srv/net/nil/nildummy/nildummy_module.c
r8e58f94 r7bdcc45 52 52 int nil_module_start_standalone(async_client_conn_t client_connection) 53 53 { 54 ipcarg_t phonehash;54 sysarg_t phonehash; 55 55 int rc; 56 56 -
uspace/srv/net/tl/icmp/icmp.c
r8e58f94 r7bdcc45 693 693 int rc; 694 694 695 switch (IPC_GET_ METHOD(*call)) {695 switch (IPC_GET_IMETHOD(*call)) { 696 696 case NET_ICMP_DEST_UNREACH: 697 697 rc = packet_translate_remote(icmp_globals.net_phone, &packet, … … 824 824 825 825 /* Process the call */ 826 switch (IPC_GET_ METHOD(call)) {826 switch (IPC_GET_IMETHOD(call)) { 827 827 case IPC_M_PHONE_HUNGUP: 828 828 keep_on_going = false; … … 900 900 901 901 *answer_count = 0; 902 switch (IPC_GET_ METHOD(*call)) {902 switch (IPC_GET_IMETHOD(*call)) { 903 903 case NET_TL_RECEIVED: 904 904 rc = packet_translate_remote(icmp_globals.net_phone, &packet, … … 953 953 * result. 954 954 */ 955 if ((IPC_GET_ METHOD(call) == IPC_M_PHONE_HUNGUP) ||955 if ((IPC_GET_IMETHOD(call) == IPC_M_PHONE_HUNGUP) || 956 956 (res == EHANGUP)) 957 957 return; -
uspace/srv/net/tl/icmp/icmp_module.c
r8e58f94 r7bdcc45 58 58 int tl_module_start_standalone(async_client_conn_t client_connection) 59 59 { 60 ipcarg_t phonehash;60 sysarg_t phonehash; 61 61 int rc; 62 62 -
uspace/srv/net/tl/tcp/tcp.c
r8e58f94 r7bdcc45 829 829 /* Notify the destination socket */ 830 830 async_msg_5(socket->phone, NET_SOCKET_RECEIVED, 831 ( ipcarg_t) socket->socket_id,831 (sysarg_t) socket->socket_id, 832 832 ((packet_dimension->content < socket_data->data_fragment_size) ? 833 833 packet_dimension->content : socket_data->data_fragment_size), 0, 0, 834 ( ipcarg_t) fragments);834 (sysarg_t) fragments); 835 835 836 836 return EOK; … … 1090 1090 /* Notify the destination socket */ 1091 1091 async_msg_5(socket->phone, NET_SOCKET_ACCEPTED, 1092 ( ipcarg_t) listening_socket->socket_id,1092 (sysarg_t) listening_socket->socket_id, 1093 1093 socket_data->data_fragment_size, TCP_HEADER_SIZE, 1094 0, ( ipcarg_t) socket->socket_id);1094 0, (sysarg_t) socket->socket_id); 1095 1095 1096 1096 fibril_rwlock_write_unlock(socket_data->local_lock); … … 1240 1240 1241 1241 *answer_count = 0; 1242 switch (IPC_GET_ METHOD(*call)) {1242 switch (IPC_GET_IMETHOD(*call)) { 1243 1243 case NET_TL_RECEIVED: 1244 1244 // fibril_rwlock_read_lock(&tcp_globals.lock); … … 1323 1323 1324 1324 /* Process the call */ 1325 switch (IPC_GET_ METHOD(call)) {1325 switch (IPC_GET_IMETHOD(call)) { 1326 1326 case IPC_M_PHONE_HUNGUP: 1327 1327 keep_on_going = false; … … 2481 2481 * result. 2482 2482 */ 2483 if ((IPC_GET_ METHOD(call) == IPC_M_PHONE_HUNGUP) ||2483 if ((IPC_GET_IMETHOD(call) == IPC_M_PHONE_HUNGUP) || 2484 2484 (res == EHANGUP)) 2485 2485 return; -
uspace/srv/net/tl/tcp/tcp_module.c
r8e58f94 r7bdcc45 61 61 int tl_module_start_standalone(async_client_conn_t client_connection) 62 62 { 63 ipcarg_t phonehash;63 sysarg_t phonehash; 64 64 int rc; 65 65 -
uspace/srv/net/tl/udp/udp.c
r8e58f94 r7bdcc45 393 393 fibril_rwlock_write_unlock(&udp_globals.lock); 394 394 async_msg_5(socket->phone, NET_SOCKET_RECEIVED, 395 ( ipcarg_t) socket->socket_id, packet_dimension->content, 0, 0,396 ( ipcarg_t) fragments);395 (sysarg_t) socket->socket_id, packet_dimension->content, 0, 0, 396 (sysarg_t) fragments); 397 397 398 398 return EOK; … … 742 742 743 743 /* Process the call */ 744 switch (IPC_GET_ METHOD(call)) {744 switch (IPC_GET_IMETHOD(call)) { 745 745 case IPC_M_PHONE_HUNGUP: 746 746 keep_on_going = false; … … 866 866 *answer_count = 0; 867 867 868 switch (IPC_GET_ METHOD(*call)) {868 switch (IPC_GET_IMETHOD(*call)) { 869 869 case NET_TL_RECEIVED: 870 870 rc = packet_translate_remote(udp_globals.net_phone, &packet, … … 913 913 * result. 914 914 */ 915 if ((IPC_GET_ METHOD(call) == IPC_M_PHONE_HUNGUP) ||915 if ((IPC_GET_IMETHOD(call) == IPC_M_PHONE_HUNGUP) || 916 916 (res == EHANGUP)) 917 917 return; -
uspace/srv/net/tl/udp/udp_module.c
r8e58f94 r7bdcc45 59 59 int tl_module_start_standalone(async_client_conn_t client_connection) 60 60 { 61 ipcarg_t phonehash;61 sysarg_t phonehash; 62 62 int rc; 63 63
Note:
See TracChangeset
for help on using the changeset viewer.
