Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions config/rdkb-wifi.ovsschema
Original file line number Diff line number Diff line change
Expand Up @@ -2219,6 +2219,15 @@
"min": 0,
"max": 1
}
},
"diagnostic_enable": {
"type": {
"key": {
"type": "boolean"
},
"min": 0,
"max": 1
}
}
},
"indexes": [
Expand Down
3 changes: 3 additions & 0 deletions lib/inc/schema_gen.h
Original file line number Diff line number Diff line change
Expand Up @@ -1741,6 +1741,7 @@
PJS_OVS_INT(lq_client_threshold) \
PJS_OVS_BOOL(lq_client_detail_enable) \
PJS_OVS_STRING(lq_client_whitelist, 256 + 1) \
PJS_OVS_BOOL(diagnostic_enable) \
)

#define PJS_GEN_TABLE \
Expand Down Expand Up @@ -3465,6 +3466,7 @@
COLUMN(lq_client_threshold) \
COLUMN(lq_client_detail_enable) \
COLUMN(lq_client_whitelist) \
COLUMN(diagnostic_enable) \

#define SCHEMA__AWLAN_Node__id "id"
#define SCHEMA__AWLAN_Node__model "model"
Expand Down Expand Up @@ -4777,3 +4779,4 @@
#define SCHEMA__Wifi_Wei_Rfc_Config__lq_client_threshold "lq_client_threshold"
#define SCHEMA__Wifi_Wei_Rfc_Config__lq_client_detail_enable "lq_client_detail_enable"
#define SCHEMA__Wifi_Wei_Rfc_Config__lq_client_whitelist "lq_client_whitelist"
#define SCHEMA__Wifi_Wei_Rfc_Config__diagnostic_enable "diagnostic_enable"
2 changes: 2 additions & 0 deletions source/core/wifi_ctrl_rbus_handlers.c
Original file line number Diff line number Diff line change
Expand Up @@ -2090,6 +2090,8 @@ static wei_param_entry_t g_wei_param_table[] = {
WEI_FIELD(WEI_LQ_CLIENT_THRESHOLD_DMPATH, FIELD_UINT, lq.client_threshold),
WEI_FIELD(WEI_LQ_CLIENT_DETAIL_ENABLE_DMPATH, FIELD_BOOL, lq.client_detail_enable),
WEI_FIELD(WEI_LQ_CLIENT_WHITELIST_DMPATH, FIELD_STRING, lq.client_whitelist),

WEI_FIELD(WEI_DIAGNOSTIC_ENABLE_DMPATH, FIELD_BOOL, wei_diagnostic_enable),
};
#define WEI_PARAM_TABLE_COUNT (sizeof(g_wei_param_table) / sizeof(g_wei_param_table[0]))

Expand Down
3 changes: 3 additions & 0 deletions source/core/wifi_ctrl_wei_rfc.h
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,8 @@ extern "C" {
//WEI endpoint for ignite
#define WEI_IGNITE_ENABLE_DMPATH "Device.X_RDKCENTRAL-COM_WEI.Ignite.Enable"

#define WEI_DIAGNOSTIC_ENABLE_DMPATH "Device.X_RDKCENTRAL-COM_WEI.Diagnostic.Enable"

/* ---- Staying-Connected (SC) TR-181 parameter paths (WiFi-DB owned) ---- */
#define WEI_SC_HOME_ENABLE_DMPATH "Device.X_RDKCENTRAL-COM_WEI.SC.Home.Enable"
#define WEI_SC_HOME_THRESHOLD_DMPATH "Device.X_RDKCENTRAL-COM_WEI.SC.Home.Threshold"
Expand Down Expand Up @@ -116,6 +118,7 @@ typedef struct {
wei_rfc_pillar_config_t sc;
wei_rfc_pillar_config_t gc;
wei_rfc_pillar_config_t lq;
bool wei_diagnostic_enable;
Comment thread
rshah-1 marked this conversation as resolved.
} wei_rfc_dml_parameters_t;

/* Field type tags for the WEI RFC parameter descriptor table (drives the
Expand Down
10 changes: 8 additions & 2 deletions source/db/wifi_db_apis.c
Original file line number Diff line number Diff line change
Expand Up @@ -349,6 +349,8 @@ static void wei_rfc_schema_to_dml(const struct schema_Wifi_Wei_Rfc_Config *cfg,
dml->lq.client_threshold = (uint32_t)cfg->lq_client_threshold;
dml->lq.client_detail_enable = cfg->lq_client_detail_enable;
snprintf(dml->lq.client_whitelist, sizeof(dml->lq.client_whitelist), "%s", cfg->lq_client_whitelist);

dml->wei_diagnostic_enable = cfg->diagnostic_enable;
}

static void wei_rfc_dml_to_schema(const wei_rfc_dml_parameters_t *dml, struct schema_Wifi_Wei_Rfc_Config *cfg)
Expand Down Expand Up @@ -386,6 +388,8 @@ static void wei_rfc_dml_to_schema(const wei_rfc_dml_parameters_t *dml, struct sc
cfg->lq_client_threshold = (int)dml->lq.client_threshold;
cfg->lq_client_detail_enable = dml->lq.client_detail_enable;
snprintf(cfg->lq_client_whitelist, sizeof(cfg->lq_client_whitelist), "%s", dml->lq.client_whitelist);

cfg->diagnostic_enable = dml->wei_diagnostic_enable;
}

/************************************************************************************
Expand Down Expand Up @@ -424,11 +428,12 @@ void callback_Wifi_Wei_Rfc_Config(ovsdb_update_monitor_t *mon, struct schema_Wif

wifi_util_dbg_print(WIFI_DB,
"%s:%d WEI RFC Config New/Modify wei_enable=%d lq_dur=%u "
"sc(h_en=%d c_en=%d) gc(h_en=%d c_en=%d) lq(h_en=%d c_en=%d)\r\n",
"sc(h_en=%d c_en=%d) gc(h_en=%d c_en=%d) lq(h_en=%d c_en=%d) diag_en=%d\r\n",
__func__, __LINE__, rfc_param->wei_enable, rfc_param->lq_meas_duration,
rfc_param->sc.home_enable, rfc_param->sc.client_enable,
rfc_param->gc.home_enable, rfc_param->gc.client_enable,
rfc_param->lq.home_enable, rfc_param->lq.client_enable);
rfc_param->lq.home_enable, rfc_param->lq.client_enable,
Comment thread
rshah-1 marked this conversation as resolved.
rfc_param->wei_diagnostic_enable);

/* Marshal onto the ctrl thread (this callback runs on the wifidb event-loop
* thread); field_id=-1 means "already applied to the DB-mirror cache above,
Expand Down Expand Up @@ -6671,6 +6676,7 @@ void wifidb_init_wei_rfc_config_default(wei_rfc_dml_parameters_t *config)
defaults.radio_2g_max_phy = WEI_RFC_RADIO_2G_MAX_PHY_DEFAULT;
defaults.radio_5g_max_phy = WEI_RFC_RADIO_5G_MAX_PHY_DEFAULT;
defaults.radio_6g_max_phy = WEI_RFC_RADIO_6G_MAX_PHY_DEFAULT;
defaults.wei_diagnostic_enable = true;
Comment thread
rshah-1 marked this conversation as resolved.

memcpy(config, &defaults, sizeof(defaults));
}
Expand Down
Loading