| 1 | // SPDX-License-Identifier: GPL-3.0-or-later |
| 2 | // !! AUTOGENERATED FILE !! |
| 3 | // This file is generated by protoc-gen-mosrpc, do not edit. |
| 4 | // Any changes made to this file will be lost. |
| 5 | |
| 6 | #pragma once |
| 7 | |
| 8 | #if !defined(__MOS_KERNEL__) && defined(__cplusplus) && defined(__MOS_RPC_SERVER__) |
| 9 | #define __rpc_have_cpp_server__ |
| 10 | #endif |
| 11 | |
| 12 | #if !defined(__MOS_KERNEL__) && defined(__cplusplus) && defined(__MOS_RPC_CLIENT__) |
| 13 | #define __rpc_have_cpp_client__ |
| 14 | #endif |
| 15 | |
| 16 | // don't expose this to the kernel |
| 17 | #ifdef __rpc_have_cpp_server__ |
| 18 | #include <librpc/rpc_server++.hpp> |
| 19 | #endif |
| 20 | |
| 21 | #ifdef __rpc_have_cpp_client__ |
| 22 | #include <librpc/rpc_client.h> |
| 23 | #include <string> // HACK |
| 24 | #endif |
| 25 | |
| 26 | #include "proto/net-networkd.pb.h" |
| 27 | |
| 28 | // Service NetworkManager has a custom C name: network_manager |
| 29 | // network_manager service |
| 30 | #define NETWORK_MANAGER_SERVICE_X(ARGS, PB, xarg) \ |
| 31 | PB(xarg, 1, register_network_device, REGISTER_NETWORK_DEVICE, RegisterNetworkDeviceRequest, RegisterNetworkDeviceResponse) \ |
| 32 | /**/ |
| 33 | |
| 34 | // Service stubs and interfaces for C++ clients and servers |
| 35 | #ifdef __rpc_have_cpp_client__ |
| 36 | RPC_CLIENT_DEFINE_STUB_CLASS(NetworkManagerStub, NETWORK_MANAGER_SERVICE_X); |
| 37 | #endif |
| 38 | |
| 39 | #ifdef __rpc_have_cpp_server__ |
| 40 | RPC_DECL_SERVER_INTERFACE_CLASS(INetworkManagerService, NETWORK_MANAGER_SERVICE_X); |
| 41 | #endif |
| 42 | |
| 43 | #ifdef __MOS_RPC_SERVER__ |
| 44 | #define MOS_RPC_NETWORK_MANAGER_SERVER(name) RPC_DECLARE_SERVER(name, NETWORK_MANAGER_SERVICE_X) |
| 45 | #endif |
| 46 | |
| 47 | #ifdef __MOS_RPC_CLIENT__ |
| 48 | #define MOS_RPC_NETWORK_MANAGER_CLIENT(name) RPC_DECLARE_CLIENT(name, NETWORK_MANAGER_SERVICE_X) |
| 49 | #endif |
| 50 | |
| 51 | #undef __rpc_have_cpp_server__ |
| 52 | #undef __rpc_have_cpp_client__ |
| 53 | |