Skip to content

Commit

Permalink
Merge tag 'wireless-drivers-next-for-davem-2017-08-28' of git://git.k…
Browse files Browse the repository at this point in the history
…ernel.org/pub/scm/linux/kernel/git/kvalo/wireless-drivers-next

Kalle Valo says:

====================
wireless-drivers-next patches for 4.14

rsi driver is getting a lot of new features lately, but as usual
active development happening on iwlwifi as well as other drivers.

I pulled wireless-drivers to fix multiple conflicts in iwlwifi and to
make it easier further development.

Major changes:

ath10k

* initial UBS bus support (no full support yet)

* add tdls support for 10.4 firmware

ath9k

* add Dell Wireless 1802

wil6210

* support FW RSSI reporting

rsi

* support legacy power save, U-APSD, rf-kill and AP mode

* RTS threshold configuration

brcmfmac

* support CYW4373 SDIO/USB chipset

iwlwifi

* some more code moved to a new directory

* add new PCI ID for 7265D
====================

Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
davem330 committed Aug 29, 2017
2 parents 22eac91 + 5307eca commit 7619de8
Show file tree
Hide file tree
Showing 127 changed files with 4,310 additions and 1,272 deletions.
9 changes: 2 additions & 7 deletions drivers/bcma/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,8 @@ config BCMA_POSSIBLE
depends on HAS_IOMEM && HAS_DMA
default y

menu "Broadcom specific AMBA"
depends on BCMA_POSSIBLE

config BCMA
tristate "BCMA support"
menuconfig BCMA
tristate "Broadcom specific AMBA"
depends on BCMA_POSSIBLE
help
Bus driver for Broadcom specific Advanced Microcontroller Bus
Expand Down Expand Up @@ -117,5 +114,3 @@ config BCMA_DEBUG
This turns on additional debugging messages.

If unsure, say N

endmenu
2 changes: 1 addition & 1 deletion drivers/net/wireless/ath/ar5523/ar5523.c
Original file line number Diff line number Diff line change
Expand Up @@ -1749,7 +1749,7 @@ static void ar5523_disconnect(struct usb_interface *intf)
{ USB_DEVICE((vendor), (device) + 1), \
.driver_info = AR5523_FLAG_ABG|AR5523_FLAG_PRE_FIRMWARE }

