qcacld-3.0: Handle WMI_ROAM_STATS_EVENTID from firmware
The event WMI_ROAM_STATS_EVENTID is received after every roam, once the roam synch complete is sent by the host. This event contains details regarding the roam trigger reason, values associated with the trigger, roam scan candidate info, roam status, roam failure reason. This helps in debugging/understanding the scenario when roam failure happens. WMI_ROAM_STATS_EVENTID Format: ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ roam_stats_event_fixed_param |-> Contains vdev id and number of | roams detail. ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ roam_trigger data TLV |-> Has details on the roam trigger | reason. Number of roam triggers | TLV detail is present in the | fixed param. Maximum 5 roam | per event is supported ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ wmi_roam_scan_info TLV |-> Has details on the roam scan - | scan type, rssi threshold, | reason. ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ wmi_roam_scan_channel_info |-> Has details on the roam scan TLV | channels. Number of channels | per trigger is found on the | wmi_roam_scan_info TLV. ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ wmi_roam_ap_info TLV |-> Has details on Roam candidate | APs found during scan. Number | of roam candidate APs per | trigger is found on the | on the wmi_roam_scan_info tlv. | Max 8 candidates are allowed | per roam scan. ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ wmi_roam_result TLV |-> Info on roam success or failure. | Fail reason, if roaming failed. ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ wmi_roam_neighbor_report_info|->After roaming, firmware sends TLV | neighbor/btm report to roamed AP | to get list of roam candidates. | This tlv provides info on this. ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ wmi_roam_neighbor_channel_info|-> This has the info on the | channel list received as part | of BTM/Neighbor report. ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Print the info received as part of this event into kmsg. Featurize all the function defines for this roam logging under WLAN_FEATURE_ROAM_OFFLOAD flag. Change-Id: Iddc70b572f2e3dc47f08fd1c3c3597cb44981a17 CRs-Fixed: 2576222
Šī revīzija ir iekļauta:

revīziju iesūtīja
nshrivas

