00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00038 #include <icmp_remote.h>
00039 #include <net/modules.h>
00040 #include <packet_client.h>
00041
00042 #include <async.h>
00043 #include <errno.h>
00044 #include <ipc/services.h>
00045 #include <ipc/icmp.h>
00046 #include <sys/types.h>
00047
00062 int
00063 icmp_destination_unreachable_msg(int icmp_phone, icmp_code_t code,
00064 icmp_param_t mtu, packet_t *packet)
00065 {
00066 async_msg_3(icmp_phone, NET_ICMP_DEST_UNREACH, (sysarg_t) code,
00067 (sysarg_t) packet_get_id(packet), (sysarg_t) mtu);
00068 return EOK;
00069 }
00070
00083 int icmp_source_quench_msg(int icmp_phone, packet_t *packet)
00084 {
00085 async_msg_2(icmp_phone, NET_ICMP_SOURCE_QUENCH, 0,
00086 (sysarg_t) packet_get_id(packet));
00087 return EOK;
00088 }
00089
00103 int icmp_time_exceeded_msg(int icmp_phone, icmp_code_t code, packet_t *packet)
00104 {
00105 async_msg_2(icmp_phone, NET_ICMP_TIME_EXCEEDED, (sysarg_t) code,
00106 (sysarg_t) packet_get_id(packet));
00107 return EOK;
00108 }
00109
00124 int icmp_parameter_problem_msg(int icmp_phone, icmp_code_t code,
00125 icmp_param_t pointer, packet_t *packet)
00126 {
00127 async_msg_3(icmp_phone, NET_ICMP_PARAMETERPROB, (sysarg_t) code,
00128 (sysarg_t) packet_get_id(packet), (sysarg_t) pointer);
00129 return EOK;
00130 }
00131