static struct usb_device_id ar5523_id_table[] = {
static const struct usb_device_id ar5523_id_table[] = {
AR5523_DEVICE_UG(0x168c, 0x0001), /* Atheros / AR5523 */
AR5523_DEVICE_UG(0x0cf3, 0x0001), /* Atheros2 / AR5523_1 */
AR5523_DEVICE_UG(0x0cf3, 0x0003), /* Atheros2 / AR5523_2 */
Expand Down
7 changes: 7 additions & 0 deletions drivers/net/wireless/ath/ath10k/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,13 @@ config ATH10K_SDIO
This module adds experimental support for SDIO/MMC bus. Currently
work in progress and will not fully work.

config ATH10K_USB
tristate "Atheros ath10k USB support (EXPERIMENTAL)"
depends on ATH10K && USB
---help---
This module adds experimental support for USB bus. Currently
work in progress and will not fully work.

config ATH10K_DEBUG
bool "Atheros ath10k debugging"
depends on ATH10K
Expand Down
3 changes: 3 additions & 0 deletions drivers/net/wireless/ath/ath10k/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,8 @@ ath10k_pci-$(CONFIG_ATH10K_AHB) += ahb.o
obj-$(CONFIG_ATH10K_SDIO) += ath10k_sdio.o
ath10k_sdio-y += sdio.o

obj-$(CONFIG_ATH10K_USB) += ath10k_usb.o
ath10k_usb-y += usb.o

# for tracing framework to find trace.h
CFLAGS_trace.o := -I$(src)
15 changes: 10 additions & 5 deletions drivers/net/wireless/ath/ath10k/ahb.c
Original file line number Diff line number Diff line change
Expand Up @@ -197,35 +197,40 @@ static int ath10k_ahb_rst_ctrl_init(struct ath10k *ar)

dev = &ar_ahb->pdev->dev;

ar_ahb->core_cold_rst = devm_reset_control_get(dev, "wifi_core_cold");
ar_ahb->core_cold_rst = devm_reset_control_get_exclusive(dev,
"wifi_core_cold");
if (IS_ERR(ar_ahb->core_cold_rst)) {
ath10k_err(ar, "failed to get core cold rst ctrl: %ld\n",
PTR_ERR(ar_ahb->core_cold_rst));
return PTR_ERR(ar_ahb->core_cold_rst);
}

ar_ahb->radio_cold_rst = devm_reset_control_get(dev, "wifi_radio_cold");
ar_ahb->radio_cold_rst = devm_reset_control_get_exclusive(dev,
"wifi_radio_cold");
if (IS_ERR(ar_ahb->radio_cold_rst)) {
ath10k_err(ar, "failed to get radio cold rst ctrl: %ld\n",
PTR_ERR(ar_ahb->radio_cold_rst));
return PTR_ERR(ar_ahb->radio_cold_rst);
}

ar_ahb->radio_warm_rst = devm_reset_control_get(dev, "wifi_radio_warm");
ar_ahb->radio_warm_rst = devm_reset_control_get_exclusive(dev,
"wifi_radio_warm");
if (IS_ERR(ar_ahb->radio_warm_rst)) {
ath10k_err(ar, "failed to get radio warm rst ctrl: %ld\n",
PTR_ERR(ar_ahb->radio_warm_rst));
return PTR_ERR(ar_ahb->radio_warm_rst);
}

ar_ahb->radio_srif_rst = devm_reset_control_get(dev, "wifi_radio_srif");
ar_ahb->radio_srif_rst = devm_reset_control_get_exclusive(dev,
"wifi_radio_srif");
if (IS_ERR(ar_ahb->radio_srif_rst)) {
ath10k_err(ar, "failed to get radio srif rst ctrl: %ld\n",
PTR_ERR(ar_ahb->radio_srif_rst));
return PTR_ERR(ar_ahb->radio_srif_rst);
}

ar_ahb->cpu_init_rst = devm_reset_control_get(dev, "wifi_cpu_init");
ar_ahb->cpu_init_rst = devm_reset_control_get_exclusive(dev,
"wifi_cpu_init");
if (IS_ERR(ar_ahb->cpu_init_rst)) {
ath10k_err(ar, "failed to get cpu init rst ctrl: %ld\n",
PTR_ERR(ar_ahb->cpu_init_rst));
Expand Down
10 changes: 10 additions & 0 deletions drivers/net/wireless/ath/ath10k/core.c
Original file line number Diff line number Diff line change
Expand Up @@ -1454,6 +1454,7 @@ static void ath10k_core_get_fw_name(struct ath10k *ar, char *fw_name,
{
switch (ar->hif.bus) {
case ATH10K_BUS_SDIO:
case ATH10K_BUS_USB:
scnprintf(fw_name, fw_name_len, "%s-%s-%d.bin",
ATH10K_FW_FILE_BASE, ath10k_bus_str(ar->hif.bus),
fw_api);
Expand Down Expand Up @@ -1885,6 +1886,7 @@ static int ath10k_core_init_firmware_features(struct ath10k *ar)
ar->fw_stats_req_mask = WMI_10_4_STAT_PEER |
WMI_10_4_STAT_PEER_EXTD;
ar->max_spatial_stream = ar->hw_params.max_spatial_stream;
ar->max_num_tdls_vdevs = TARGET_10_4_NUM_TDLS_VDEVS;

if (test_bit(ATH10K_FW_FEATURE_PEER_FLOW_CONTROL,
fw_file->fw_features))
Expand Down Expand Up @@ -2123,6 +2125,14 @@ int ath10k_core_start(struct ath10k *ar, enum ath10k_firmware_mode mode,
ar->running_fw->fw_file.fw_features))
val |= WMI_10_4_COEX_GPIO_SUPPORT;

if (test_bit(WMI_SERVICE_TDLS_EXPLICIT_MODE_ONLY,
ar->wmi.svc_map))
val |= WMI_10_4_TDLS_EXPLICIT_MODE_ONLY;

if (test_bit(WMI_SERVICE_TDLS_UAPSD_BUFFER_STA,
ar->wmi.svc_map))
val |= WMI_10_4_TDLS_UAPSD_BUFFER_STA;

status = ath10k_mac_ext_resource_config(ar, val);
if (status) {
ath10k_err(ar,
Expand Down
5 changes: 5 additions & 0 deletions drivers/net/wireless/ath/ath10k/core.h
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@ enum ath10k_bus {
ATH10K_BUS_PCI,
ATH10K_BUS_AHB,
ATH10K_BUS_SDIO,
ATH10K_BUS_USB,
};

static inline const char *ath10k_bus_str(enum ath10k_bus bus)
Expand All @@ -103,6 +104,8 @@ static inline const char *ath10k_bus_str(enum ath10k_bus bus)
return "ahb";
case ATH10K_BUS_SDIO:
return "sdio";
case ATH10K_BUS_USB:
return "usb";
}

return "unknown";
Expand Down Expand Up @@ -993,6 +996,8 @@ struct ath10k {
u32 reg_ack_cts_timeout_orig;
} fw_coverage;

u32 ampdu_reference;

void *ce_priv;

/* must be last */
Expand Down
2 changes: 2 additions & 0 deletions drivers/net/wireless/ath/ath10k/debug.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ enum ath10k_debug_mask {
ATH10K_DBG_AHB = 0x00008000,
ATH10K_DBG_SDIO = 0x00010000,
ATH10K_DBG_SDIO_DUMP = 0x00020000,
ATH10K_DBG_USB = 0x00040000,
ATH10K_DBG_USB_BULK = 0x00080000,
ATH10K_DBG_ANY = 0xffffffff,
};

Expand Down
12 changes: 11 additions & 1 deletion drivers/net/wireless/ath/ath10k/htt_rx.c
Original file line number Diff line number Diff line change
Expand Up @@ -890,16 +890,26 @@ static void ath10k_htt_rx_h_ppdu(struct ath10k *ar,
status->nss = 0;
status->encoding = RX_ENC_LEGACY;
status->bw = RATE_INFO_BW_20;

status->flag &= ~RX_FLAG_MACTIME_END;
status->flag |= RX_FLAG_NO_SIGNAL_VAL;

status->flag &= ~(RX_FLAG_AMPDU_IS_LAST);
status->flag |= RX_FLAG_AMPDU_DETAILS | RX_FLAG_AMPDU_LAST_KNOWN;
status->ampdu_reference = ar->ampdu_reference;

ath10k_htt_rx_h_signal(ar, status, rxd);
ath10k_htt_rx_h_channel(ar, status, rxd, vdev_id);
ath10k_htt_rx_h_rates(ar, status, rxd);
}

if (is_last_ppdu)
if (is_last_ppdu) {
ath10k_htt_rx_h_mactime(ar, status, rxd);

/* set ampdu last segment flag */
status->flag |= RX_FLAG_AMPDU_IS_LAST;
ar->ampdu_reference++;
}
}

static const char * const tid_to_ac[] = {
Expand Down
5 changes: 5 additions & 0 deletions drivers/net/wireless/ath/ath10k/hw.h
Original file line number Diff line number Diff line change
Expand Up @@ -720,6 +720,11 @@ ath10k_rx_desc_get_l3_pad_bytes(struct ath10k_hw_params *hw,
#define TARGET_10_4_IPHDR_PAD_CONFIG 1
#define TARGET_10_4_QWRAP_CONFIG 0

/* TDLS config */
#define TARGET_10_4_NUM_TDLS_VDEVS 1
#define TARGET_10_4_NUM_TDLS_BUFFER_STA 1
#define TARGET_10_4_NUM_TDLS_SLEEP_STA 1

/* Maximum number of Copy Engine's supported */
#define CE_COUNT_MAX 12

Expand Down
5 changes: 4 additions & 1 deletion drivers/net/wireless/ath/ath10k/mac.c
Original file line number Diff line number Diff line change
Expand Up @@ -8197,8 +8197,11 @@ int ath10k_mac_register(struct ath10k *ar)
NL80211_PROBE_RESP_OFFLOAD_SUPPORT_P2P;
}

if (test_bit(WMI_SERVICE_TDLS, ar->wmi.svc_map))
if (test_bit(WMI_SERVICE_TDLS, ar->wmi.svc_map) ||
test_bit(WMI_SERVICE_TDLS_EXPLICIT_MODE_ONLY, ar->wmi.svc_map)) {
ar->hw->wiphy->flags |= WIPHY_FLAG_SUPPORTS_TDLS;
ieee80211_hw_set(ar->hw, TDLS_WIDER_BW);
}

ar->hw->wiphy->flags |= WIPHY_FLAG_HAS_REMAIN_ON_CHANNEL;
ar->hw->wiphy->flags |= WIPHY_FLAG_HAS_CHANNEL_SWITCH;
Expand Down
8 changes: 4 additions & 4 deletions drivers/net/wireless/ath/ath10k/sdio.c
Original file line number Diff line number Diff line change
Expand Up @@ -683,7 +683,7 @@ static int ath10k_sdio_mbox_rxmsg_pending_handler(struct ath10k *ar,
lookaheads[0] = msg_lookahead;

timeout = jiffies + SDIO_MBOX_PROCESSING_TIMEOUT_HZ;
while (time_before(jiffies, timeout)) {
do {
/* Try to allocate as many HTC RX packets indicated by
* n_lookaheads.
*/
Expand Down Expand Up @@ -719,7 +719,7 @@ static int ath10k_sdio_mbox_rxmsg_pending_handler(struct ath10k *ar,
* performance in high throughput situations.
*/
*done = false;
}
} while (time_before(jiffies, timeout));

if (ret && (ret != -ECANCELED))
ath10k_warn(ar, "failed to get pending recv messages: %d\n",
Expand Down Expand Up @@ -1336,11 +1336,11 @@ static void ath10k_sdio_irq_handler(struct sdio_func *func)
sdio_release_host(ar_sdio->func);

timeout = jiffies + ATH10K_SDIO_HIF_COMMUNICATION_TIMEOUT_HZ;
while (time_before(jiffies, timeout) && !done) {
do {
ret = ath10k_sdio_mbox_proc_pending_irqs(ar, &done);
if (ret)
break;
}
} while (time_before(jiffies, timeout) && !done);

sdio_claim_host(ar_sdio->func);

Expand Down
Loading

0 comments on commit 7619de8

Please sign in to comment.