From: Jes Sorensen Date: Mon, 9 Jun 2014 13:16:05 +0000 (+0200) Subject: staging: rtl8723au: Remove WMM_ defines X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=c9324c88533fbb15ec59de8e0d4b9d0c9d100026;p=openwrt%2Fstaging%2Fblogic.git staging: rtl8723au: Remove WMM_ defines Only one is used, and only describes the size of an array defined in a local function. Use sizeof() in the local function to deobfuscate it. Signed-off-by: Jes Sorensen Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/rtl8723au/core/rtw_mlme.c b/drivers/staging/rtl8723au/core/rtw_mlme.c index 76e1797c8f2b..a3174c0d42f9 100644 --- a/drivers/staging/rtl8723au/core/rtw_mlme.c +++ b/drivers/staging/rtl8723au/core/rtw_mlme.c @@ -2197,7 +2197,7 @@ unsigned int rtw_restructure_ht_ie23a(struct rtw_adapter *padapter, u8 *in_ie, unsigned char *pframe; const u8 *p; struct ieee80211_ht_cap ht_capie; - unsigned char WMM_IE[] = {0x00, 0x50, 0xf2, 0x02, 0x00, 0x01, 0x00}; + u8 WMM_IE[7] = {0x00, 0x50, 0xf2, 0x02, 0x00, 0x01, 0x00}; struct mlme_priv *pmlmepriv = &padapter->mlmepriv; struct ht_priv *phtpriv = &pmlmepriv->htpriv; @@ -2210,8 +2210,9 @@ unsigned int rtw_restructure_ht_ie23a(struct rtw_adapter *padapter, u8 *in_ie, if (pmlmepriv->qos_option == 0) { out_len = *pout_len; pframe = rtw_set_ie23a(out_ie + out_len, - WLAN_EID_VENDOR_SPECIFIC, - _WMM_IE_Length_, WMM_IE, pout_len); + WLAN_EID_VENDOR_SPECIFIC, + sizeof(WMM_IE), WMM_IE, + pout_len); pmlmepriv->qos_option = 1; } diff --git a/drivers/staging/rtl8723au/include/wifi.h b/drivers/staging/rtl8723au/include/wifi.h index 4ab28e59f8ba..07ea4c63e71b 100644 --- a/drivers/staging/rtl8723au/include/wifi.h +++ b/drivers/staging/rtl8723au/include/wifi.h @@ -52,13 +52,6 @@ #define _STATUS_CODE_ 2 #define _TIMESTAMP_ 8 -/*----------------------------------------------------------------------------- - Below is the definition for WMM -------------------------------------------------------------------------------*/ -#define _WMM_IE_Length_ 7 /* for WMM STA */ -#define _WMM_Para_Element_Length_ 24 - - /*----------------------------------------------------------------------------- Below is the definition for 802.11n ------------------------------------------------------------------------------*/