Merge pull request #9 from kimocoder/v5.1.5

Merge changes
This commit is contained in:
evilphish 2017-11-15 22:02:06 +01:00 committed by GitHub
commit 37aa584934
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 11 additions and 35 deletions

View File

@ -14,7 +14,7 @@ EXTRA_CFLAGS += -Wno-unused-parameter
EXTRA_CFLAGS += -Wno-unused-function
EXTRA_CFLAGS += -Wno-unused
EXTRA_CFLAGS += -Wno-date-time
EXTRA_CFLAGS += -Wno-misleading-indentation
#EXTRA_CFLAGS += -Wno-misleading-indentation
#EXTRA_CFLAGS += -Wno-uninitialized
GCC_VER_49 := $(shell echo `$(CC) -dumpversion | cut -f1-2 -d.` \>= 4.9 | bc )
@ -48,6 +48,7 @@ CONFIG_PCI_HCI = n
CONFIG_SDIO_HCI = n
CONFIG_GSPI_HCI = n
########################## Features ###########################
CONFIG_NET_NS = y
CONFIG_MP_INCLUDED = y
CONFIG_POWER_SAVING = n
CONFIG_USB_AUTOSUSPEND = n
@ -64,7 +65,7 @@ CONFIG_CALIBRATE_TX_POWER_TO_MAX = y
CONFIG_RTW_ADAPTIVITY_EN = disable
CONFIG_RTW_ADAPTIVITY_MODE = normal
CONFIG_SIGNAL_SCALE_MAPPING = n
CONFIG_80211W = n
CONFIG_80211W = y
CONFIG_REDUCE_TX_CPU_LOADING = n
CONFIG_BR_EXT = y
CONFIG_TDLS = n

View File

