qcacld-3.0: Replace typedef tdls_config_params_t

The Linux Coding Style enumerates a few special cases where typedefs
are useful, but stresses "NEVER EVER use a typedef unless you can
clearly match one of those rules." The tdls_config_params_t typedef
does not meet any of those criteria, so replace references to it with
a reference to a properly named struct.

Change-Id: Iac14e2e25c7079773e89385fd87b632840ca6a53
CRs-Fixed: 2119582
This commit is contained in:
Jeff Johnson 2017-10-01 20:09:16 -07:00 • committed by snandini
commit a0ce1020cc
3 changed files with 7 additions and 7 deletions

View file

@ -51,7 +51,7 @@ enum tdls_concerned_external_events {
#define ENA_TDLS_BUFFER_STA (1 << 1) /* TDLS Buffer STA support */
#define ENA_TDLS_SLEEP_STA (1 << 2) /* TDLS Sleep STA support */
/**
* struct tdls_config_params_t - tdls config params
* struct hdd_tdls_config_params - tdls config params
*
* @tdls: tdls
* @tx_period_t: tx period
@ -63,7 +63,7 @@ enum tdls_concerned_external_events {
* @rssi_teardown_threshold: rssi tear down threshold
* @rssi_delta: rssi delta
*/
typedef struct {
struct hdd_tdls_config_params {
uint32_t tdls;
uint32_t tx_period_t;
uint32_t tx_packet_n;
@ -73,7 +73,7 @@ typedef struct {
int32_t rssi_trigger_threshold;
int32_t rssi_teardown_threshold;
int32_t rssi_delta;
} tdls_config_params_t;
};
typedef int (*cfg80211_exttdls_callback)(const uint8_t *mac,
uint32_t opclass,
@ -120,7 +120,7 @@ typedef struct {
} tdlsInfo_t;
int wlan_hdd_tdls_set_params(struct net_device *dev,
tdls_config_params_t *config);
struct hdd_tdls_config_params *config);
int wlan_hdd_tdls_get_all_peers(struct hdd_adapter *pAdapter, char *buf,
int buflen);

View file

@ -107,7 +107,7 @@ static void dump_tdls_state_param_setting(tdlsInfo_t *info)
*
* Return: 0 if all parameters are valid; -EINVAL otherwise
*/
static int wlan_hdd_tdls_check_config(tdls_config_params_t *config)
static int wlan_hdd_tdls_check_config(struct hdd_tdls_config_params *config)
{
if (config->tdls > 2) {
hdd_err("Invalid 1st argument %d. <0...2>",
@ -182,7 +182,7 @@ static int wlan_hdd_tdls_check_config(tdls_config_params_t *config)
* Return: 0 if success or negative errno otherwise
*/
int wlan_hdd_tdls_set_params(struct net_device *dev,
tdls_config_params_t *config)
struct hdd_tdls_config_params *config)
{
struct hdd_adapter *pAdapter = WLAN_HDD_GET_PRIV_PTR(dev);
struct hdd_context *hdd_ctx = WLAN_HDD_GET_CTX(pAdapter);

View file

@ -11127,7 +11127,7 @@ static int __iw_set_var_ints_getnone(struct net_device *dev,
#ifdef FEATURE_WLAN_TDLS
case WE_TDLS_CONFIG_PARAMS:
{
tdls_config_params_t tdlsParams;
struct hdd_tdls_config_params tdlsParams;
tdlsParams.tdls = apps_args[0];
tdlsParams.tx_period_t = apps_args[1];