@@ -30,8 +30,8 @@ static_assert(RPC_MAXIMUM_PORT_COUNT == rpc::MAX_PORT_COUNT,
3030template <uint32_t lane_size>
3131rpc_status_t handle_server_impl (
3232 rpc::Server &server,
33- const std::unordered_map<rpc_opcode_t , rpc_opcode_callback_ty> &callbacks,
34- const std::unordered_map<rpc_opcode_t , void *> &callback_data,
33+ const std::unordered_map<uint16_t , rpc_opcode_callback_ty> &callbacks,
34+ const std::unordered_map<uint16_t , void *> &callback_data,
3535 uint32_t &index) {
3636 auto port = server.try_open (lane_size, index);
3737 if (!port)
@@ -239,8 +239,8 @@ struct Device {
239239 void *buffer;
240240 rpc::Server server;
241241 rpc::Client client;
242- std::unordered_map<rpc_opcode_t , rpc_opcode_callback_ty> callbacks;
243- std::unordered_map<rpc_opcode_t , void *> callback_data;
242+ std::unordered_map<uint16_t , rpc_opcode_callback_ty> callbacks;
243+ std::unordered_map<uint16_t , void *> callback_data;
244244};
245245
246246// A struct containing all the runtime state required to run the RPC server.
@@ -335,7 +335,7 @@ rpc_status_t rpc_handle_server(uint32_t device_id) {
335335 }
336336}
337337
338- rpc_status_t rpc_register_callback (uint32_t device_id, rpc_opcode_t opcode,
338+ rpc_status_t rpc_register_callback (uint32_t device_id, uint16_t opcode,
339339 rpc_opcode_callback_ty callback,
340340 void *data) {
341341 if (!state)
0 commit comments