@ -336,7 +336,6 @@ u16 rtw_get_efuse_mask_arraylen(PADAPTER pAdapter)
return 0;
}
#ifdef RTW_HALMAC
#include "../../hal/hal_halmac.h"
@ -386,7 +385,6 @@ void EFUSE_GetEfuseDefinition(PADAPTER adapter, u8 efusetype, u8 type, void *out
struct dvobj_priv *d;
u32 v32 = 0;
d = adapter_to_dvobj(adapter);
if (adapter->HalFunc.EFUSEGetEfuseDefinition) {
@ -414,7 +412,6 @@ u8 rtw_efuse_access(PADAPTER adapter, u8 write, u16 addr, u16 cnts, u8 *data)
u32 size, i;
int err;
d = adapter_to_dvobj(adapter);
err = rtw_halmac_get_physical_efuse_size(d, &size);
if (err)
@ -715,7 +712,6 @@ VOID hal_ReadEFuse_BT_logic_map(
u16 i, total, used;
u8 efuse_usage;
/* */
/* Do NOT excess total size of EFuse table. Added by Roger, 2008.11.10. */
/* */
@ -830,7 +826,6 @@ exit:
rtw_mfree(efuseTbl, EFUSE_BT_MAP_LEN);
}
static u8 hal_EfusePartialWriteCheck(
PADAPTER padapter,
u8 efuseType,
@ -873,7 +868,6 @@ static u8 hal_EfusePartialWriteCheck(
return bRet;
}
static u8 hal_EfusePgPacketWrite2ByteHeader(
PADAPTER padapter,
u8 efuseType,
@ -940,7 +934,6 @@ static u8 hal_EfusePgPacketWrite2ByteHeader(
return _TRUE;
}
static u8 hal_EfusePgPacketWrite1ByteHeader(
PADAPTER pAdapter,
u8 efuseType,
@ -953,7 +946,6 @@ static u8 hal_EfusePgPacketWrite1ByteHeader(
u16 efuse_addr = *pAddr;
u8 repeatcnt = 0;
/* RTW_INFO("%s\n", __FUNCTION__); */
pg_header = ((pTargetPkt->offset << 4) & 0xf0) | pTargetPkt->word_en;
@ -996,7 +988,6 @@ static u8 hal_EfusePgPacketWriteHeader(
return bRet;
}
static u8
Hal_EfuseWordEnableDataWrite(
PADAPTER padapter,
@ -1010,7 +1001,6 @@ Hal_EfuseWordEnableDataWrite(
u8 badworden = 0x0F;
u8 tmpdata[PGPKT_DATA_SIZE];
/* RTW_INFO("%s: efuse_addr=%#x word_en=%#x\n", __FUNCTION__, efuse_addr, word_en); */
_rtw_memset(tmpdata, 0xFF, PGPKT_DATA_SIZE);
@ -1116,7 +1106,6 @@ u8 EfusePgPacketWrite_BT(
return _TRUE;
}
#else /* !RTW_HALMAC */
/* ------------------------------------------------------------------------------ */
#define REG_EFUSE_CTRL 0x0030
@ -1469,7 +1458,6 @@ EFUSE_Write1Byte(
}
} /* EFUSE_Write1Byte */
/* 11/16/2008 MH Read one byte from real Efuse. */
u8
efuse_OneByteRead(
@ -1555,7 +1543,6 @@ efuse_OneByteWrite(
/* -----------------e-fuse reg ctrl --------------------------------- */
/* address */
efuseValue = rtw_read32(pAdapter, EFUSE_CTRL);
efuseValue |= (BIT21 | BIT31);
efuseValue &= ~(0x3FFFF);
@ -1627,7 +1614,6 @@ Efuse_PgPacketWrite(IN PADAPTER pAdapter,
return ret;
}
int
Efuse_PgPacketWrite_BT(IN PADAPTER pAdapter,
IN u8 offset,
@ -1642,7 +1628,6 @@ Efuse_PgPacketWrite_BT(IN PADAPTER pAdapter,
return ret;
}
u8
Efuse_WordEnableDataWrite(IN PADAPTER pAdapter,
IN u16 efuse_addr,
@ -2087,7 +2072,6 @@ efuse_ShadowRead4Byte(
} /* efuse_ShadowRead4Byte */
/*-----------------------------------------------------------------------------
* Function: efuse_ShadowWrite1Byte
* efuse_ShadowWrite2Byte
@ -2135,7 +2119,6 @@ efuse_ShadowWrite2Byte(
PHAL_DATA_TYPE pHalData = GET_HAL_DATA(pAdapter);
pHalData->efuse_eeprom_data[Offset] = Value & 0x00FF;
pHalData->efuse_eeprom_data[Offset + 1] = Value >> 8;
@ -2157,7 +2140,6 @@ efuse_ShadowWrite4Byte(
} /* efuse_ShadowWrite1Byte */
/*-----------------------------------------------------------------------------
* Function: EFUSE_ShadowRead
*
@ -2225,7 +2207,6 @@ EFUSE_ShadowWrite(
if (pAdapter->registrypriv.mp_mode == 0)
return;
if (Type == 1)
efuse_ShadowWrite1Byte(pAdapter, Offset, (u8)Value);
else if (Type == 2)
@ -2344,7 +2325,6 @@ void EFUSE_ShadowMapUpdate(
u8 *efuse_map = NULL;
int err;
mapLen = EEPROM_MAX_SIZE;
efuse_map = pHalData->efuse_eeprom_data;
/* efuse default content is 0xFF */

View File

@ -77,7 +77,6 @@
#endif /* CONFIG_WAPI_SUPPORT */
static const u32 rtw_cipher_suites[] = {
WLAN_CIPHER_SUITE_WEP40,
WLAN_CIPHER_SUITE_WEP104,
@ -196,7 +195,6 @@ static struct ieee80211_channel rtw_5ghz_a_channels[] = {
CHAN5G(216, 0),
};
void rtw_2g_channels_init(struct ieee80211_channel *channels)
{
_rtw_memcpy((void *)channels, (void *)rtw_2ghz_channels,
@ -471,7 +469,6 @@ struct cfg80211_bss *rtw_cfg80211_inform_bss(_adapter *padapter, struct wlan_net
}
/* _exit_critical_bh(&pwdev_priv->scan_req_lock, &irqL); */
channel = pnetwork->network.Configuration.DSConfig;
freq = rtw_ch2freq(channel);
notify_channel = ieee80211_get_channel(wiphy, freq);
@ -524,7 +521,6 @@ struct cfg80211_bss *rtw_cfg80211_inform_bss(_adapter *padapter, struct wlan_net
_rtw_memcpy(pwlanhdr->addr2, pnetwork->network.MacAddress, ETH_ALEN);
_rtw_memcpy(pwlanhdr->addr3, pnetwork->network.MacAddress, ETH_ALEN);
/* pbuf += sizeof(struct rtw_ieee80211_hdr_3addr); */
len = sizeof(struct rtw_ieee80211_hdr_3addr);
_rtw_memcpy((pbuf + len), pnetwork->network.IEs, pnetwork->network.IELength);
@ -754,10 +750,10 @@ void rtw_cfg80211_indicate_connect(_adapter *padapter)
}
check_bss:
if (!rtw_cfg80211_check_bss(padapter))
if (!rtw_cfg80211_check_bss(padapter)){
RTW_PRINT(FUNC_ADPT_FMT" BSS not found !!\n", FUNC_ADPT_ARG(padapter));
if (rtw_to_roam(padapter) > 0) {
}else if (rtw_to_roam(padapter) > 0) {
#if LINUX_VERSION_CODE > KERNEL_VERSION(2, 6, 39) || defined(COMPAT_KERNEL_RELEASE)
struct wiphy *wiphy = pwdev->wiphy;
struct ieee80211_channel *notify_channel;
@ -894,7 +890,6 @@ void rtw_cfg80211_indicate_disconnect(_adapter *padapter, u16 reason, u8 locally
}
}
#ifdef CONFIG_AP_MODE
static int rtw_cfg80211_ap_set_encryption(struct net_device *dev, struct ieee_param *param, u32 param_len)
{
@ -6497,6 +6492,10 @@ static void rtw_cfg80211_preinit_wiphy(_adapter *adapter, struct wiphy *wiphy)
wiphy->bands[IEEE80211_BAND_5GHZ] = rtw_spt_band_alloc(IEEE80211_BAND_5GHZ);
#endif
#if defined(CONFIG_NET_NS)
wiphy->flags |= WIPHY_FLAG_NETNS_OK;
#endif //CONFIG_NET_NS
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 38) && LINUX_VERSION_CODE < KERNEL_VERSION(3, 0, 0))
#if defined(CONFIG_NET_NS)
wiphy->flags |= WIPHY_FLAG_NETNS_OK;
@ -6597,6 +6596,7 @@ static struct cfg80211_ops rtw_cfg80211_ops = {
#if (LINUX_VERSION_CODE < KERNEL_VERSION(3, 6, 0))
.set_channel = cfg80211_rtw_set_channel,
#endif
/* .auth = cfg80211_rtw_auth, */
/* .assoc = cfg80211_rtw_assoc, */
#endif /* CONFIG_AP_MODE */

View File

@ -183,8 +183,6 @@ static void find_ns(struct ieee80211_radiotap_iterator *iterator,
}
}
/**
* ieee80211_radiotap_iterator_next - return next radiotap parser iterator arg
* @iterator: radiotap_iterator to move to next arg (if any)
@ -366,4 +364,3 @@ int rtw_ieee80211_radiotap_iterator_next(
return 0;
}
}

View File

@ -1919,12 +1919,10 @@ static int readFile(struct file *fp, char *buf, int len)
return -EPERM;
while (sum < len) {
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4, 1, 0))
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4, 14, 0))
rlen = kernel_read(fp, buf + sum, len - sum, &fp->f_pos);
#else
#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(4, 1, 0))
rlen = __vfs_read(fp, buf + sum, len - sum, &fp->f_pos);
#endif
#else
rlen = fp->f_op->read(fp, buf + sum, len - sum, &fp->f_pos);
#endif