ath10k: rename debug_mask

Rename debug_mask variable to ath10k_debug_mask. Fixes a linker error:

drivers/net/wireless/ath/ath10k/built-in.o: In function `ath10k_add_interface':
/home/kvalo/ath10k/src/ath10k/drivers/net/wireless/ath/ath10k/mac.c:1710:
	multiple definition of `debug_mask'
drivers/net/wireless/ath/ath6kl/built-in.o:/home/kvalo/ath10k/src/ath10k/include/linux/list.h:188:
	first defined here

This changes just the variable, the name of kernel module parameters
stays the same.

Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
ath10k: rename ath10k_p2p module parameter to p2p

AFAICS there's no need to have the ath10k_ prefix in p2p
kernel module parameter so remove that. The name of
the actual variable in code stays the same, ath10k_p2p.

Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
ath10k: use data_lock to protect {scan, rx}_channel

We used RCU in a funky way.

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
ath10k: simplify scan event locking

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
ath10k: increase scan timeout

We can't use the max scan time as the timeout
itself. We must account for various overheads (ie.
command/event processing).

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
ath10k: wait for remain on channel chan switch

We didn't wait for scan channel change event so we
could end up sending frames to a different
channel.

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
ath10k: abort scan if start completion never came

Abort the scan just in case FW has hung
temporarily.

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
ath10k: add error handling to some functions

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
ath10k: remove unnecessary check

rx skbuff is never NULL.

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
ath10k: remove unnecessary prints

Error codes are already propagated and printed.

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
ath10k: cleanup warning/error prints

Gets rid of __func__ usage except debug prints.

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
ath10k: move htc creation error handling

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
ath10k: cleanup pci suspend

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
ath10k: use ath10k_err for non-recoverable failures

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
ath10k: avoid infinite loop

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
ath10k: fix htt debug flag

Use HTT_DUMP for tx frag/msdu.

Signed-off-by: Bartosz Markowski <bartosz.markowski@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
ath10k: fix possible htt rx memleak

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
ath10k: fix rx descriptor definition

Fortunately we don't use these fields but it's
good to have them defined correctly.

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>