From f917638b7d79d42438275aea3ef4d27196d314a2 Mon Sep 17 00:00:00 2001 From: Jeff Johnson Date: Tue, 17 Jul 2018 19:15:58 -0700 Subject: [PATCH] qcacld-3.0: Save sar version in the HDD context SAR version information is now being populated in struct wma_tgt_cfg. Keep a copy of the information in the HDD context for local reference. Change-Id: I7bc943fc71b651baeb56e4966d97efca2cccbf4e CRs-Fixed: 2282071 --- core/hdd/inc/wlan_hdd_main.h | 2 ++ core/hdd/src/wlan_hdd_main.c | 7 +++++++ 2 files changed, 9 insertions(+) diff --git a/core/hdd/inc/wlan_hdd_main.h b/core/hdd/inc/wlan_hdd_main.h index 530c4d84db8b..92c4a6523c61 100644 --- a/core/hdd/inc/wlan_hdd_main.h +++ b/core/hdd/inc/wlan_hdd_main.h @@ -93,6 +93,7 @@ #include #include "wlan_hdd_nud_tracking.h" #include "wlan_hdd_twt.h" +#include "wma_sar_public_structs.h" /* * Preprocessor definitions and constants @@ -1980,6 +1981,7 @@ struct hdd_context { struct hdd_cache_channels *original_channels; qdf_mutex_t cache_channel_lock; #endif + enum sar_version sar_version; }; /** diff --git a/core/hdd/src/wlan_hdd_main.c b/core/hdd/src/wlan_hdd_main.c index e3bd5bb1b2c2..4de5d4815764 100644 --- a/core/hdd/src/wlan_hdd_main.c +++ b/core/hdd/src/wlan_hdd_main.c @@ -1877,6 +1877,12 @@ static void hdd_update_ra_rate_limit(struct hdd_context *hdd_ctx, } #endif +static void hdd_sar_target_config(struct hdd_context *hdd_ctx, + struct wma_tgt_cfg *cfg) +{ + hdd_ctx->sar_version = cfg->sar_version; +} + void hdd_update_tgt_cfg(hdd_handle_t hdd_handle, struct wma_tgt_cfg *cfg) { int ret; @@ -2008,6 +2014,7 @@ void hdd_update_tgt_cfg(hdd_handle_t hdd_handle, struct wma_tgt_cfg *cfg) hdd_ctx->max_intf_count = cfg->max_intf_count; } + hdd_sar_target_config(hdd_ctx, cfg); hdd_lpass_target_config(hdd_ctx, cfg); hdd_ctx->ap_arpns_support = cfg->ap_arpns_support;