From 5a6aec02775e5cb74a294cd2cab3335ecc4226bd Mon Sep 17 00:00:00 2001 From: Abhijit Pradhan Date: Wed, 20 Nov 2019 13:00:35 +0530 Subject: [PATCH] qcacmn: Control the size of the freq and chan_num (GUMAC-SCAN) Depending on the requirement, a bigger size or a smaller size for the frequency variable can be chosen. The advantages of each size are described below: Advantage of a bigger size: When two technologies (e.g. 802.11AX and 802.11AD) are controlled by the same driver software, the frequency range may be very large and a bigger size (e.g. 32bit integer) is more appropriate. Advantage of a smaller size: When the frequency range is not very large, a smaller size (e.g. 16bit integer) can be used. It saves a large amount of space especially when many large arrays containing elements of this type/size are defined in the driver. Also, change the size of the IEEE channel variables to unsigned 8-bit integer. Change-Id: I6349c0665bf0a7329627427913f9eebba2821043 CRs-Fixed: 2586177 --- umac/global_umac_dispatcher/lmac_if/inc/wlan_lmac_if_def.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/umac/global_umac_dispatcher/lmac_if/inc/wlan_lmac_if_def.h b/umac/global_umac_dispatcher/lmac_if/inc/wlan_lmac_if_def.h index 64c872498227..c1462e1a6c4c 100644 --- a/umac/global_umac_dispatcher/lmac_if/inc/wlan_lmac_if_def.h +++ b/umac/global_umac_dispatcher/lmac_if/inc/wlan_lmac_if_def.h @@ -1020,8 +1020,8 @@ struct wlan_lmac_if_reg_rx_ops { enum dfs_reg *dfs_reg); QDF_STATUS (*reg_ch_avoid_event_handler)(struct wlan_objmgr_psoc *psoc, struct ch_avoid_ind_type *ch_avoid_ind); - uint32_t (*reg_freq_to_chan)(struct wlan_objmgr_pdev *pdev, - uint32_t freq); + uint8_t (*reg_freq_to_chan)(struct wlan_objmgr_pdev *pdev, + qdf_freq_t freq); QDF_STATUS (*reg_set_chan_144)(struct wlan_objmgr_pdev *pdev, bool enable_ch_144); bool (*reg_get_chan_144)(struct wlan_objmgr_pdev *pdev);