Changeset 984a9ba in mainline for uspace/lib/drv/generic/remote_battery_dev.c
- Timestamp:
- 2018-07-05T09:34:09Z (7 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 63d46341
- Parents:
- 76f566d
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/drv/generic/remote_battery_dev.c
r76f566d r984a9ba 90 90 } 91 91 92 static void remote_battery_status_get(ddf_fun_t *, void *, cap_call_handle_t, 93 ipc_call_t *); 94 static void remote_battery_charge_level_get(ddf_fun_t *, void *, cap_call_handle_t, 95 ipc_call_t *); 92 static void remote_battery_status_get(ddf_fun_t *, void *, ipc_call_t *); 93 static void remote_battery_charge_level_get(ddf_fun_t *, void *, ipc_call_t *); 96 94 97 95 /** Remote battery interface operations */ … … 114 112 /** Process the status_get() request from the remote client 115 113 * 116 * @param fun The function from which the battery status is read 117 * @param ops The local ops structure 114 * @param fun The function from which the battery status is read 115 * @param ops The local ops structure 116 * 118 117 */ 119 static void 120 remote_battery_status_get(ddf_fun_t *fun, void *ops, cap_call_handle_t chandle, 118 static void remote_battery_status_get(ddf_fun_t *fun, void *ops, 121 119 ipc_call_t *call) 122 120 { … … 124 122 125 123 if (bops->battery_status_get == NULL) { 126 async_answer_0(c handle, ENOTSUP);124 async_answer_0(call, ENOTSUP); 127 125 return; 128 126 } … … 132 130 133 131 if (rc != EOK) 134 async_answer_0(c handle, rc);132 async_answer_0(call, rc); 135 133 else 136 async_answer_1(c handle, rc, batt_status);134 async_answer_1(call, rc, batt_status); 137 135 } 138 136 139 137 /** Process the battery_charge_level_get() request from the remote client 140 138 * 141 * @param fun 142 * @param ops 139 * @param fun The function from which the battery charge level is read 140 * @param ops The local ops structure 143 141 * 144 142 */ 145 static void 146 remote_battery_charge_level_get(ddf_fun_t *fun, void *ops, cap_call_handle_t chandle, 143 static void remote_battery_charge_level_get(ddf_fun_t *fun, void *ops, 147 144 ipc_call_t *call) 148 145 { … … 150 147 151 148 if (bops->battery_charge_level_get == NULL) { 152 async_answer_0(c handle, ENOTSUP);149 async_answer_0(call, ENOTSUP); 153 150 return; 154 151 } … … 158 155 159 156 if (rc != EOK) 160 async_answer_0(c handle, rc);157 async_answer_0(call, rc); 161 158 else 162 async_answer_1(c handle, rc, battery_level);159 async_answer_1(call, rc, battery_level); 163 160 } 164
Note:
See TracChangeset
for help on using the changeset viewer.