From 25453b4128ebc2ddbb3bfe992ae16aaa329b32d9 Mon Sep 17 00:00:00 2001 From: fanxiaoyu Date: Mon, 6 Sep 2021 01:17:06 +0000 Subject: [PATCH] Description:add dsoftbus kernel driver module Feature or Bugfix:Feature Binary Source: No Signed-off-by: fanxiaoyu --- Kconfig | 1 + Makefile | 1 + model/misc/dsoftbus/Kconfig | 24 +++++++++++++++++++++++ model/misc/dsoftbus/Makefile | 37 ++++++++++++++++++++++++++++++++++++ 4 files changed, 63 insertions(+) create mode 100644 model/misc/dsoftbus/Kconfig create mode 100644 model/misc/dsoftbus/Makefile diff --git a/Kconfig b/Kconfig index 3f4581f..037b190 100644 --- a/Kconfig +++ b/Kconfig @@ -25,3 +25,4 @@ source "drivers/hdf/khdf/model/usb/host/Kconfig" source "drivers/hdf/khdf/model/usb/device/Kconfig" source "drivers/hdf/khdf/model/audio/Kconfig" source "drivers/hdf/khdf/model/misc/vibrator/Kconfig" +source "drivers/hdf/khdf/model/misc/dsoftbus/Kconfig" \ No newline at end of file diff --git a/Makefile b/Makefile index b91e439..33c8c23 100644 --- a/Makefile +++ b/Makefile @@ -50,3 +50,4 @@ obj-$(CONFIG_DRIVERS_HDF_STORAGE) += model/storage/ obj-$(CONFIG_DRIVERS_HDF_BT) += model/network/bluetooth/ obj-$(CONFIG_DRIVERS_HDF_VIBRATOR) += model/misc/vibrator/ obj-$(CONFIG_DRIVERS_HDF_AUDIO) += model/audio/ +obj-$(CONFIG_DRIVERS_HDF_DSOFTBUS) += model/misc/dsoftbus/ diff --git a/model/misc/dsoftbus/Kconfig b/model/misc/dsoftbus/Kconfig new file mode 100644 index 0000000..5c8e3ae --- /dev/null +++ b/model/misc/dsoftbus/Kconfig @@ -0,0 +1,24 @@ +# Copyright (c) 2021 Huawei Device Co., Ltd. +# +# This software is licensed under the terms of the GNU General Public +# License version 2, as published by the Free Software Foundation, and +# may be copied, distributed, and modified under those terms. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. + +config DRIVERS_HDF_DSOFTBUS + bool "Enable HDF dsoftbus driver" + default n + depends on DRIVERS_HDF + help + control HDF dsoftbus driver capability. + +config DSOFTBUS_WLAN_PARAM_MONITOR + bool "enable dsoftbus wlan parameter monitor" + default n + depends on DRIVERS_HDF_DSOFTBUS + help + control hdf dsoftbus wlan parameter monitor capability. \ No newline at end of file diff --git a/model/misc/dsoftbus/Makefile b/model/misc/dsoftbus/Makefile new file mode 100644 index 0000000..ff2567f --- /dev/null +++ b/model/misc/dsoftbus/Makefile @@ -0,0 +1,37 @@ +# +# Copyright (c) 2021 Huawei Device Co., Ltd. +# +# This software is licensed under the terms of the GNU General Public +# License version 2, as published by the Free Software Foundation, and +# may be copied, distributed, and modified under those terms. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# + +DSOFTBUS_ROOT_DIR = ../../../../../../framework/model/misc/dsoftbus + +obj-$(CONFIG_DRIVERS_HDF_DSOFTBUS) += \ + $(DSOFTBUS_ROOT_DIR)/src/hdf_dsoftbus_driver.o \ + $(DSOFTBUS_ROOT_DIR)/src/module_manager.o +ifeq ($(CONFIG_DSOFTBUS_WLAN_PARAM_MONITOR), y) +obj-$(CONFIG_DRIVERS_HDF_DSOFTBUS) += $(DSOFTBUS_ROOT_DIR)/src/wlan_param_monitor.o +ccflags-$(CONFIG_DRIVERS_HDF_DSOFTBUS) +=-DENABLE_WLAN_PARAM_MONITOR +endif + +ccflags-y += -Iinclude/../drivers/hdf/framework/model/misc/dsoftbus/include \ + -Iinclude/../drivers/hdf/framework/core/common/include/host \ + -Iinclude/../drivers/hdf/framework/include/core \ + -Iinclude/../drivers/hdf/framework/include/osal \ + -Iinclude/../drivers/hdf/framework/include/utils \ + -Iinclude/../drivers/hdf/framework/ability/sbuf/include \ + -Iinclude/../drivers/hdf/framework/include/platform \ + -Iinclude/../drivers/hdf/framework/include/config \ + -Iinclude/../drivers/hdf/framework/core/host/include \ + -Iinclude/../drivers/hdf/framework/core/shared/include \ + -Iinclude/../drivers/hdf/framework/utils/include \ + -Iinclude/../drivers/hdf/khdf/osal/include \ + -I$(PROJECT_ROOT)/third_party/bounds_checking_function/include