Commit d8b322b6 authored by Fabio Aiuto's avatar Fabio Aiuto Committed by Greg Kroah-Hartman
Browse files

staging: rtl8723bs: fix camel case in struct ndis_802_11_conf

parent d3fcee1b
Loading
Loading
Loading
Loading
+9 −9
Original line number Diff line number Diff line
@@ -340,7 +340,7 @@ void add_RATid(struct adapter *padapter, struct sta_info *psta, u8 rssi_level)

	shortGIrate = query_ra_short_GI(psta);

	if (pcur_network->configuration.DSConfig > 14) {
	if (pcur_network->configuration.ds_config > 14) {
		sta_band |= WIRELESS_INVALID;
	} else {
		if (tx_ra_bitmap & 0xffff000)
@@ -400,13 +400,13 @@ void update_bmc_sta(struct adapter *padapter)
		supportRateNum = rtw_get_rateset_len((u8 *)&pcur_network->supported_rates);
		network_type = rtw_check_network_type((u8 *)&pcur_network->supported_rates,
						      supportRateNum,
						      pcur_network->configuration.DSConfig
						      pcur_network->configuration.ds_config
		);
		if (is_supported_tx_cck(network_type)) {
			network_type = WIRELESS_11B;
		} else if (network_type == WIRELESS_INVALID) { /*  error handling */

			if (pcur_network->configuration.DSConfig > 14)
			if (pcur_network->configuration.ds_config > 14)
				network_type = WIRELESS_INVALID;
			else
				network_type = WIRELESS_11B;
@@ -656,8 +656,8 @@ void start_bss_network(struct adapter *padapter)
	struct HT_info_element *pht_info = NULL;
	u8 cbw40_enable = 0;

	bcn_interval = (u16)pnetwork->configuration.BeaconPeriod;
	cur_channel = pnetwork->configuration.DSConfig;
	bcn_interval = (u16)pnetwork->configuration.beacon_period;
	cur_channel = pnetwork->configuration.ds_config;
	cur_bwmode = CHANNEL_WIDTH_20;
	cur_ch_offset = HAL_PRIME_CHNL_OFFSET_DONT_CARE;

@@ -850,8 +850,8 @@ int rtw_check_beacon_data(struct adapter *padapter, u8 *pbuf, int len)

	/* beacon interval */
	p = rtw_get_beacon_interval_from_ie(ie);/* ie + 8;	8: TimeStamp, 2: Beacon Interval 2:Capability */
	/* pbss_network->configuration.BeaconPeriod = le16_to_cpu(*(unsigned short*)p); */
	pbss_network->configuration.BeaconPeriod = get_unaligned_le16(p);
	/* pbss_network->configuration.beacon_period = le16_to_cpu(*(unsigned short*)p); */
	pbss_network->configuration.beacon_period = get_unaligned_le16(p);

	/* capability */
	/* cap = *(unsigned short *)rtw_get_capability_from_ie(ie); */
@@ -873,7 +873,7 @@ int rtw_check_beacon_data(struct adapter *padapter, u8 *pbuf, int len)

	/* channel */
	channel = 0;
	pbss_network->configuration.Length = 0;
	pbss_network->configuration.length = 0;
	p = rtw_get_ie(
		ie + _BEACON_IE_OFFSET_,
		WLAN_EID_DS_PARAMS, &ie_len,
@@ -882,7 +882,7 @@ int rtw_check_beacon_data(struct adapter *padapter, u8 *pbuf, int len)
	if (p && ie_len > 0)
		channel = *(p + 2);

	pbss_network->configuration.DSConfig = channel;
	pbss_network->configuration.ds_config = channel;

	memset(supportRate, 0, NDIS_802_11_LENGTH_RATES_EX);
	/*  get supported rates */
+3 −3
Original line number Diff line number Diff line
@@ -810,7 +810,7 @@ u8 rtw_joinbss_cmd(struct adapter *padapter, struct wlan_network *pnetwork)
			/* rtw_restructure_ht_ie */
			rtw_restructure_ht_ie(padapter, &pnetwork->network.ies[12], &psecnetwork->ies[0],
									pnetwork->network.ie_length-12, &psecnetwork->ie_length,
									pnetwork->network.configuration.DSConfig);
									pnetwork->network.configuration.ds_config);
		}
	}

@@ -2004,8 +2004,8 @@ void rtw_createbss_cmd_callback(struct adapter *padapter, struct cmd_obj *pcmd)
		/*  copy pdev_network information to	pmlmepriv->cur_network */
		memcpy(&tgt_network->network, pnetwork, (get_wlan_bssid_ex_sz(pnetwork)));

		/*  reset DSConfig */
		/* tgt_network->network.configuration.DSConfig = (u32)rtw_ch2freq(pnetwork->configuration.DSConfig); */
		/*  reset ds_config */
		/* tgt_network->network.configuration.ds_config = (u32)rtw_ch2freq(pnetwork->configuration.ds_config); */

		_clr_fwstate_(pmlmepriv, _FW_UNDER_LINKING);

+3 −3
Original line number Diff line number Diff line
@@ -298,7 +298,7 @@ int rtw_generate_ie(struct registry_priv *pregistrypriv)
	ie += sz;

	/* beacon interval : 2bytes */
	*(__le16 *)ie = cpu_to_le16((u16)pdev_network->configuration.BeaconPeriod);/* BCN_INTERVAL; */
	*(__le16 *)ie = cpu_to_le16((u16)pdev_network->configuration.beacon_period);/* BCN_INTERVAL; */
	sz += 2;
	ie += 2;

@@ -334,11 +334,11 @@ int rtw_generate_ie(struct registry_priv *pregistrypriv)
	}

	/* DS parameter set */
	ie = rtw_set_ie(ie, WLAN_EID_DS_PARAMS, 1, (u8 *)&(pdev_network->configuration.DSConfig), &sz);
	ie = rtw_set_ie(ie, WLAN_EID_DS_PARAMS, 1, (u8 *)&(pdev_network->configuration.ds_config), &sz);

	/* IBSS Parameter Set */

	ie = rtw_set_ie(ie, WLAN_EID_IBSS_PARAMS, 2, (u8 *)&(pdev_network->configuration.ATIMWindow), &sz);
	ie = rtw_set_ie(ie, WLAN_EID_IBSS_PARAMS, 2, (u8 *)&(pdev_network->configuration.atim_window), &sz);

	if (rateLen > 8) {
		ie = rtw_set_ie(ie, WLAN_EID_EXT_SUPP_RATES, (rateLen - 8), (pdev_network->supported_rates + 8), &sz);
+10 −10
Original line number Diff line number Diff line
@@ -396,7 +396,7 @@ int is_same_network(struct wlan_bssid_ex *src, struct wlan_bssid_ex *dst, u8 fea
	d_cap = le16_to_cpu(tmpd);

	return (src->ssid.SsidLength == dst->ssid.SsidLength) &&
		/* 	(src->configuration.DSConfig == dst->configuration.DSConfig) && */
		/* 	(src->configuration.ds_config == dst->configuration.ds_config) && */
			((!memcmp(src->mac_address, dst->mac_address, ETH_ALEN))) &&
			((!memcmp(src->ssid.Ssid, dst->ssid.Ssid, src->ssid.SsidLength))) &&
			((s_cap & WLAN_CAPABILITY_IBSS) ==
@@ -1148,7 +1148,7 @@ static void rtw_joinbss_update_network(struct adapter *padapter, struct wlan_net
	rtw_update_protection(padapter, (cur_network->network.ies) + sizeof(struct ndis_802_11_fix_ie),
									(cur_network->network.ie_length));

	rtw_update_ht_cap(padapter, cur_network->network.ies, cur_network->network.ie_length, (u8) cur_network->network.configuration.DSConfig);
	rtw_update_ht_cap(padapter, cur_network->network.ies, cur_network->network.ie_length, (u8) cur_network->network.configuration.ds_config);
}

/* Notes: the function could be > passive_level (the same context as Rx tasklet) */
@@ -2152,12 +2152,12 @@ void rtw_init_registrypriv_dev_network(struct adapter *adapter)

	memcpy(&pdev_network->ssid, &pregistrypriv->ssid, sizeof(struct ndis_802_11_ssid));

	pdev_network->configuration.Length = sizeof(struct ndis_802_11_conf);
	pdev_network->configuration.BeaconPeriod = 100;
	pdev_network->configuration.FHConfig.Length = 0;
	pdev_network->configuration.FHConfig.HopPattern = 0;
	pdev_network->configuration.FHConfig.HopSet = 0;
	pdev_network->configuration.FHConfig.DwellTime = 0;
	pdev_network->configuration.length = sizeof(struct ndis_802_11_conf);
	pdev_network->configuration.beacon_period = 100;
	pdev_network->configuration.fh_config.Length = 0;
	pdev_network->configuration.fh_config.HopPattern = 0;
	pdev_network->configuration.fh_config.HopSet = 0;
	pdev_network->configuration.fh_config.DwellTime = 0;
}

void rtw_update_registrypriv_dev_network(struct adapter *adapter)
@@ -2189,10 +2189,10 @@ void rtw_update_registrypriv_dev_network(struct adapter *adapter)
		break;
	}

	pdev_network->configuration.DSConfig = (pregistrypriv->channel);
	pdev_network->configuration.ds_config = (pregistrypriv->channel);

	if (cur_network->network.infrastructure_mode == Ndis802_11IBSS)
		pdev_network->configuration.ATIMWindow = (0);
		pdev_network->configuration.atim_window = (0);

	pdev_network->infrastructure_mode = (cur_network->network.infrastructure_mode);

+17 −17
Original line number Diff line number Diff line
@@ -2237,7 +2237,7 @@ void issue_beacon(struct adapter *padapter, int timeout_ms)
	pframe = rtw_set_ie(pframe, WLAN_EID_SUPP_RATES, ((rate_len > 8) ? 8 : rate_len), cur_network->supported_rates, &pattrib->pktlen);

	/*  DS parameter set */
	pframe = rtw_set_ie(pframe, WLAN_EID_DS_PARAMS, 1, (unsigned char *)&(cur_network->configuration.DSConfig), &pattrib->pktlen);
	pframe = rtw_set_ie(pframe, WLAN_EID_DS_PARAMS, 1, (unsigned char *)&(cur_network->configuration.ds_config), &pattrib->pktlen);

	/* if ((pmlmeinfo->state&0x03) == WIFI_FW_ADHOC_STATE) */
	{
@@ -2440,7 +2440,7 @@ void issue_probersp(struct adapter *padapter, unsigned char *da, u8 is_valid_p2p
		pframe = rtw_set_ie(pframe, WLAN_EID_SUPP_RATES, ((rate_len > 8) ? 8 : rate_len), cur_network->supported_rates, &pattrib->pktlen);

		/*  DS parameter set */
		pframe = rtw_set_ie(pframe, WLAN_EID_DS_PARAMS, 1, (unsigned char *)&(cur_network->configuration.DSConfig), &pattrib->pktlen);
		pframe = rtw_set_ie(pframe, WLAN_EID_DS_PARAMS, 1, (unsigned char *)&(cur_network->configuration.ds_config), &pattrib->pktlen);

		if ((pmlmeinfo->state&0x03) == WIFI_FW_ADHOC_STATE) {
			u8 erpinfo = 0;
@@ -3708,10 +3708,10 @@ static void issue_action_BSSCoexistPacket(struct adapter *padapter)
			p = rtw_get_ie(pbss_network->ies + _FIXED_IE_LENGTH_, WLAN_EID_HT_CAPABILITY, &len, pbss_network->ie_length - _FIXED_IE_LENGTH_);
			if ((p == NULL) || (len == 0)) {/* non-HT */

				if (pbss_network->configuration.DSConfig <= 0)
				if (pbss_network->configuration.ds_config <= 0)
					continue;

				ICS[0][pbss_network->configuration.DSConfig] = 1;
				ICS[0][pbss_network->configuration.ds_config] = 1;

				if (ICS[0][0] == 0)
					ICS[0][0] = 1;
@@ -4038,14 +4038,14 @@ u8 collect_bss_info(struct adapter *padapter, union recv_frame *precv_frame, str
	if (bssid->ie_length < 12)
		return _FAIL;

	/*  Checking for DSConfig */
	/*  Checking for ds_config */
	p = rtw_get_ie(bssid->ies + ie_offset, WLAN_EID_DS_PARAMS, &len, bssid->ie_length - ie_offset);

	bssid->configuration.DSConfig = 0;
	bssid->configuration.Length = 0;
	bssid->configuration.ds_config = 0;
	bssid->configuration.length = 0;

	if (p) {
		bssid->configuration.DSConfig = *(p + 2);
		bssid->configuration.ds_config = *(p + 2);
	} else {
		/*  In 5G, some ap do not have DSSET IE */
		/*  checking HT info for channel */
@@ -4053,14 +4053,14 @@ u8 collect_bss_info(struct adapter *padapter, union recv_frame *precv_frame, str
		if (p) {
			struct HT_info_element *HT_info = (struct HT_info_element *)(p + 2);

			bssid->configuration.DSConfig = HT_info->primary_channel;
			bssid->configuration.ds_config = HT_info->primary_channel;
		} else { /*  use current channel */
			bssid->configuration.DSConfig = rtw_get_oper_ch(padapter);
			bssid->configuration.ds_config = rtw_get_oper_ch(padapter);
		}
	}

	memcpy(&le32_tmp, rtw_get_beacon_interval_from_ie(bssid->ies), 2);
	bssid->configuration.BeaconPeriod = le32_to_cpu(le32_tmp);
	bssid->configuration.beacon_period = le32_to_cpu(le32_tmp);

	val16 = rtw_get_capability((struct wlan_bssid_ex *)bssid);

@@ -4077,7 +4077,7 @@ u8 collect_bss_info(struct adapter *padapter, union recv_frame *precv_frame, str
	else
		bssid->privacy = 0;

	bssid->configuration.ATIMWindow = 0;
	bssid->configuration.atim_window = 0;

	/* 20/40 BSS Coexistence check */
	if ((pregistrypriv->wifi_spec == 1) && (false == pmlmeinfo->bwmode_updated)) {
@@ -4096,7 +4096,7 @@ u8 collect_bss_info(struct adapter *padapter, union recv_frame *precv_frame, str
	}

	/*  mark bss info receiving from nearby channel as SignalQuality 101 */
	if (bssid->configuration.DSConfig != rtw_get_oper_ch(padapter))
	if (bssid->configuration.ds_config != rtw_get_oper_ch(padapter))
		bssid->phy_info.SignalQuality = 101;

	return _SUCCESS;
@@ -4111,7 +4111,7 @@ void start_create_ibss(struct adapter *padapter)
	struct mlme_ext_info *pmlmeinfo = &(pmlmeext->mlmext_info);
	struct wlan_bssid_ex		*pnetwork = (struct wlan_bssid_ex *)(&(pmlmeinfo->network));

	pmlmeext->cur_channel = (u8)pnetwork->configuration.DSConfig;
	pmlmeext->cur_channel = (u8)pnetwork->configuration.ds_config;
	pmlmeinfo->bcn_interval = get_beacon_interval(pnetwork);

	/* update wireless mode */
@@ -4409,7 +4409,7 @@ static void process_80211d(struct adapter *padapter, struct wlan_bssid_ex *bssid
	}

	/*  If channel is used by AP, set channel scan type to active */
	channel = bssid->configuration.DSConfig;
	channel = bssid->configuration.ds_config;
	chplan_new = pmlmeext->channel_set;
	i = 0;
	while ((i < MAX_CHANNEL_NUM) && (chplan_new[i].ChannelNum != 0)) {
@@ -5401,7 +5401,7 @@ u8 join_cmd_hdl(struct adapter *padapter, u8 *pbuf)

	memcpy(pnetwork->ies, ((struct wlan_bssid_ex *)pbuf)->ies, pnetwork->ie_length);

	pmlmeext->cur_channel = (u8)pnetwork->configuration.DSConfig;
	pmlmeext->cur_channel = (u8)pnetwork->configuration.ds_config;
	pmlmeinfo->bcn_interval = get_beacon_interval(pnetwork);

	/* Check AP vendor to move rtw_joinbss_cmd() */
@@ -5428,7 +5428,7 @@ u8 join_cmd_hdl(struct adapter *padapter, u8 *pbuf)
			{
				struct HT_info_element *pht_info = (struct HT_info_element *)(pIE->data);

				if (pnetwork->configuration.DSConfig <= 14) {
				if (pnetwork->configuration.ds_config <= 14) {
					if ((pregpriv->bw_mode & 0x0f) > CHANNEL_WIDTH_20)
						cbw40_enable = 1;
				}
Loading