vecāks
fc03a36791
revīzija
5292e0ab83
@@ -582,7 +582,7 @@
|
||||
* gRemoveTimeStampSyncCmd - Enable/Disable to remove time stamp sync cmd
|
||||
* @Min: 0
|
||||
* @Max: 1
|
||||
* @Default: 1
|
||||
* @Default: 0
|
||||
*
|
||||
* This ini is used to enable/disable the removal of time stamp sync cmd
|
||||
*
|
||||
@@ -592,7 +592,7 @@
|
||||
*/
|
||||
#define CFG_REMOVE_TIME_STAMP_SYNC_CMD CFG_INI_BOOL( \
|
||||
"gRemoveTimeStampSyncCmd", \
|
||||
1, \
|
||||
0, \
|
||||
"Enable to remove time stamp sync cmd")
|
||||
|
||||
/*
|
||||
|
@@ -2258,4 +2258,41 @@ QDF_STATUS mlme_set_tgt_wpa3_roam_cap(struct wlan_objmgr_psoc *psoc,
|
||||
QDF_STATUS
|
||||
wlan_mlme_get_ignore_fw_reg_offload_ind(struct wlan_objmgr_psoc *psoc,
|
||||
bool *disabled);
|
||||
|
||||
/**
|
||||
* mlme_get_roam_trigger_str() - Get the string for enum
|
||||
* WMI_ROAM_TRIGGER_REASON_ID reason.
|
||||
* @roam_scan_trigger: roam scan trigger ID
|
||||
*
|
||||
* Return: Meaningful string from enum WMI_ROAM_TRIGGER_REASON_ID
|
||||
*/
|
||||
char *mlme_get_roam_trigger_str(uint32_t roam_scan_trigger);
|
||||
|
||||
/**
|
||||
* mlme_get_converted_timestamp() - Return time of the day
|
||||
* from timestamp
|
||||
* @timestamp: Timestamp value in milliseconds
|
||||
* @time: Output buffer to fill time into
|
||||
*
|
||||
* Return: Time of the day in [HH:MM:SS.uS]
|
||||
*/
|
||||
void mlme_get_converted_timestamp(uint32_t timestamp, char *time);
|
||||
|
||||
/**
|
||||
* mlme_get_roam_fail_reason_str() - Get fail string from enum
|
||||
* WMI_ROAM_FAIL_REASON_ID
|
||||
* @result: Roam fail reason
|
||||
*
|
||||
* Return: Meaningful string from enum
|
||||
*/
|
||||
char *mlme_get_roam_fail_reason_str(uint32_t result);
|
||||
|
||||
/**
|
||||
* mlme_get_sub_reason_str() - Get roam trigger sub reason from enum
|
||||
* WMI_ROAM_TRIGGER_SUB_REASON_ID
|
||||
* @sub_reason: Sub reason value
|
||||
*
|
||||
* Return: Meaningful string from enum WMI_ROAM_TRIGGER_SUB_REASON_ID
|
||||
*/
|
||||
char *mlme_get_sub_reason_str(uint32_t sub_reason);
|
||||
#endif /* _WLAN_MLME_API_H_ */
|
||||
|
@@ -41,6 +41,14 @@
|
||||
#define CFG_VHT_TX_MCS_MAP_STAMAX 0xFFFF
|
||||
#define CFG_VHT_TX_MCS_MAP_STADEF 0xFFFE
|
||||
|
||||
/* Roam debugging related macro defines */
|
||||
#define MAX_ROAM_DEBUG_BUF_SIZE 250
|
||||
#define MAX_ROAM_EVENTS_SUPPORTED 5
|
||||
#define ROAM_FAILURE_BUF_SIZE 40
|
||||
#define TIME_STRING_LEN 24
|
||||
|
||||
#define ROAM_CHANNEL_BUF_SIZE 300
|
||||
#define LINE_STR "========================================="
|
||||
/*
|
||||
* MLME_CFG_VHT_CSN_BEAMFORMEE_ANT_SUPPORTED_FW_DEF + 1 is
|
||||
* assumed to be the default fw supported BF antennas, if fw
|
||||
@@ -2280,4 +2288,18 @@ struct wlan_mlme_cfg {
|
||||
struct roam_trigger_min_rssi trig_min_rssi[NUM_OF_ROAM_TRIGGERS];
|
||||
};
|
||||
|
||||
/**
|
||||
* struct mlme_roam_debug_info - Roam debug information storage structure.
|
||||
* @trigger: Roam trigger related data
|
||||
* @scan: Roam scan related data structure.
|
||||
* @result: Roam result parameters.
|
||||
* @data_11kv: Neighbor report/BTM parameters.
|
||||
*/
|
||||
struct mlme_roam_debug_info {
|
||||
struct wmi_roam_trigger_info trigger;
|
||||
struct wmi_roam_scan_data scan;
|
||||
struct wmi_roam_result result;
|
||||
struct wmi_neighbor_report_data data_11kv;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
@@ -3545,3 +3545,103 @@ wlan_mlme_get_ignore_fw_reg_offload_ind(struct wlan_objmgr_psoc *psoc,
|
||||
*disabled = mlme_obj->cfg.reg.ignore_fw_reg_offload_ind;
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
char *mlme_get_roam_trigger_str(uint32_t roam_scan_trigger)
|
||||
{
|
||||
switch (roam_scan_trigger) {
|
||||
case WMI_ROAM_TRIGGER_REASON_PER:
|
||||
return "PER";
|
||||
case WMI_ROAM_TRIGGER_REASON_BMISS:
|
||||
return "BEACON MISS";
|
||||
case WMI_ROAM_TRIGGER_REASON_LOW_RSSI:
|
||||
return "LOW RSSI";
|
||||
case WMI_ROAM_TRIGGER_REASON_HIGH_RSSI:
|
||||
return "HIGH RSSI";
|
||||
case WMI_ROAM_TRIGGER_REASON_PERIODIC:
|
||||
return "PERIODIC SCAN";
|
||||
case WMI_ROAM_TRIGGER_REASON_MAWC:
|
||||
return "MAWC";
|
||||
case WMI_ROAM_TRIGGER_REASON_DENSE:
|
||||
return "DENSE ENVIRONMENT";
|
||||
case WMI_ROAM_TRIGGER_REASON_BACKGROUND:
|
||||
return "BACKGROUND SCAN";
|
||||
case WMI_ROAM_TRIGGER_REASON_FORCED:
|
||||
return "FORCED SCAN";
|
||||
case WMI_ROAM_TRIGGER_REASON_BTM:
|
||||
return "BTM TRIGGER";
|
||||
case WMI_ROAM_TRIGGER_REASON_UNIT_TEST:
|
||||
return "TEST COMMMAND";
|
||||
case WMI_ROAM_TRIGGER_REASON_BSS_LOAD:
|
||||
return "HIGH BSS LOAD";
|
||||
case WMI_ROAM_TRIGGER_REASON_DEAUTH:
|
||||
return "DEAUTH RECEIVED";
|
||||
case WMI_ROAM_TRIGGER_REASON_IDLE:
|
||||
return "IDLE STATE SCAN";
|
||||
case WMI_ROAM_TRIGGER_REASON_NONE:
|
||||
return "NONE";
|
||||
default:
|
||||
return "UNKNOWN";
|
||||
}
|
||||
}
|
||||
|
||||
void mlme_get_converted_timestamp(uint32_t timestamp, char *time)
|
||||
{
|
||||
uint32_t hr, mins, secs;
|
||||
|
||||
secs = timestamp / 1000;
|
||||
mins = secs / 60;
|
||||
hr = mins / 60;
|
||||
qdf_snprintf(time, TIME_STRING_LEN, "[%02d:%02d:%02d.%06u]",
|
||||
(hr % 24), (mins % 60), (secs % 60),
|
||||
(timestamp % 1000) * 1000);
|
||||
}
|
||||
|
||||
char *mlme_get_roam_fail_reason_str(uint32_t result)
|
||||
{
|
||||
switch (result) {
|
||||
case WMI_ROAM_FAIL_REASON_NO_SCAN_START:
|
||||
return "SCAN NOT STARTED";
|
||||
case WMI_ROAM_FAIL_REASON_NO_AP_FOUND:
|
||||
return "NO AP FOUND";
|
||||
case WMI_ROAM_FAIL_REASON_NO_CAND_AP_FOUND:
|
||||
return "NO CANDIDATE FOUND";
|
||||
case WMI_ROAM_FAIL_REASON_HOST:
|
||||
return "HOST ABORTED";
|
||||
case WMI_ROAM_FAIL_REASON_AUTH_SEND:
|
||||
return "Send AUTH Failed";
|
||||
case WMI_ROAM_FAIL_REASON_AUTH_RECV:
|
||||
return "Received AUTH with FAILURE Status";
|
||||
case WMI_ROAM_FAIL_REASON_NO_AUTH_RESP:
|
||||
return "No Auth response from AP";
|
||||
case WMI_ROAM_FAIL_REASON_REASSOC_SEND:
|
||||
return "Send Re-assoc request failed";
|
||||
case WMI_ROAM_FAIL_REASON_REASSOC_RECV:
|
||||
return "Received Re-Assoc resp with Failure status";
|
||||
case WMI_ROAM_FAIL_REASON_NO_REASSOC_RESP:
|
||||
return "No Re-assoc response from AP";
|
||||
case WMI_ROAM_FAIL_REASON_EAPOL_TIMEOUT:
|
||||
return "EAPOL timed out";
|
||||
case WMI_ROAM_FAIL_REASON_MLME:
|
||||
return "MLME error";
|
||||
case WMI_ROAM_FAIL_REASON_INTERNAL_ABORT:
|
||||
return "Target aborted roam";
|
||||
default:
|
||||
return "NONE";
|
||||
}
|
||||
}
|
||||
|
||||
char *mlme_get_sub_reason_str(uint32_t sub_reason)
|
||||
{
|
||||
switch (sub_reason) {
|
||||
case WMI_ROAM_TRIGGER_SUB_REASON_PERIODIC_TIMER:
|
||||
return "PERIODIC TIMER";
|
||||
case WMI_ROAM_TRIGGER_SUB_REASON_INACTIVITY_TIMER:
|
||||
return "INACTIVITY TIMER";
|
||||
case WMI_ROAM_TRIGGER_SUB_REASON_BTM_DI_TIMER:
|
||||
return "BTM DISASSOC TIMER";
|
||||
case WMI_ROAM_TRIGGER_SUB_REASON_FULL_SCAN:
|
||||
return "FULL SCAN";
|
||||
default:
|
||||
return "NONE";
|
||||
}
|
||||
}
|
||||
|
Atsaukties uz šo jaunā problēmā
Block a user