diff --git a/Kbuild b/Kbuild index 35f5203e0fd6..59b3f40f3d12 100644 --- a/Kbuild +++ b/Kbuild @@ -1028,6 +1028,8 @@ TDLS_TARGET_IF_SRC := components/target_if/tdls/src TDLS_INC := -I$(WLAN_ROOT)/$(TDLS_DIR)/dispatcher/inc \ -I$(WLAN_ROOT)/$(TDLS_OS_IF_INC) \ -I$(WLAN_ROOT)/$(TDLS_TARGET_IF_INC) + +ifeq ($(CONFIG_CONVERGED_TDLS_ENABLE), y) TDLS_OBJS := $(TDLS_DIR)/core/src/wlan_tdls_main.o \ $(TDLS_DIR)/core/src/wlan_tdls_cmds_process.o \ $(TDLS_DIR)/core/src/wlan_tdls_peer.o \ @@ -1039,6 +1041,7 @@ TDLS_OBJS := $(TDLS_DIR)/core/src/wlan_tdls_main.o \ $(TDLS_DIR)/dispatcher/src/wlan_tdls_cfg.o \ $(TDLS_OS_IF_SRC)/wlan_cfg80211_tdls.o \ $(TDLS_TARGET_IF_SRC)/target_if_tdls.o +endif ########### BMI ########### BMI_DIR := core/bmi diff --git a/components/tdls/dispatcher/inc/wlan_tdls_ucfg_api.h b/components/tdls/dispatcher/inc/wlan_tdls_ucfg_api.h index 62e0a872bb5b..ba108d798fa3 100644 --- a/components/tdls/dispatcher/inc/wlan_tdls_ucfg_api.h +++ b/components/tdls/dispatcher/inc/wlan_tdls_ucfg_api.h @@ -32,6 +32,8 @@ #include #include +#ifdef CONVERGED_TDLS_ENABLE + /** * ucfg_tdls_init() - TDLS module initialization API * @@ -253,4 +255,63 @@ QDF_STATUS ucfg_set_tdls_offchan_mode(struct wlan_objmgr_vdev *vdev, */ QDF_STATUS ucfg_set_tdls_secoffchanneloffset(struct wlan_objmgr_vdev *vdev, int offchanoffset); + +#else + +static inline +QDF_STATUS ucfg_tdls_init(void) +{ + return QDF_STATUS_SUCCESS; +} + +static inline +QDF_STATUS ucfg_tdls_deinit(void) +{ + return QDF_STATUS_SUCCESS; +} + +static inline +QDF_STATUS ucfg_tdls_psoc_open(struct wlan_objmgr_psoc *psoc) +{ + return QDF_STATUS_SUCCESS; +} + +static inline +QDF_STATUS ucfg_tdls_psoc_close(struct wlan_objmgr_psoc *psoc) +{ + return QDF_STATUS_SUCCESS; +} + +static inline +QDF_STATUS ucfg_tdls_psoc_enable(struct wlan_objmgr_psoc *psoc) +{ + return QDF_STATUS_SUCCESS; +} + +static inline +QDF_STATUS ucfg_tdls_psoc_disable(struct wlan_objmgr_psoc *psoc) +{ + return QDF_STATUS_SUCCESS; +} + +static inline +void ucfg_tdls_update_rx_pkt_cnt(struct wlan_objmgr_vdev *vdev, + struct qdf_mac_addr *mac_addr, + struct qdf_mac_addr *dest_mac_addr) +{ +} + +static inline +void ucfg_tdls_update_tx_pkt_cnt(struct wlan_objmgr_vdev *vdev, + struct qdf_mac_addr *mac_addr) +{ +} + +static inline +QDF_STATUS ucfg_tdls_teardown_links(struct wlan_objmgr_vdev *vdev) +{ + return QDF_STATUS_SUCCESS; +} + +#endif /* CONVERGED_TDLS_ENABLE */ #endif diff --git a/core/hdd/src/wlan_hdd_main.c b/core/hdd/src/wlan_hdd_main.c index d773dd5429dd..4135ba6bbf96 100644 --- a/core/hdd/src/wlan_hdd_main.c +++ b/core/hdd/src/wlan_hdd_main.c @@ -1261,6 +1261,7 @@ void hdd_update_macaddr(struct hdd_context *hdd_ctx, } } +#ifdef CONVERGED_TDLS_ENABLE static int hdd_update_tdls_config(struct hdd_context *hdd_ctx) { struct wlan_objmgr_psoc *psoc = hdd_ctx->psoc; @@ -1303,6 +1304,12 @@ static int hdd_update_tdls_config(struct hdd_context *hdd_ctx) return 0; } +#else +static int hdd_update_tdls_config(struct hdd_context *hdd_ctx) +{ + return 0; +} +#endif #ifdef WLAN_FEATURE_ROAM_OFFLOAD static void hdd_update_roam_offload(struct hdd_context *hdd_ctx, diff --git a/os_if/tdls/inc/wlan_cfg80211_tdls.h b/os_if/tdls/inc/wlan_cfg80211_tdls.h index c4c6b1c6f8ba..0e12284c79c2 100644 --- a/os_if/tdls/inc/wlan_cfg80211_tdls.h +++ b/os_if/tdls/inc/wlan_cfg80211_tdls.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2017-2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2017-2019 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -270,7 +270,18 @@ void hdd_notify_sta_disconnect(uint8_t session_id, */ void hdd_notify_teardown_tdls_links(struct wlan_objmgr_vdev *vdev); -#else +#else /* CONVERGED_TDLS_ENABLE */ +static inline +QDF_STATUS wlan_cfg80211_tdls_priv_init(struct vdev_osif_priv *osif_priv) +{ + return QDF_STATUS_SUCCESS; +} + +static inline +void wlan_cfg80211_tdls_priv_deinit(struct vdev_osif_priv *osif_priv) +{ +} + static inline void hdd_notify_tdls_reset_adapter(struct wlan_objmgr_vdev *vdev) { @@ -305,5 +316,5 @@ void hdd_notify_teardown_tdls_links(struct wlan_objmgr_vdev *vdev) { } -#endif -#endif +#endif /* CONVERGED_TDLS_ENABLE */ +#endif /* _WLAN_CFG80211_TDLS_H_ */