qcacmn: Add error handling in the Spectral control path
Add an attribute which describes the error code in the response to set config, start scan and stop scan. CRs-Fixed: 2500481 Change-Id: I491cd6e061d2d08ceb4d9af2a7de5223e229c280
This commit is contained in:

gecommit door
nshrivas

bovenliggende
ae946e39c7
commit
9217a212bb
@@ -429,7 +429,8 @@ spectral_control_cmn(struct wlan_objmgr_pdev *pdev,
|
||||
break;
|
||||
|
||||
case SPECTRAL_STOP_SCAN:
|
||||
sc->sptrlc_stop_spectral_scan(pdev, smode);
|
||||
err = &sscan_req->action_req.sscan_err_code;
|
||||
sc->sptrlc_stop_spectral_scan(pdev, smode, err);
|
||||
break;
|
||||
|
||||
case SPECTRAL_GET_CAPABILITY_INFO:
|
||||
|
@@ -143,8 +143,10 @@ struct spectral_context {
|
||||
(struct wlan_objmgr_pdev *pdev,
|
||||
const enum spectral_scan_mode smode,
|
||||
enum spectral_cp_error_code *err);
|
||||
QDF_STATUS (*sptrlc_stop_spectral_scan)(struct wlan_objmgr_pdev *pdev,
|
||||
enum spectral_scan_mode smode);
|
||||
QDF_STATUS (*sptrlc_stop_spectral_scan)
|
||||
(struct wlan_objmgr_pdev *pdev,
|
||||
enum spectral_scan_mode smode,
|
||||
enum spectral_cp_error_code *err);
|
||||
bool (*sptrlc_is_spectral_active)(struct wlan_objmgr_pdev *pdev,
|
||||
enum spectral_scan_mode smode);
|
||||
bool (*sptrlc_is_spectral_enabled)(struct wlan_objmgr_pdev *pdev,
|
||||
|
@@ -56,7 +56,7 @@
|
||||
* ioctl parameter types
|
||||
*/
|
||||
enum spectral_params {
|
||||
SPECTRAL_PARAM_FFT_PERIOD = 1,
|
||||
SPECTRAL_PARAM_FFT_PERIOD,
|
||||
SPECTRAL_PARAM_SCAN_PERIOD,
|
||||
SPECTRAL_PARAM_SCAN_COUNT,
|
||||
SPECTRAL_PARAM_SHORT_REPORT,
|
||||
@@ -80,8 +80,7 @@ enum spectral_params {
|
||||
SPECTRAL_PARAM_STOP,
|
||||
SPECTRAL_PARAM_ENABLE,
|
||||
SPECTRAL_PARAM_FREQUENCY,
|
||||
SPECTRAL_PARAM_AFTER_LAST,
|
||||
SPECTRAL_PARAM_MAX = SPECTRAL_PARAM_AFTER_LAST - 1,
|
||||
SPECTRAL_PARAM_MAX,
|
||||
};
|
||||
|
||||
/**
|
||||
|
@@ -218,12 +218,14 @@ enum spectral_capability_type {
|
||||
|
||||
/**
|
||||
* enum spectral_cp_error_code - Spectral control path response code
|
||||
* @SPECTRAL_SCAN_RESP_ERR_INVALID: Invalid error identifier
|
||||
* @SPECTRAL_SCAN_RESP_ERR_PARAM_UNSUPPORTED: parameter unsupported
|
||||
* @SPECTRAL_SCAN_RESP_ERR_MODE_UNSUPPORTED: mode unsupported
|
||||
* @SPECTRAL_SCAN_RESP_ERR_PARAM_INVALID_VALUE: invalid parameter value
|
||||
* @SPECTRAL_SCAN_RESP_ERR_PARAM_NOT_INITIALIZED: parameter uninitialized
|
||||
*/
|
||||
enum spectral_cp_error_code {
|
||||
SPECTRAL_SCAN_ERR_INVALID,
|
||||
SPECTRAL_SCAN_ERR_PARAM_UNSUPPORTED,
|
||||
SPECTRAL_SCAN_ERR_MODE_UNSUPPORTED,
|
||||
SPECTRAL_SCAN_ERR_PARAM_INVALID_VALUE,
|
||||
|
@@ -102,7 +102,7 @@ QDF_STATUS tgt_get_spectral_config(struct wlan_objmgr_pdev *pdev,
|
||||
* tgt_start_spectral_scan() - Start spectral scan
|
||||
* @pdev: Pointer to pdev object
|
||||
* @smode: Spectral scan mode
|
||||
* @res: Spectral control path error code
|
||||
* @err: Spectral control path error code
|
||||
*
|
||||
* Implementation for starting spectral scan
|
||||
*
|
||||
@@ -116,13 +116,15 @@ QDF_STATUS tgt_start_spectral_scan(struct wlan_objmgr_pdev *pdev,
|
||||
* tgt_stop_spectral_scan() - Stop spectral scan
|
||||
* @pdev: Pointer to pdev object
|
||||
* @smode: Spectral scan mode
|
||||
* @err: Spectral control path error code
|
||||
*
|
||||
* Implementation for stop spectral scan
|
||||
*
|
||||
* Return: QDF_STATUS_SUCCESS on success, else QDF_STATUS_E_FAILURE
|
||||
*/
|
||||
QDF_STATUS tgt_stop_spectral_scan(struct wlan_objmgr_pdev *pdev,
|
||||
enum spectral_scan_mode smode);
|
||||
enum spectral_scan_mode smode,
|
||||
enum spectral_cp_error_code *err);
|
||||
|
||||
/**
|
||||
* tgt_is_spectral_active() - Get whether Spectral is active
|
||||
|
@@ -125,13 +125,14 @@ tgt_start_spectral_scan(struct wlan_objmgr_pdev *pdev,
|
||||
|
||||
QDF_STATUS
|
||||
tgt_stop_spectral_scan(struct wlan_objmgr_pdev *pdev,
|
||||
enum spectral_scan_mode smode)
|
||||
enum spectral_scan_mode smode,
|
||||
enum spectral_cp_error_code *err)
|
||||
{
|
||||
struct wlan_objmgr_psoc *psoc = NULL;
|
||||
struct wlan_objmgr_psoc *psoc;
|
||||
|
||||
psoc = wlan_pdev_get_psoc(pdev);
|
||||
return psoc->soc_cb.tx_ops.sptrl_tx_ops.sptrlto_stop_spectral_scan(
|
||||
pdev, smode);
|
||||
pdev, smode, err);
|
||||
}
|
||||
|
||||
bool
|
||||
|
Verwijs in nieuw issue
Block a user