diff --git a/Kbuild b/Kbuild index 53a58d448a..21ed2e4258 100644 --- a/Kbuild +++ b/Kbuild @@ -2586,6 +2586,7 @@ DP_COMP_INC := -I$(WLAN_ROOT)/components/dp/core/inc \ WLAN_DP_COMP_OBJS := $(DP_COMP_CORE_DIR)/wlan_dp_main.o \ $(DP_COMP_UCFG_DIR)/wlan_dp_ucfg_api.o \ + $(DP_COMP_UCFG_DIR)/wlan_dp_api.o \ $(DP_COMP_OS_IF_DIR)/os_if_dp.o \ $(DP_COMP_OS_IF_DIR)/os_if_dp_txrx.o \ $(DP_COMP_CORE_DIR)/wlan_dp_bus_bandwidth.o \ diff --git a/components/dp/core/inc/wlan_dp_main.h b/components/dp/core/inc/wlan_dp_main.h index 379da4a539..8af5de1c7e 100644 --- a/components/dp/core/inc/wlan_dp_main.h +++ b/components/dp/core/inc/wlan_dp_main.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved. + * Copyright (c) 2022-2023 Qualcomm Innovation Center, Inc. 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 @@ -706,4 +706,23 @@ QDF_STATUS dp_config_direct_link(struct wlan_dp_intf *dp_intf, return QDF_STATUS_SUCCESS; } #endif +#ifdef WLAN_FEATURE_11BE +/** + * __wlan_dp_update_peer_map_unmap_version() - update peer map unmap version + * @version: Peer map unmap version pointer to be updated + * + * Return: None + */ +static inline void +__wlan_dp_update_peer_map_unmap_version(uint8_t *version) +{ + /* 0x32 -> host supports HTT peer map v3 format and peer unmap v2 format. */ + *version = 0x32; +} +#else +static inline void +__wlan_dp_update_peer_map_unmap_version(uint8_t *version) +{ +} +#endif #endif diff --git a/components/dp/dispatcher/inc/wlan_dp_api.h b/components/dp/dispatcher/inc/wlan_dp_api.h new file mode 100644 index 0000000000..cd0f6c5cdf --- /dev/null +++ b/components/dp/dispatcher/inc/wlan_dp_api.h @@ -0,0 +1,31 @@ +/* + * Copyright (c) 2023, Qualcomm Innovation Center, Inc. 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 above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES + * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR + * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES + * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN + * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF + * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + */ +/** + * DOC: wlan_dp_api.h + * + */ + +#if !defined(_WLAN_DP_API_H_) +#define _WLAN_DP_API_H_ + +/** + * wlan_dp_update_peer_map_unmap_version() - update peer map unmap version + * @version: Peer map unmap version pointer to be updated + * + * Return: None + */ +void wlan_dp_update_peer_map_unmap_version(uint8_t *version); +#endif diff --git a/components/dp/dispatcher/src/wlan_dp_api.c b/components/dp/dispatcher/src/wlan_dp_api.c new file mode 100644 index 0000000000..47da3fe4a8 --- /dev/null +++ b/components/dp/dispatcher/src/wlan_dp_api.c @@ -0,0 +1,27 @@ +/* + * Copyright (c) 2023, Qualcomm Innovation Center, Inc. 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 above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES + * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR + * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES + * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN + * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF + * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + */ +/** + * DOC: wlan_dp_api.c + * + */ + +#include "wlan_dp_main.h" +#include "wlan_dp_api.h" + +void wlan_dp_update_peer_map_unmap_version(uint8_t *version) +{ + __wlan_dp_update_peer_map_unmap_version(version); +} diff --git a/core/wma/src/wma_main.c b/core/wma/src/wma_main.c index 5461e09371..24fa4c7834 100644 --- a/core/wma/src/wma_main.c +++ b/core/wma/src/wma_main.c @@ -121,6 +121,7 @@ #include "wlan_tdls_api.h" #include "wlan_twt_cfg_ext_api.h" #include "wlan_mlo_mgr_sta.h" +#include "wlan_dp_api.h" #define WMA_LOG_COMPLETION_TIMER 500 /* 500 msecs */ #define WMI_TLV_HEADROOM 128 @@ -7257,6 +7258,8 @@ int wma_rx_service_ready_ext_event(void *handle, uint8_t *event, target_psoc_set_num_radios(tgt_hdl, 1); + wlan_dp_update_peer_map_unmap_version(&wlan_res_cfg->peer_map_unmap_version); + if (wmi_service_enabled(wmi_handle, wmi_service_new_htt_msg_format)) { cdp_cfg_set_new_htt_msg_format(soc, 1);