8#if !defined(__MOS_KERNEL__) && defined(__cplusplus) && defined(__MOS_RPC_SERVER__)
9#define __rpc_have_cpp_server__
12#if !defined(__MOS_KERNEL__) && defined(__cplusplus) && defined(__MOS_RPC_CLIENT__)
13#define __rpc_have_cpp_client__
17#ifdef __rpc_have_cpp_server__
21#ifdef __rpc_have_cpp_client__
29#define USERFS_SERVICE_X(ARGS, PB, xarg) \
30 PB(xarg, 1, mount, MOUNT, mosrpc_fs_mount_request, mosrpc_fs_mount_response) \
31 PB(xarg, 2, readdir, READDIR, mosrpc_fs_readdir_request, mosrpc_fs_readdir_response) \
32 PB(xarg, 3, lookup, LOOKUP, mosrpc_fs_lookup_request, mosrpc_fs_lookup_response) \
33 PB(xarg, 4, readlink, READLINK, mosrpc_fs_readlink_request, mosrpc_fs_readlink_response) \
34 PB(xarg, 5, get_page, GET_PAGE, mosrpc_fs_getpage_request, mosrpc_fs_getpage_response) \
35 PB(xarg, 6, put_page, PUT_PAGE, mosrpc_fs_putpage_request, mosrpc_fs_putpage_response) \
36 PB(xarg, 7, create_file, CREATE_FILE, mosrpc_fs_create_file_request, mosrpc_fs_create_file_response) \
37 PB(xarg, 8, sync_inode, SYNC_INODE, mosrpc_fs_sync_inode_request, mosrpc_fs_sync_inode_response) \
38 PB(xarg, 9, unlink, UNLINK, mosrpc_fs_unlink_request, mosrpc_fs_unlink_response) \
39 PB(xarg, 10, make_dir, MAKE_DIR, mosrpc_fs_make_dir_request, mosrpc_fs_make_dir_response) \
43#ifdef __rpc_have_cpp_client__
47#ifdef __rpc_have_cpp_server__
51#ifdef __MOS_RPC_SERVER__
52#define MOS_RPC_USERFS_SERVER(name) RPC_DECLARE_SERVER(name, USERFS_SERVICE_X)
55#ifdef __MOS_RPC_CLIENT__
56#define MOS_RPC_USERFS_CLIENT(name) RPC_DECLARE_CLIENT(name, USERFS_SERVICE_X)
59#undef __rpc_have_cpp_server__
60#undef __rpc_have_cpp_client__
#define USERFS_SERVICE_X(ARGS, PB, xarg)
#define RPC_DECL_SERVER_INTERFACE_CLASS(classname, X_MACRO)
#define RPC_CLIENT_DEFINE_STUB_CLASS(_class_name, X_MACRO)