Changes in uspace/lib/net/generic/net_remote.c [6b82009:e882e3a] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/net/generic/net_remote.c
r6b82009 re882e3a 38 38 #include <ipc/services.h> 39 39 #include <ipc/net_net.h> 40 41 40 #include <malloc.h> 42 41 #include <async.h> 43 42 #include <generic.h> 44 43 #include <net/modules.h> … … 98 97 size_t count, uint8_t **data) 99 98 { 100 return generic_translate_req(sess, NET_NET_GET_ DEVICE_CONF, 0, 0,99 return generic_translate_req(sess, NET_NET_GET_CONF, 0, 0, 101 100 *configuration, count, configuration, data); 102 101 } … … 124 123 * 125 124 */ 126 int net_get_device_conf_req(async_sess_t *sess, device_id_t device_id,125 int net_get_device_conf_req(async_sess_t *sess, nic_device_id_t device_id, 127 126 measured_string_t **configuration, size_t count, uint8_t **data) 128 127 { … … 131 130 } 132 131 132 int net_get_devices_req(async_sess_t *sess, measured_string_t **devices, 133 size_t *count, uint8_t **data) 134 { 135 if ((!devices) || (!count)) 136 return EBADMEM; 137 138 async_exch_t *exch = async_exchange_begin(sess); 139 140 int rc = async_req_0_1(exch, NET_NET_GET_DEVICES_COUNT, count); 141 if (rc != EOK) { 142 async_exchange_end(exch); 143 return rc; 144 } 145 146 if (*count == 0) { 147 async_exchange_end(exch); 148 *data = NULL; 149 return EOK; 150 } 151 152 aid_t message_id = async_send_0(exch, NET_NET_GET_DEVICES, NULL); 153 rc = measured_strings_return(exch, devices, data, *count); 154 155 async_exchange_end(exch); 156 157 sysarg_t result; 158 async_wait_for(message_id, &result); 159 160 if ((rc == EOK) && (result != EOK)) { 161 free(*devices); 162 free(*data); 163 } 164 165 return (int) result; 166 } 167 133 168 /** @} 134 169 */
Note:
See TracChangeset
for help on using the changeset viewer.