Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 54e9c50c authored by Lincoln Tran's avatar Lincoln Tran Committed by Madan Koyyalamudi
Browse files

qcacld-3.0: Only send VHT TX_BF if FW supports it

Only send the VHT TX beamforming capability if firmware has set the
support bit. This helps ensure backward compatibility for older
products.

Change-Id: Ia5830c9f378e3f0ddc83c8019d5168a270ad6f69
CRs-fixed: 2933687
parent 54f1508f
Loading
Loading
Loading
Loading
+15 −1
Original line number Diff line number Diff line
/*
 * Copyright (c) 2017-2020 The Linux Foundation. All rights reserved.
 * Copyright (c) 2017-2021 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
@@ -207,6 +207,14 @@ bool wlan_nan_get_sap_conc_support(struct wlan_objmgr_psoc *psoc);
 * Return: Cleanup NAN state upon NAN disable
 */
QDF_STATUS nan_disable_cleanup(struct wlan_objmgr_psoc *psoc);

/**
 * wlan_nan_is_beamforming_supported- Get support for beamforing
 * @psoc: pointer to psoc object
 *
 * Return: True if beamforming is supported, false if not.
 */
bool wlan_nan_is_beamforming_supported(struct wlan_objmgr_psoc *psoc);
#else /* WLAN_FEATURE_NAN */
static inline QDF_STATUS nan_init(void)
{
@@ -252,5 +260,11 @@ QDF_STATUS nan_disable_cleanup(struct wlan_objmgr_psoc *psoc)
{
	return QDF_STATUS_E_FAILURE;
}

static inline
bool wlan_nan_is_beamforming_supported(struct wlan_objmgr_psoc *psoc)
{
	return false;
}
#endif /* WLAN_FEATURE_NAN */
#endif /* _WLAN_NAN_API_H_ */
+5 −0
Original line number Diff line number Diff line
@@ -1399,3 +1399,8 @@ bool wlan_nan_get_sap_conc_support(struct wlan_objmgr_psoc *psoc)
	return (psoc_nan_obj->nan_caps.nan_sap_supported &&
		ucfg_is_nan_conc_control_supported(psoc));
}

bool wlan_nan_is_beamforming_supported(struct wlan_objmgr_psoc *psoc)
{
	return ucfg_nan_is_beamforming_supported(psoc);
}
+4 −2
Original line number Diff line number Diff line
@@ -88,7 +88,7 @@
#include "wlan_coex_ucfg_api.h"
#include <wlan_cp_stats_mc_ucfg_api.h>
#include "wmi_unified_vdev_api.h"

#include "wlan_nan_api.h"
#ifdef DCS_INTERFERENCE_DETECTION
#include <wlan_dcs_ucfg_api.h>
#endif
@@ -2615,6 +2615,8 @@ QDF_STATUS wma_post_vdev_create_setup(struct wlan_objmgr_vdev *vdev)
	wma_set_vdev_mgmt_rate(wma_handle, vdev_id);
	if (IS_FEATURE_SUPPORTED_BY_FW(DOT11AX))
		wma_set_he_txbf_cfg(mac, vdev_id);

	if (wlan_nan_is_beamforming_supported(mac->psoc))
		wma_set_vht_txbf_cfg(mac, vdev_id);

	/* Initialize roaming offload state */