Changes in uspace/lib/net/netif/netif_remote.c [42a9f27:774e6d1a] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/net/netif/netif_remote.c
r42a9f27 r774e6d1a 27 27 */ 28 28 29 /** @addtogroup libnet 29 /** @addtogroup libnet 30 30 * @{ 31 31 */ … … 49 49 /** Return the device local hardware address. 50 50 * 51 * @param[in] netif_phone The network interface phone. 52 * @param[in] device_id The device identifier. 53 * @param[out] address The device local hardware address. 54 * @param[out] data The address data. 55 * @return EOK on success. 56 * @return EBADMEM if the address parameter is NULL. 57 * @return ENOENT if there no such device. 58 * @return Other error codes as defined for the 59 * netif_get_addr_message() function. 51 * @param[in] netif_phone Network interface phone. 52 * @param[in] device_id Device identifier. 53 * @param[out] address Device local hardware address. 54 * @param[out] data Address data. 55 * 56 * @return EOK on success. 57 * @return EBADMEM if the address parameter is NULL. 58 * @return ENOENT if there no such device. 59 * @return Other error codes as defined for the 60 * netif_get_addr_message() function. 61 * 60 62 */ 61 int netif_get_addr_req _remote(int netif_phone, device_id_t device_id,62 measured_string_ ref *address, char**data)63 int netif_get_addr_req(int netif_phone, device_id_t device_id, 64 measured_string_t **address, uint8_t **data) 63 65 { 64 66 return generic_get_addr_req(netif_phone, NET_NETIF_GET_ADDR, device_id, … … 68 70 /** Probe the existence of the device. 69 71 * 70 * @param[in] netif_phone The network interface phone. 71 * @param[in] device_id The device identifier. 72 * @param[in] irq The device interrupt number. 73 * @param[in] io The device input/output address. 74 * @return EOK on success. 75 * @return Other error codes as defined for the 76 * netif_probe_message(). 72 * @param[in] netif_phone Network interface phone. 73 * @param[in] device_id Device identifier. 74 * @param[in] irq Device interrupt number. 75 * @param[in] io Device input/output address. 76 * 77 * @return EOK on success. 78 * @return Other error codes as defined for the 79 * netif_probe_message(). 80 * 77 81 */ 78 int 79 netif_probe_req_remote(int netif_phone, device_id_t device_id, int irq, int io) 82 int netif_probe_req(int netif_phone, device_id_t device_id, int irq, void *io) 80 83 { 81 return async_req_3_0(netif_phone, NET_NETIF_PROBE, device_id, irq, io); 84 return async_req_3_0(netif_phone, NET_NETIF_PROBE, device_id, irq, 85 (sysarg_t) io); 82 86 } 83 87 84 88 /** Send the packet queue. 85 89 * 86 * @param[in] netif_phone The network interface phone. 87 * @param[in] device_id The device identifier. 88 * @param[in] packet The packet queue. 89 * @param[in] sender The sending module service. 90 * @return EOK on success. 91 * @return Other error codes as defined for the generic_send_msg() 92 * function. 90 * @param[in] netif_phone Network interface phone. 91 * @param[in] device_id Device identifier. 92 * @param[in] packet Packet queue. 93 * @param[in] sender Sending module service. 94 * 95 * @return EOK on success. 96 * @return Other error codes as defined for the generic_send_msg() 97 * function. 98 * 93 99 */ 94 int 95 netif_send_msg_remote(int netif_phone, device_id_t device_id, packet_t packet, 100 int netif_send_msg(int netif_phone, device_id_t device_id, packet_t *packet, 96 101 services_t sender) 97 102 { … … 102 107 /** Start the device. 103 108 * 104 * @param[in] netif_phone The network interface phone. 105 * @param[in] device_id The device identifier. 106 * @return EOK on success. 107 * @return Other error codes as defined for the find_device() 108 * function. 109 * @return Other error codes as defined for the 110 * netif_start_message() function. 109 * @param[in] netif_phone Network interface phone. 110 * @param[in] device_id Device identifier. 111 * 112 * @return EOK on success. 113 * @return Other error codes as defined for the find_device() 114 * function. 115 * @return Other error codes as defined for the 116 * netif_start_message() function. 117 * 111 118 */ 112 int netif_start_req _remote(int netif_phone, device_id_t device_id)119 int netif_start_req(int netif_phone, device_id_t device_id) 113 120 { 114 121 return async_req_1_0(netif_phone, NET_NETIF_START, device_id); … … 117 124 /** Stop the device. 118 125 * 119 * @param[in] netif_phone The network interface phone. 120 * @param[in] device_id The device identifier. 121 * @return EOK on success. 122 * @return Other error codes as defined for the find_device() 123 * function. 124 * @return Other error codes as defined for the 125 * netif_stop_message() function. 126 * @param[in] netif_phone Network interface phone. 127 * @param[in] device_id Device identifier. 128 * 129 * @return EOK on success. 130 * @return Other error codes as defined for the find_device() 131 * function. 132 * @return Other error codes as defined for the 133 * netif_stop_message() function. 134 * 126 135 */ 127 int netif_stop_req _remote(int netif_phone, device_id_t device_id)136 int netif_stop_req(int netif_phone, device_id_t device_id) 128 137 { 129 138 return async_req_1_0(netif_phone, NET_NETIF_STOP, device_id); … … 132 141 /** Return the device usage statistics. 133 142 * 134 * @param[in] netif_phone The network interface phone. 135 * @param[in] device_id The device identifier. 136 * @param[out] stats The device usage statistics. 143 * @param[in] netif_phone Network interface phone. 144 * @param[in] device_id Device identifier. 145 * @param[out] stats Device usage statistics. 146 * 137 147 * @return EOK on success. 148 * 138 149 */ 139 int netif_stats_req _remote(int netif_phone, device_id_t device_id,140 device_stats_ refstats)150 int netif_stats_req(int netif_phone, device_id_t device_id, 151 device_stats_t *stats) 141 152 { 142 153 if (!stats) … … 144 155 145 156 aid_t message_id = async_send_1(netif_phone, NET_NETIF_STATS, 146 ( ipcarg_t) device_id, NULL);157 (sysarg_t) device_id, NULL); 147 158 async_data_read_start(netif_phone, stats, sizeof(*stats)); 148 159 149 ipcarg_t result;160 sysarg_t result; 150 161 async_wait_for(message_id, &result); 151 162 … … 153 164 } 154 165 155 /** Create bidirectional connection with the network interface module and 156 * registers the message receiver. 166 /** Create bidirectional connection with the network interface module 167 * 168 * Create bidirectional connection with the network interface module and 169 * register the message receiver. 157 170 * 158 171 * @param[in] service The network interface module service. … … 161 174 * @param[in] receiver The message receiver. 162 175 * 163 * @return The phone of the needed service. 164 * @return EOK on success. 165 * @return Other error codes as defined for the bind_service() 166 * function. 176 * @return The phone of the needed service. 177 * @return EOK on success. 178 * @return Other error codes as defined for the bind_service() 179 * function. 180 * 167 181 */ 168 int 169 netif_bind_service_remote(services_t service, device_id_t device_id, 182 int netif_bind_service(services_t service, device_id_t device_id, 170 183 services_t me, async_client_conn_t receiver) 171 184 {
Note:
See TracChangeset
for help on using the changeset viewer.