staging: rtl8723bs: rename dot118021x_UncstKey to dot118021x_uncst_key
PATCH v2 1/1 staging: rtl8723bs: rename dot118021x_UncstKey to dot118021x_uncst_key
checkpatch.pl warns about CamelCase in the struct member dot118021x_UncstKey. Rename it to dot118021x_uncst_key to follow the kernel coding style.
Also wrap lines that exceed 100 columns because of the longer name
Signed-off-by Gowtham S Bhushan <[email protected]>
---
v2: dropped an unrelated change to the grpkey memcpy line in ioctl_cfg80211.c
drivers/staging/rtl8723bs/core/rtw_ap.c | 2 +- drivers/staging/rtl8723bs/core/rtw_cmd.c | 2 +- drivers/staging/rtl8723bs/core/rtw_mlme.c | 2 +- drivers/staging/rtl8723bs/core/rtw_security.c | 8 ++++---- drivers/staging/rtl8723bs/core/rtw_xmit.c | 7 ++++--- drivers/staging/rtl8723bs/include/rtw_xmit.h | 2 +- drivers/staging/rtl8723bs/include/sta_info.h | 2 +- drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c | 7 +++++-- 8 files changed, 18 insertions(+), 14 deletions(-)
drivers/staging/rtl8723bs/core/rtw_ap.c +1 -1
@@ -1167,7 +1167,7 @@ u8 rtw_ap_set_pairwise_key(struct adapter *padapter, struct sta_info *psta)memcpy (psetstakey_para->addr, psta->hwaddr,ETH_ALEN ); -memcpy (psetstakey_para->key, &psta->dot118021x_UncstKey,16 ); +memcpy (psetstakey_para->key, &psta->dot118021x_uncst_key,16 ); res =rtw_enqueue_cmd (pcmdpriv, ph2c);
drivers/staging/rtl8723bs/core/rtw_cmd.c +1 -1
@@ -880,7 +880,7 @@ u8 rtw_setstakey_cmd(struct adapter *padapter, struct sta_info *sta, u8 unicast_GET_ENCRY_ALGO (psecuritypriv, sta, psetstakey_para->algorithm, false);if (unicast_key) -memcpy (&psetstakey_para->key, &sta->dot118021x_UncstKey,16 ); +memcpy (&psetstakey_para->key, &sta->dot118021x_uncst_key,16 );else memcpy (&psetstakey_para->key, &psecuritypriv->dot118021XGrpKey[psecuritypriv->dot118021XGrpKeyid].skey,16 );
drivers/staging/rtl8723bs/core/rtw_mlme.c +1 -1
@@ -984,7 +984,7 @@ static struct sta_info *rtw_joinbss_update_stainfo(struct adapter *adapter, stru psta->ieee8021x_blocked = true; psta->dot118021_x_privacy = adapter->securitypriv.dot11_privacy_algrthm; -memset ((u8 *)&psta->dot118021x_UncstKey,0 ,sizeof (union Keytype )); +memset ((u8 *)&psta->dot118021x_uncst_key,0 ,sizeof (union Keytype ));memset ((u8 *)&psta->dot11tkiprxmickey,0 ,sizeof (union Keytype ));memset ((u8 *)&psta->dot11tkiptxmickey,0 ,sizeof (union Keytype ));
drivers/staging/rtl8723bs/core/rtw_security.c +4 -4
@@ -458,7 +458,7 @@ u32 rtw_tkip_encrypt(struct adapter *padapter, u8 *pxmitframe)if (is_multicast_ether_addr (pattrib->ra)) prwskey = psecuritypriv->dot118021XGrpKey[psecuritypriv->dot118021XGrpKeyid].skey;else - prwskey = pattrib->dot118021x_UncstKey.skey; + prwskey = pattrib->dot118021x_uncst_key.skey;for (curfragnum =0 ; curfragnum < pattrib->nr_frags; curfragnum++) { iv = pframe + pattrib->hdrlen;
@@ -573,7 +573,7 @@ u32 rtw_tkip_decrypt(struct adapter *padapter, u8 *precvframe) prwskey = psecuritypriv->dot118021XGrpKey[prxattrib->key_index].skey; }else { - prwskey = &stainfo->dot118021x_UncstKey.skey[0 ]; + prwskey = &stainfo->dot118021x_uncst_key.skey[0 ]; } iv = pframe + prxattrib->hdrlen;
@@ -960,7 +960,7 @@ u32 rtw_aes_encrypt(struct adapter *padapter, u8 *pxmitframe)if (is_multicast_ether_addr (pattrib->ra)) prwskey = psecuritypriv->dot118021XGrpKey[psecuritypriv->dot118021XGrpKeyid].skey;else - prwskey = pattrib->dot118021x_UncstKey.skey; + prwskey = pattrib->dot118021x_uncst_key.skey;for (curfragnum =0 ; curfragnum < pattrib->nr_frags; curfragnum++) {if ((curfragnum +1 ) == pattrib->nr_frags) {/* 4 the last fragment */
@@ -1248,7 +1248,7 @@ u32 rtw_aes_decrypt(struct adapter *padapter, u8 *precvframe) goto exit; } }else { - prwskey = &stainfo->dot118021x_UncstKey.skey[0 ]; + prwskey = &stainfo->dot118021x_uncst_key.skey[0 ]; } length = ((union recv_frame *)precvframe)->u.hdr.len -
drivers/staging/rtl8723bs/core/rtw_xmit.c +4 -3
@@ -512,7 +512,7 @@ static int update_attrib_sec_info(struct adapter *padapter, struct pkt_attrib *pstruct security_priv *psecuritypriv = &padapter->securitypriv;signed int bmcast =is_multicast_ether_addr (pattrib->ra); -memset (pattrib->dot118021x_UncstKey.skey,0 ,16 ); +memset (pattrib->dot118021x_uncst_key.skey,0 ,16 );memset (pattrib->dot11tkiptxmickey.skey,0 ,16 ); pattrib->mac_id = psta->mac_id;
@@ -589,7 +589,7 @@ static int update_attrib_sec_info(struct adapter *padapter, struct pkt_attrib *p }if (pattrib->encrypt >0 ) -memcpy (pattrib->dot118021x_UncstKey.skey, psta->dot118021x_UncstKey.skey,16 ); +memcpy (pattrib->dot118021x_uncst_key.skey, psta->dot118021x_uncst_key.skey,16 );if (pattrib->encrypt && ((padapter->securitypriv.sw_encrypt) || (!psecuritypriv->hw_decrypted)))
@@ -1289,7 +1289,8 @@ int rtw_mgmt_xmitframe_coalesce(struct adapter *padapter, struct sk_buff *pkt, s goto xmitframe_coalesce_fail;/* before encrypt dump the management packet content */ if (pattrib->encrypt >0 ) -memcpy (pattrib->dot118021x_UncstKey.skey, psta->dot118021x_UncstKey.skey,16 ); +memcpy (pattrib->dot118021x_uncst_key.skey, + psta->dot118021x_uncst_key.skey,16 );/* bakeup original management packet */ memcpy (tmp_buf, pframe, pattrib->pktlen);/* move to data portion */
drivers/staging/rtl8723bs/include/rtw_xmit.h +1 -1
@@ -162,7 +162,7 @@ struct pkt_attrib {u8 rtsen;u8 cts2self;union Keytype dot11tkiptxmickey; -union Keytype dot118021x_UncstKey; +union Keytype dot118021x_uncst_key;u8 icmp_pkt;
drivers/staging/rtl8723bs/include/sta_info.h +1 -1
@@ -90,7 +90,7 @@ struct sta_info {uint dot118021_x_privacy;/* aes, tkip... */ union Keytype dot11tkiptxmickey;union Keytype dot11tkiprxmickey; -union Keytype dot118021x_UncstKey; +union Keytype dot118021x_uncst_key;union pn48 dot11txpn;/* PN48 used for Unicast xmit */ union pn48 dot11wtxpn;/* PN48 used for Unicast mgmt xmit. */ union pn48 dot11rxpn;/* PN48 used for Unicast recv. */
drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c +5 -2
@@ -607,7 +607,8 @@ static int rtw_cfg80211_ap_set_encryption(struct net_device *dev, struct ieee_paif (psecuritypriv->dot11_auth_algrthm == dot11_auth_algrthm_8021x && psta) {/* psk/802_1x */ if (check_fwstate (pmlmepriv,WIFI_AP_STATE )) {if (param->u.crypt.set_tx ==1 ) {/* pairwise key */ -memcpy (psta->dot118021x_UncstKey.skey, param->u.crypt.key, (param->u.crypt.key_len >16 ?16 : param->u.crypt.key_len)); +memcpy (psta->dot118021x_uncst_key.skey, param->u.crypt.key, + (param->u.crypt.key_len >16 ?16 : param->u.crypt.key_len));if (strcmp (param->u.crypt.alg,"WEP" ) ==0 ) { psta->dot118021_x_privacy = _WEP40_;
@@ -770,7 +771,9 @@ static int rtw_cfg80211_set_encryption(struct net_device *dev, struct ieee_paramif (param->u.crypt.set_tx ==1 ) {/* pairwise key */ -memcpy (psta->dot118021x_UncstKey.skey, param->u.crypt.key, (param->u.crypt.key_len >16 ?16 : param->u.crypt.key_len)); +memcpy (psta->dot118021x_uncst_key.skey, param->u.crypt.key, + (param->u.crypt.key_len >16 ?16 : + param->u.crypt.key_len));if (strcmp (param->u.crypt.alg,"TKIP" ) ==0 ) {/* set mic key */ memcpy (psta->dot11tkiptxmickey.skey, ¶m->u.crypt.key[16 ],8 );
Signature · 1 line
2.55.0