Changes in uspace/lib/c/include/ipc/icmp.h [753bca3:774e6d1a] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/c/include/ipc/icmp.h
r753bca3 r774e6d1a 82 82 /*@{*/ 83 83 84 /** Return sthe ICMP code message parameter.84 /** Return the ICMP code message parameter. 85 85 * 86 * @param[in] call The message call structure. 86 * @param[in] call Message call structure. 87 * 87 88 */ 88 #define ICMP_GET_CODE(call) \ 89 ({ \ 90 icmp_code_t code = (icmp_code_t) IPC_GET_ARG1(*call); \ 91 code; \ 92 }) 89 #define ICMP_GET_CODE(call) ((icmp_code_t) IPC_GET_ARG1(call)) 93 90 94 /** Return sthe ICMP link MTU message parameter.91 /** Return the ICMP link MTU message parameter. 95 92 * 96 * @param[in] call The message call structure. 93 * @param[in] call Message call structure. 94 * 97 95 */ 98 #define ICMP_GET_MTU(call) \ 99 ({ \ 100 icmp_param_t mtu = (icmp_param_t) IPC_GET_ARG3(*call); \ 101 mtu; \ 102 }) 96 #define ICMP_GET_MTU(call) ((icmp_param_t) IPC_GET_ARG3(call)) 103 97 104 /** Return sthe pointer message parameter.98 /** Return the pointer message parameter. 105 99 * 106 * @param[in] call The message call structure. 100 * @param[in] call Message call structure. 101 * 107 102 */ 108 #define ICMP_GET_POINTER(call) \ 109 ({ \ 110 icmp_param_t pointer = (icmp_param_t) IPC_GET_ARG3(*call); \ 111 pointer; \ 112 }) 103 #define ICMP_GET_POINTER(call) ((icmp_param_t) IPC_GET_ARG3(call)) 113 104 114 /** Return sthe size message parameter.105 /** Return the size message parameter. 115 106 * 116 * @param[in] call The message call structure. 107 * @param[in] call Message call structure. 108 * 117 109 */ 118 #define ICMP_GET_SIZE(call) \ 119 ({ \ 120 size_t size = (size_t) IPC_GET_ARG1(call); \ 121 size; \ 122 }) 110 #define ICMP_GET_SIZE(call) ((size_t) IPC_GET_ARG1(call)) 123 111 124 /** Return sthe timeout message parameter.112 /** Return the timeout message parameter. 125 113 * 126 * @param[in] call The message call structure. 114 * @param[in] call Message call structure. 115 * 127 116 */ 128 #define ICMP_GET_TIMEOUT(call) \ 129 ({ \ 130 suseconds_t timeout = (suseconds_t) IPC_GET_ARG2(call); \ 131 timeout; \ 132 }) 117 #define ICMP_GET_TIMEOUT(call) ((suseconds_t) IPC_GET_ARG2(call)) 133 118 134 /** Return sthe time to live message parameter.119 /** Return the time to live message parameter. 135 120 * 136 * @param[in] call The message call structure. 121 * @param[in] call Message call structure. 122 * 137 123 */ 138 #define ICMP_GET_TTL(call) \ 139 ({ \ 140 ip_ttl_t ttl = (ip_ttl_t) IPC_GET_ARG3(call); \ 141 ttl; \ 142 }) 124 #define ICMP_GET_TTL(call) ((ip_ttl_t) IPC_GET_ARG3(call)) 143 125 144 /** Return sthe type of service message parameter.126 /** Return the type of service message parameter. 145 127 * 146 * @param[in] call The message call structure. 128 * @param[in] call Message call structure. 129 * 147 130 */ 148 #define ICMP_GET_TOS(call) \ 149 ({ \ 150 ip_tos_t tos = (ip_tos_t) IPC_GET_ARG4(call); \ 151 tos; \ 152 }) 131 #define ICMP_GET_TOS(call) ((ip_tos_t) IPC_GET_ARG4(call)) 153 132 154 /** Return sthe dont fragment message parameter.133 /** Return the dont fragment message parameter. 155 134 * 156 * @param[in] call The message call structure.135 * @param[in] call Message call structure. 157 136 */ 158 #define ICMP_GET_DONT_FRAGMENT(call) \ 159 ({ \ 160 int dont_fragment = (int) IPC_GET_ARG5(call); \ 161 dont_fragment; \ 162 }) 137 #define ICMP_GET_DONT_FRAGMENT(call) ((int) IPC_GET_ARG5(call)) 163 138 164 139 /*@}*/
Note:
See TracChangeset
for help on using the changeset viewer.