ipc: binder: Add the head files related to the actv binder

Signed-off-by: Yu Qingsong <qs_cosmos@163.com>
This commit is contained in:
yuqingsong (A) 2023-12-08 16:28:34 +08:00
parent 09be225858
commit 2ac9838458
4 changed files with 37 additions and 0 deletions

View File

@ -13,6 +13,7 @@
import("//build/ohos.gni") import("//build/ohos.gni")
import("//build/ohos_var.gni") import("//build/ohos_var.gni")
import("./config.gni")
SUBSYSTEM_DIR = "//foundation/communication/ipc" SUBSYSTEM_DIR = "//foundation/communication/ipc"
IPC_CORE_ROOT = "$SUBSYSTEM_DIR/ipc/native" IPC_CORE_ROOT = "$SUBSYSTEM_DIR/ipc/native"
@ -36,6 +37,9 @@ config("ipc_util_config") {
if (defined(build_public_version) && build_public_version) { if (defined(build_public_version) && build_public_version) {
cflags += [ "-DBUILD_PUBLIC_VERSION" ] cflags += [ "-DBUILD_PUBLIC_VERSION" ]
} }
if (ipc_feature_actv_binder_enabled) {
cflags += [ "-DCONFIG_ACTV_BINDER" ]
}
} }
group("ipc_components") { group("ipc_components") {

View File

@ -21,6 +21,7 @@
"mini" "mini"
], ],
"features": [ "features": [
"ipc_feature_actv_binder_enabled",
"ipc_feature_rpc_enabled" "ipc_feature_rpc_enabled"
], ],
"syscap":[ "syscap":[

View File

@ -13,4 +13,5 @@
declare_args() { declare_args() {
ipc_feature_rpc_enabled = false ipc_feature_rpc_enabled = false
ipc_feature_actv_binder_enabled = true
} }

View File

@ -0,0 +1,31 @@
/*
* Copyright (C) 2023 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef OHOS_IPC_ACTV_BINDER_H
#define OHOS_IPC_ACTV_BINDER_H
#include <sys/types.h>
#ifdef CONFIG_ACTV_BINDER
#define BINDER_SET_ACTVMGR _IOWR('b', 64, uint64_t)
#define ACTV_BINDER_HANDLE_BIT 1
#define ACTV_BINDER_WRITE_READ _IOWR('b', 97, struct binder_write_read)
#endif // CONFIG_ACTV_BINDER
#endif // OHOS_IPC_ACTV_BINDER_H