[PATCH] staging: vt6655: Fix interrupt race condition on device start up.

2019-03-24 Thread Malcolm Priestley
device doesn't keep polling the system while the workqueue is being processed. Signed-off-by: Malcolm Priestley CC: sta...@vger.kernel.org # v4.2+ --- drivers/staging/vt6655/device_main.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/staging/v

[PATCH] staging: vt6655: Remove vif check from vnt_interrupt

2019-03-27 Thread Malcolm Priestley
A check for vif is made in vnt_interrupt_work. There is a small chance of leaving interrupt disabled while vif is NULL and the work hasn't been scheduled. Signed-off-by: Malcolm Priestley CC: sta...@vger.kernel.org # v4.2+ --- drivers/staging/vt6655/device_main.c | 3 +-- 1 file chang

Re: [PATCH] staging: vt6655: fix sparse warning: argument type

2014-12-21 Thread Malcolm Priestley
On 21/12/14 08:17, Jeremiah Mahler wrote: Eddie, all, On Sat, Dec 20, 2014 at 10:27:55PM -0700, Eddie Kovsky wrote: Fixes following warning generated by sparse: drivers/staging/vt6655/baseband.c:2180:45: warning: incorrect type in argument 1 (different address spaces) drivers/staging/vt6655/b

Re: [PATCH] staging: vt6655: fix sparse warnings: incorrect argument type

2014-12-21 Thread Malcolm Priestley
On 21/12/14 13:56, Mike Krinkin wrote: this patch fixes following sparse warnings: drivers/staging/vt6655/device_main.c:1503:25: warning: incorrect type in argument 1 (different address spaces) drivers/staging/vt6655/device_main.c:1503:25:expected void [noderef] * drivers/staging/vt6655/

Re: [PATCH] Staging: vt6656: Checkpatch fix: else after break or return

2015-01-11 Thread Malcolm Priestley
On 11/01/15 16:42, Joe Perches wrote: On Mon, 2015-01-12 at 03:19 +1100, Emrys Bayliss wrote: This patch fixes the following checkpatch.pl error: rxtx.c:588: WARNING: else is not generally useful after a break or return Signed-off-by: Emrys Bayliss --- drivers/staging/vt6656/rxtx.c | 6 +--

[PATCH 2/5] staging: vt6656: correct return of vnt_init_registers.

2019-12-20 Thread Malcolm Priestley
The driver standard error returns remove bool false conditions. Cc: stable # v5.3+ Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/main_usb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/vt6656/main_usb.c b/drivers/staging/vt6656/main_usb.c

[PATCH 1/5] staging: vt6656: Fix non zero logical return of, usb_control_msg

2019-12-20 Thread Malcolm Priestley
ormal operation causes errors. Correct the return function so only return zero when transfer is successful. Cc: stable # v5.3+ Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/usbpipe.c | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/drivers/staging/vt6

[PATCH 3/5] staging: vt6656: limit reg output to block size

2019-12-20 Thread Malcolm Priestley
+ Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/baseband.c | 4 ++-- drivers/staging/vt6656/usbpipe.c | 17 + drivers/staging/vt6656/usbpipe.h | 5 + 3 files changed, 24 insertions(+), 2 deletions(-) diff --git a/drivers/staging/vt6656/baseband.c b/drivers

[PATCH 4/5] staging: vt6656: remove bool from vnt_radio_power_on ret

2019-12-20 Thread Malcolm Priestley
The driver uses logical only error checking a bool true would flag error. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/card.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/vt6656/card.c b/drivers/staging/vt6656/card.c index 56cd77fd9ea0

[PATCH 5/5] staging: vt6656: set usb_set_intfdata on driver fail.

2019-12-20 Thread Malcolm Priestley
intfdata will contain stale pointer when the device is detached after failed initialization when referenced in vt6656_disconnect Provide driver access to it here and NULL it. Cc: stable Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/device.h | 1 + drivers/staging/vt6656

[PATCH 1/4] staging: vt6656: correct packet types for CTS protect, mode.

2020-01-08 Thread Malcolm Priestley
otherwise transmit packets as PK_TYPE_11A. Cc: stable Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/device.h | 2 ++ drivers/staging/vt6656/rxtx.c | 12 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/drivers/staging/vt6656/device.h b/drivers/staging

[PATCH 4/4] staging: vt6656: Move ieee80211_rx_status off stack.

2020-01-08 Thread Malcolm Priestley
ieee80211_rx_status off stack to IEEE80211_SKB_RXCB (skb->cb) removing the need to copy on to it. skb->cb is always present as a clean buffer so simply fill it in. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/dpc.c | 21 ++--- 1 file changed, 10 inse

[PATCH 2/4] staging: vt6656: use NULLFUCTION stack on mac80211

2020-01-08 Thread Malcolm Priestley
ff-by: Malcolm Priestley --- drivers/staging/vt6656/main_usb.c | 1 + drivers/staging/vt6656/rxtx.c | 14 +- 2 files changed, 6 insertions(+), 9 deletions(-) diff --git a/drivers/staging/vt6656/main_usb.c b/drivers/staging/vt6656/main_usb.c index 9cb924c54571..5e48b3ddb94c 100644

[PATCH 3/4] staging: vt6656: Fix false Tx excessive retries reporting.

2020-01-08 Thread Malcolm Priestley
The driver reporting IEEE80211_TX_STAT_ACK is not being handled correctly. The driver should only report on TSR_TMO flag is not set indicating no transmission errors and when not IEEE80211_TX_CTL_NO_ACK is being requested. Cc: stable Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656

Re: [PATCH 1/5] staging: vt6656: Fix non zero logical return of, usb_control_msg

2020-01-08 Thread Malcolm Priestley
On 06/01/2020 21:45, Quentin Deslandes wrote: > On 01/03/20 13:58:08, Dan Carpenter wrote: >> On Fri, Dec 20, 2019 at 09:14:59PM +, Malcolm Priestley wrote: >>> Starting with commit 59608cb1de1856 >>> ("staging: vt6656: clean function's error path in usbp

[PATCH 1/5] staging: vt6656: Simplify RX finding bit rates

2020-01-19 Thread Malcolm Priestley
The bit rate can be found by multiplying the rate value by 5. Use rx_bitrate to compared to sband bitrates removing the need to find it by hw_value. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/device.h | 1 - drivers/staging/vt6656/dpc.c| 21 ++--- 2 files

[PATCH 2/5] staging: vt6656: create vnt rx header for sk_buff.

2020-01-19 Thread Malcolm Priestley
vnt_rx_header contains the structure of the original variables wbk_status, rx_sts, rx_rate and pay_load_len packed. Replace all the old variables for the ones in this. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/device.h | 7 +++ drivers/staging/vt6656/dpc.c| 29

[PATCH 3/5] staging: vt6656: Use vnt_rx_tail struct for tail variables.

2020-01-19 Thread Malcolm Priestley
Place tsf_time, sq, new_rsr, rssi, rsr and sq3 packed in the structure. Unused variables are removed along with skb_data and structure is placed beyond vnt_rx_header + pay_load_with_padding on skb->data. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/device.h |

[PATCH 5/5] staging: vt6656: Remove memory buffer from vnt_download_firmware.

2020-01-19 Thread Malcolm Priestley
The memory buffer is being done twice here as vnt_control_out passes it straight to kmemdup. Remove buffer and add const to the variable in vnt_control_out to pass the pointer to it. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/firmware.c | 14 ++ drivers/staging

[PATCH 4/5] staging: vt6656: Just check NEWRSR_DECRYPTOK for RX_FLAG_DECRYPTED.

2020-01-19 Thread Malcolm Priestley
At present the driver does a number of checks for RX_FLAG_DECRYPTED. Remove all these and just pass check NEWRSR_DECRYPTOK mac80211 will handle the processing of the sk_buff and dispose of it. This means that mac80211 can do unsupported encryption modes on stack. Signed-off-by: Malcolm

[PATCH 1/2] staging: vt6656: fix sign of rx_dbm to bb_pre_ed_rssi.

2020-02-02 Thread Malcolm Priestley
bb_pre_ed_rssi is an u8 rx_dm always returns negative signed values add minus operator to always yield positive. fixes issue where rx sensitivity is always set to maximum because the unsigned numbers were always greater then 100. Cc: stable Signed-off-by: Malcolm Priestley --- drivers/staging

[PATCH 2/2] staging: vt6656: Fix return for unsupported cipher modes.

2020-02-02 Thread Malcolm Priestley
mac80211 expect to see -EOPNOTSUPP on unsupported ciphers so these can be done on stack. correct all the returns to do this. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/key.c | 5 - drivers/staging/vt6656/main_usb.c | 4 +--- 2 files changed, 5 insertions(+), 4

[PATCH 1/2] staging: vt6656: Disable and remove fall back rates from driver.

2020-02-02 Thread Malcolm Priestley
The fall back rates are not properly implemented in driver and form part of the legacy driver. mac80211 has no indication that this is happening and it does appear the driver does function considerably better without them so remove them. Signed-off-by: Malcolm Priestley --- drivers/staging

[PATCH 2/2] staging: vt6656: Remove fall back functions and headers.

2020-02-02 Thread Malcolm Priestley
Fall back is no longer used in driver so remove all functions and headers. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/device.h | 1 - drivers/staging/vt6656/rxtx.c | 206 drivers/staging/vt6656/rxtx.h | 60 -- 3 files changed, 267

[PATCH v2 1/2] staging: vt6656: fix sign of rx_dbm to bb_pre_ed_rssi.

2020-02-04 Thread Malcolm Priestley
reate rx function.") Cc: stable Signed-off-by: Malcolm Priestley --- Added fixes tag drivers/staging/vt6656/dpc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/vt6656/dpc.c b/drivers/staging/vt6656/dpc.c index 821aae8ca402..a0b60e7d1086 100644 ---

Re: [PATCH 1/2] staging: vt6656: fix sign of rx_dbm to bb_pre_ed_rssi.

2020-02-04 Thread Malcolm Priestley
On 03/02/2020 09:42, Dan Carpenter wrote: > On Sun, Feb 02, 2020 at 12:27:25PM +0000, Malcolm Priestley wrote: >> bb_pre_ed_rssi is an u8 rx_dm always returns negative signed >> values add minus operator to always yield positive. >> >> fixes issue where rx sensitivi

[PATCH] staging: vt6656: Use mac80211 duration for tx headers

2020-02-27 Thread Malcolm Priestley
mac80211 already provides the correct duration simply copy it to the tx headers removing the need for driver to find it with vnt_get_duration_le. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/rxtx.c | 57 +-- 1 file changed, 8 insertions(+), 49

[PATCH] staging: vt6656: Remove STATUS enums from TX path

2020-02-29 Thread Malcolm Priestley
Returning standard error code or status variable. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/device.h | 9 - drivers/staging/vt6656/rxtx.c| 4 ++-- drivers/staging/vt6656/usbpipe.c | 5 ++--- 3 files changed, 4 insertions(+), 14 deletions(-) diff --git a/drivers

[PATCH 1/2] staging: vt6656: use vnt_vt3184_agc array directly

2020-02-29 Thread Malcolm Priestley
vnt_vt3184_agc is always the same regardless of rf type so use the array directly removing from stack buffer. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/baseband.c | 15 ++- 1 file changed, 2 insertions(+), 13 deletions(-) diff --git a/drivers/staging/vt6656

[PATCH 2/2] staging: vt6656: vnt_vt3184_init remove stack copy to array.

2020-02-29 Thread Malcolm Priestley
use u8 pointer addr directly and remove stack array. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/baseband.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/drivers/staging/vt6656/baseband.c b/drivers/staging/vt6656/baseband.c index 48a624bf00c0

[PATCH 1/3] staging: vt6656: vnt_int_start_interrupt remove spin lock.

2020-03-02 Thread Malcolm Priestley
This formed part of the legacy driver and potentially multi users. The driver now has only one user mac80211 remove this lock. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/int.c | 5 - 1 file changed, 5 deletions(-) diff --git a/drivers/staging/vt6656/int.c b/drivers

PATCH 2/3] staging: vt6656: Remove function vnt_int_process_data.

2020-03-02 Thread Malcolm Priestley
call vnt_start_interrupt_urb directly from vnt_start. Move debug message to vnt_start_interrupt_urb. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/int.c | 11 --- drivers/staging/vt6656/int.h | 1 - drivers/staging/vt6656/main_usb.c | 2 +- drivers/staging

[PATCH 3/3] staging: vt6656: Delete int.c/h file and move functions to usbpipe

2020-03-02 Thread Malcolm Priestley
Move functions vnt_int_process_data and vnt_int_report_rate to usbpipe.c and vnt_interrupt_data to usbpipe.h These form part of the USB structure. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/Makefile | 3 +- drivers/staging/vt6656/int.c | 110

[PATCH] staging: vt6656: Move vnt_rx_data to usbpipe.c

2020-03-03 Thread Malcolm Priestley
vnt_rx_data is a USB function and vnt_submit_rx_urb_complete is the only caller therefore removing dpc.c/h files and becoming static. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/Makefile | 1 - drivers/staging/vt6656/dpc.c | 124 -- drivers

[PATCH 1/2] staging: vt6656: Remove vnt_interrupt_buffer in_use flag.

2020-03-04 Thread Malcolm Priestley
mac80211 is the only user of in_use to start it and should not be true when so. So internal toggling of this variable is not relevant. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/device.h | 1 - drivers/staging/vt6656/usbpipe.c | 28 +++- 2 files

[PATCH 2/2] staging: vt6656: struct vnt_rcb remove unused in_use.

2020-03-04 Thread Malcolm Priestley
The variable merely toggles true to false and is unused. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/device.h | 1 - drivers/staging/vt6656/main_usb.c | 3 --- drivers/staging/vt6656/usbpipe.c | 16 +++- 3 files changed, 3 insertions(+), 17 deletions(-) diff

Re: [PATCH] staging: vt6656: Use BIT_ULL() macro instead of bit shift operation

2020-03-08 Thread Malcolm Priestley
>>> */ >>> #undef __NO_VERSION__ >>> >>> +#include >>> #include >>> #include >>> #include "device.h" >>> @@ -802,8 +803,7 @@ static u64 vnt_prepare_multicast(struct ieee80211_hw >>> *hw, >>> >>> netdev_hw_addr_list_for_each(ha, mc_list) { >>> bit_nr = ether_crc(ETH_ALEN, h

Re: [Outreachy kernel] [PATCH v4] staging: vt6656: add error code handling to unused variable

2020-03-30 Thread Malcolm Priestley
but to date this is not known to fail with the hardware I have used. No problems with hardware with this patch. Tested-by: Malcolm Priestley ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

Re: [PATCH] staging: vt6656: Use defines in vnt_mac_reg_bits_* functions

2020-04-02 Thread Malcolm Priestley
On 02/04/2020 10:19, Quentin Deslandes wrote: On 04/01/20 18:55:38, Oscar Carter wrote: On Tue, Mar 31, 2020 at 01:29:06PM +0300, Dan Carpenter wrote: On Sat, Mar 28, 2020 at 10:54:33AM +0100, Oscar Carter wrote: Define the necessary bits in the CHANNEL, PAPEDELAY and GPIOCTL0 registers to

[PATCH] staging: vt6656: replace al2230_power_table array with formula.

2020-04-02 Thread Malcolm Priestley
The power table can replaced with calculation 0x0404090 | (power << 12) removing array and length macro. variable power never goes beyond the maximum setting. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/rf.c | 79 ++--- 1 file chan

[PATCH 1/2] staging: vt6656: set all ofdm rates to default

2020-04-02 Thread Malcolm Priestley
mac80211 rate control decides which odfm rates to use so all of them should be set enabled at the appropriate bit rate. This means vnt_get_ofdm_rate is no longer required. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/card.c | 54 +++ 1 file

[PATCH 2/2] staging: vt6656: set all cck rates to default.

2020-04-02 Thread Malcolm Priestley
mac80211 rate control decides which cck rates to use so all of them should be set enabled at the appropriate bit rate. This means vnt_get_cck_rate is no longer required. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/card.c | 38 --- 1 file changed

[PATCH 1/2] staging: vt6556: vnt_rf_setpower convert to use ieee80211_channel.

2020-04-06 Thread Malcolm Priestley
ieee80211_channel contains all the necessary information to change power according to tx mode required. vnt_rf_setpower is moved and so that vnt_rf_set_txpower the only caller becomes static. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/main_usb.c | 16 ++- drivers/staging

[PATCH 2/2] staging: vt6656: rxtx remove rate change and current_rate.

2020-04-06 Thread Malcolm Priestley
There is no longer any need to change power in vnt_tx_packet. Remove current_rate in vnt_tx_packet and struct vnt_private as it is no longer used elsewhere. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/device.h | 1 - drivers/staging/vt6656/rxtx.c | 15 --- 2

Re: [PATCH 1/2] staging: vt6556: vnt_rf_setpower convert to use ieee80211_channel.

2020-04-06 Thread Malcolm Priestley
Drop these patches I have just noticed a mistake. Regards Malcolm ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

[PATCH 1/2 v2] staging: vt6556: vnt_rf_setpower convert to use ieee80211_channel.

2020-04-06 Thread Malcolm Priestley
ieee80211_channel contains all the necessary information to change power according to tx mode required. vnt_rf_setpower is moved and so that vnt_rf_set_txpower the only caller becomes static. Signed-off-by: Malcolm Priestley --- v2 ARRAY_SIZE(priv->ofdm_pwr_tbl) pointing to wrong ar

[PATCH 2/2 v2] staging: vt6656: rxtx remove rate change and current_rate.

2020-04-06 Thread Malcolm Priestley
There is no longer any need to change power in vnt_tx_packet. Remove current_rate in vnt_tx_packet and struct vnt_private as it is no longer used elsewhere. Signed-off-by: Malcolm Priestley --- v2 Patch 1 had wrong array. drivers/staging/vt6656/device.h | 1 - drivers/staging/vt6656/rxtx.c

Re: [PATCH 1/2] staging: vt6656: Refactor the assignment of the phy->signal variable

2020-04-10 Thread Malcolm Priestley
On 10/04/2020 12:28, Oscar Carter wrote: Create a constant array with the values of the "phy->signal" for every rate. Remove all "phy->signal" assignments inside the switch statement and replace these with a single reading from the new vnt_phy_signal array. Signed-off-by: Oscar Carter ---

Re: [PATCH 1/2] staging: vt6656: Refactor the assignment of the phy->signal variable

2020-04-10 Thread Malcolm Priestley
On 10/04/2020 16:59, Oscar Carter wrote: On Fri, Apr 10, 2020 at 04:37:59PM +0100, Malcolm Priestley wrote: On 10/04/2020 12:28, Oscar Carter wrote: Create a constant array with the values of the "phy->signal" for every rate. Remove all "phy->signal" ass

[PATCH] staging: vt6656: formulate rspinf values into tables

2020-04-11 Thread Malcolm Priestley
: Malcolm Priestley --- drivers/staging/vt6656/card.c | 196 +++--- 1 file changed, 40 insertions(+), 156 deletions(-) diff --git a/drivers/staging/vt6656/card.c b/drivers/staging/vt6656/card.c index 82c775bd20d2..dedb343f3ef3 100644 --- a/drivers/staging/vt6656/card.c +++ b

[PATCH v2] staging: vt6656: formulate rspinf values into tables

2020-04-12 Thread Malcolm Priestley
: Malcolm Priestley --- v1 has error in vnt_rspinf_a_table. drivers/staging/vt6656/card.c | 196 +++--- 1 file changed, 40 insertions(+), 156 deletions(-) diff --git a/drivers/staging/vt6656/card.c b/drivers/staging/vt6656/card.c index 82c775bd20d2..dedb343f3ef3 100644

Re: [PATCH] staging: vt6656: formulate rspinf values into tables

2020-04-12 Thread Malcolm Priestley
Drop this patch v2 sent Regards Malcolm ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

[PATCH] staging: vt6656: Power save stop wake_up_count wrap around.

2020-04-14 Thread Malcolm Priestley
") Cc: stable Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/usbpipe.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/staging/vt6656/usbpipe.c b/drivers/staging/vt6656/usbpipe.c index eae211e5860f..91b62c3dff7b 100644 --- a/drivers/staging/vt6656

[PATCH] staging: vt6656: Don't set RCR_MULTICAST or RCR_BROADCAST by default.

2020-04-18 Thread Malcolm Priestley
ble Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/main_usb.c | 8 ++-- 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/drivers/staging/vt6656/main_usb.c b/drivers/staging/vt6656/main_usb.c index 3c76d3cb5bbe..b2729d5eadfb 100644 --- a/drivers/staging/vt6656/m

[PATCH] staging: vt6656: Fix drivers TBTT timing counter.

2020-04-18 Thread Malcolm Priestley
The drivers TBTT counter is not synchronized with mac80211 timestamp. Reorder the functions and use vnt_update_next_tbtt to do the final synchronize. Fixes: c15158797df6 ("staging: vt6656: implement TSF counter") Cc: stable Signed-off-by: Malcolm Priestley --- drivers/stag

[PATCH ] staging: vt6656: Fix calling conditions of vnt_set_bss_mode

2020-04-18 Thread Malcolm Priestley
("staging: vt6656: Only call vnt_set_bss_mode on basic rates change.") Cc: stable Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/main_usb.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/staging/vt6656/main_usb.c b/drivers/stag

[PATCH ] staging: vt6656: Fix calling conditions of vnt_set_bss_mode

2020-04-18 Thread Malcolm Priestley
("staging: vt6656: Only call vnt_set_bss_mode on basic rates change.") Cc: stable Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/main_usb.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/staging/vt6656/main_usb.c b/drivers/stag

Re: [PATCH ] staging: vt6656: Fix calling conditions of vnt_set_bss_mode

2020-04-18 Thread Malcolm Priestley
Sorry this was sent twice gmail reported the first one failed. Regards Maloclm ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

Re: [PATCH 2/2] staging: vt6656: Fix functions' documentation

2020-04-18 Thread Malcolm Priestley
Actually I don't really think the function descriptions are needed at all the names of the functions are enough. card.c needs to be removed the bss callers to baseband.c, the tbtt's to power.c and the rest to mac.c Regards Malcolm ___ devel mailing lis

[PATCH] staging: vt6656: Fix pairwise key entry save.

2020-04-18 Thread Malcolm Priestley
using vnt_mac_disable_keyentry. Fixes: f9ef05ce13e4 ("staging: vt6656: Fix pairwise key for non station modes") Cc: stable Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/key.c | 14 +++--- drivers/staging/vt6656/main_usb.c | 6 +- 2 files changed, 8 inserti

Re: [PATCH 2/2] staging: vt6656: Fix functions' documentation

2020-04-19 Thread Malcolm Priestley
On 19/04/2020 08:47, Oscar Carter wrote: > On Sat, Apr 18, 2020 at 07:05:53PM +0100, Malcolm Priestley wrote: >> Actually I don't really think the function descriptions are needed at all the >> names of the functions are enough. >> > Then, it would be better leav

[PATCH] staging: vt6656: Move firmware functions into main_usb.

2020-04-19 Thread Malcolm Priestley
The firmware function are not that complicated so move them into main_usb as static functions in callers visibility Firmware definitions moved to device.h and MODULE_FIRMWARE move to below module_usb_driver. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/Makefile | 3

[PATCH] staging: vt6656: call vnt_update_pre_ed_threshold from vnt_config.

2020-04-19 Thread Malcolm Priestley
vnt_update_pre_ed_threshold needs to be updated more often so call from vnt_config where it updated on any of config changes. It must have maximum sensitivity when the device is off channel or idle. Remove all the other calls in scanning and bss. Signed-off-by: Malcolm Priestley --- drivers

[PATCH] staging: vt6656: Move vnt_get_frame_time and vnt_get_phy_field to rxtx

2020-04-19 Thread Malcolm Priestley
These functions are only used by rxtx so move them and their arrays used with them abbreviating the function description. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/baseband.c | 139 -- drivers/staging/vt6656/baseband.h | 13 --- drivers/staging

Re: [PATCH] staging: vt6656: Refactor the vnt_ofdm_min_rate function

2020-04-19 Thread Malcolm Priestley
Hi all On 19/04/2020 18:55, Stefano Brivio wrote: Hi Oscar, On Sat, 18 Apr 2020 15:45:53 +0200 Oscar Carter wrote: Replace the for loop by a ternary operator whose condition is an AND bitmask against the priv->basic_rates variable. The purpose of the for loop was to check if any of bits fro

[PATCH] staging: vt6656: rxtx: remove duration_id and void returns.

2020-04-23 Thread Malcolm Priestley
duration_id is not used by driver anymore so remove the returns and set all functions in path to void. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/rxtx.c | 78 --- 1 file changed, 36 insertions(+), 42 deletions(-) diff --git a/drivers/staging

[PATCH 1/2] staging: vt6656: Remove set short time in vnt_init_registers.

2020-04-23 Thread Malcolm Priestley
The short time is set in vnt_bss_info_changed no need to set it here. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/main_usb.c | 13 - 1 file changed, 13 deletions(-) diff --git a/drivers/staging/vt6656/main_usb.c b/drivers/staging/vt6656/main_usb.c index

[PATCH 2/2] staging: vt6656: Remove preamble_type setting from vnt_tx_packet.

2020-04-23 Thread Malcolm Priestley
preamble_type is set in vnt_bss_info_changed no need to set it here. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/rxtx.c | 5 - 1 file changed, 5 deletions(-) diff --git a/drivers/staging/vt6656/rxtx.c b/drivers/staging/vt6656/rxtx.c index 7e15534e52ff..f56a2b02fe36 100644

Re: [PATCH] staging: vt6656: rxtx: remove duration_id and void returns.

2020-04-25 Thread Malcolm Priestley
Drop this patch there is a mistake in it. Regards Malcolm ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

[PATCH v2] staging: vt6656: rxtx: remove duration_id and void returns.

2020-04-25 Thread Malcolm Priestley
duration_id is not used by driver anymore so remove the returns and set all functions in patch to void. Signed-off-by: Malcolm Priestley --- v1 had missing returns in vnt_generate_tx_parameter and vnt_rxtx_ab drivers/staging/vt6656/rxtx.c | 84 +-- 1 file

[PATCH 1/3] staging: vt6656: vnt_set_keymode simplify key modes.

2020-04-29 Thread Malcolm Priestley
Unused macros and onfly_latch are removed and others contain to actual key_type value is or-ed with key_mode. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/key.c | 25 + drivers/staging/vt6656/key.h | 13 +++-- 2 files changed, 16 insertions(+), 22

[PATCH 2/3] staging: vt6656 remove vnt_mac_disable_keyentry calls

2020-04-29 Thread Malcolm Priestley
It is not necessary to disable all the keys mac80211 will have removed any existing keys that were used. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/key.c | 10 +- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/drivers/staging/vt6656/key.c b/drivers/staging

[PATCH 3/3] staging: vt6656: return all key calls to mac80211 stack.

2020-04-29 Thread Malcolm Priestley
vnt_mac_set_keyentry can return USB calls so return them to mac80211. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/key.c | 20 +--- 1 file changed, 9 insertions(+), 11 deletions(-) diff --git a/drivers/staging/vt6656/key.c b/drivers/staging/vt6656/key.c index

PATCH] staging: vt6656: use struct wiphy retry short and long settings.

2020-04-29 Thread Malcolm Priestley
Remove driver options for short and long retry and use the ones set by user in wiphy. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/device.h | 3 --- drivers/staging/vt6656/main_usb.c | 8 ++-- 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/drivers/staging

[PATCH] staging: vt6656: Return on isr0 when zero.

2020-05-01 Thread Malcolm Priestley
When isr0 is zero there is nothing more todo so return and pull following code in. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/usbpipe.c | 47 1 file changed, 23 insertions(+), 24 deletions(-) diff --git a/drivers/staging/vt6656/usbpipe.c b

[PATCH ] staging: vt6656: refactor power save operation

2020-05-02 Thread Malcolm Priestley
TBT A further enhancement because the TTBT is more precise the dtim_period can be used instead. When Power save is off the TTBT continues to run at the listen interval but all the other beacons are passed. The code in vnt_int_process_data is no longer required. Signed-off-by: Malcolm Priest

[PATCH v2] staging: vt6656: refactor power save operation

2020-05-02 Thread Malcolm Priestley
BTT A further enhancement because the TBTT is more precise the dtim_period can be used instead. When Power save is off the TBTT continues to run at the listen interval but all the other beacons are passed. The code in vnt_int_process_data is no longer required. Signed-off-by: Malcolm Priest

Re: [PATCH ] staging: vt6656: refactor power save operation

2020-05-02 Thread Malcolm Priestley
Drop this patch v2 sent corrected TTBT. Regards Malcolm ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

[PATCH 1/6] staging: vt6656: vnt_rxtx_rsvtime_le16 to use ieee80211_generic_frame_duration.

2020-05-05 Thread Malcolm Priestley
ieee80211_generic_frame_duration is the mac80211 equivalent to vnt_get_rsvtime use this to get our frame time. There is a change where there is rrv_time_a and rrv_time_b the frame duration is always the same so both are equal. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/rxtx.c

[PATCH 2/6] staging: vt6656: vnt_get_rtscts_duration_le use ieee80211_rts_duration

2020-05-05 Thread Malcolm Priestley
use the mac80211 ieee80211_rts_duration for RTS frames. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/rxtx.c | 20 +--- 1 file changed, 5 insertions(+), 15 deletions(-) diff --git a/drivers/staging/vt6656/rxtx.c b/drivers/staging/vt6656/rxtx.c index 6724b213a723

[PATCH 3/6] staging: vt6656: vnt_get_rtscts_duration_le use ieee80211_ctstoself_duration

2020-05-05 Thread Malcolm Priestley
use the mac80211 ieee80211_ctstoself_duration for CTS to self frames. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/rxtx.c | 32 +++- 1 file changed, 3 insertions(+), 29 deletions(-) diff --git a/drivers/staging/vt6656/rxtx.c b/drivers/staging/vt6656

[PATCH 4/6] staging: vt6656: Split RTS and CTS Duration functions

2020-05-05 Thread Malcolm Priestley
split vnt_get_rtscts_duration_le into vnt_get_rts_duration and vnt_get_cts_duration. The duration's are all the same in vnt_rxtx_rts_g_head. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/rxtx.c | 56 ++- 1 file changed, 16 insertions(+

[PATCH 5/6] staging: vt6656: vnt_get_rtscts_rsvtime_le replace with rts/cts duration.

2020-05-05 Thread Malcolm Priestley
are no longer required. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/rxtx.c | 113 ++ 1 file changed, 5 insertions(+), 108 deletions(-) diff --git a/drivers/staging/vt6656/rxtx.c b/drivers/staging/vt6656/rxtx.c index 47da9dabb133..8348ffe6ebfa 100644

[PATCH 6/6] staging: vt6656: remove difs / sifs adjustments.

2020-05-05 Thread Malcolm Priestley
Now mac89211 is doing frame timing in rxtx these vendor adjustments need to be removed. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/card.c | 32 1 file changed, 32 deletions(-) diff --git a/drivers/staging/vt6656/card.c b/drivers/staging/vt6656

[PATCH 1/2] staging: vt6656: use off stack for out buffer USB transfers.

2017-04-22 Thread Malcolm Priestley
Since 4.9 mandated USB buffers be heap allocated this causes the driver to fail. Since there is a wide range of buffer sizes use kmemdup to create allocated buffer. Signed-off-by: Malcolm Priestley Cc: # v4.9+ --- drivers/staging/vt6656/usbpipe.c | 14 -- 1 file changed, 12

[PATCH 2/2] staging: vt6656: use off stack for in buffer USB transfers.

2017-04-22 Thread Malcolm Priestley
Since 4.9 mandated USB buffers to be heap allocated. This causes the driver to fail. Create buffer for USB transfers. Signed-off-by: Malcolm Priestley Cc: # v4.9+ --- drivers/staging/vt6656/usbpipe.c | 17 +++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a

[PATCH 2/4] staging: vt6656: always call vnt_update_ifs on short time change.

2017-04-29 Thread Malcolm Priestley
short time change needs to synchronize parameters in vnt_update_ifs so a call to the function is always necessary. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/main_usb.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/staging/vt6656/main_usb.c b/drivers/staging

[PATCH 1/4] staging: vt6656: vnt_update_ifs set max_min based on short slot time.

2017-04-29 Thread Malcolm Priestley
Short slot time is controlled by mac80211 so there is no need to find odfm rates. Merge PK_TYPE_11B and PK_TYPE_11GA & PK_TYPE_11GB into one else and switch on short slot time. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/card.c | 29 ++--- 1 file cha

[PATCH 4/4] staging: vt6656: Only call vnt_set_bss_mode on basic rates change.

2017-04-29 Thread Malcolm Priestley
To ensure the bss is always synchronized only call on basic rate change. Signed-off-by: Malcolm Priestley --- drivers/staging/vt6656/main_usb.c | 13 +++-- 1 file changed, 3 insertions(+), 10 deletions(-) diff --git a/drivers/staging/vt6656/main_usb.c b/drivers/staging/vt6656

[PATCH 3/4] staging: vt6556: vnt_start Fix missing call to vnt_key_init_table.

2017-04-29 Thread Malcolm Priestley
The key table is not intialized correctly without this call. Signed-off-by: Malcolm Priestley Cc: # v3.17+ --- drivers/staging/vt6656/main_usb.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/staging/vt6656/main_usb.c b/drivers/staging/vt6656/main_usb.c index 9237930991ca

[PATCH 1/3] staging: rtl8192e rtl92e_fill_tx_desc fix write to mapped out memory.

2017-05-07 Thread Malcolm Priestley
-by: Malcolm Priestley Cc: --- drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c | 13 + 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c b/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c index 4723a0bd5067..a23628f390c9 100644 --

[PATCH 3/3] staging: rtl8192e rtl92e_get_eeprom_size Fix read size of EPROM_CMD.

2017-05-07 Thread Malcolm Priestley
EPROM_CMD is 2 byte aligned on PCI map so calling with rtl92e_readl will return invalid data so use rtl92e_readw. The device is unable to select the right eeprom type. Signed-off-by: Malcolm Priestley Cc: --- drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c | 2 +- 1 file changed, 1 insertion

[PATCH 2/3] staging: rtl8192e: fix 2 byte alignment of register BSSIR.

2017-05-07 Thread Malcolm Priestley
BSSID has two byte alignment on PCI ioremap correct the write by swapping to 16 bits first. This fixes a problem that the device associates fail because the filter is not set correctly. Signed-off-by: Malcolm Priestley Cc: --- drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c | 9 + 1

[PATCH v2 2/4] staging: rtl8192e: fix 2 byte alignment of register BSSIDR.

2017-05-11 Thread Malcolm Priestley
BSSIDR has two byte alignment on PCI ioremap correct the write by swapping to 16 bits first. This fixes a problem that the device associates fail because the filter is not set correctly. Signed-off-by: Malcolm Priestley Cc: --- v2 - Fix name of register in commit message. drivers/staging

[PATCH v2 3/4] staging: rtl8192e: rtl92e_get_eeprom_size Fix read size of EPROM_CMD.

2017-05-11 Thread Malcolm Priestley
EPROM_CMD is 2 byte aligned on PCI map so calling with rtl92e_readl will return invalid data so use rtl92e_readw. The device is unable to select the right eeprom type. Signed-off-by: Malcolm Priestley Cc: --- v2 - Fix typo in subject line drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c | 2

[PATCH v2 1/4] staging: rtl8192e: rtl92e_fill_tx_desc fix write to mapped out memory.

2017-05-11 Thread Malcolm Priestley
The driver attempts to alter memory that is mapped to PCI device. This is because tx_fwinfo_8190pci points to skb->data Move the pci_map_single to when completed buffer is ready to be mapped with psdec is empty to drop on mapping error. Signed-off-by: Malcolm Priestley Cc: --- v2 - Fix t

[PATCH 4/4] staging: rtl8192e: GetTs Fix invalid TID 7 warning.

2017-05-11 Thread Malcolm Priestley
TID 7 is a valid value for QoS IEEE 802.11e. The switch statement that follows states 7 is valid. Remove function IsACValid and use the default case to filter invalid TIDs. Signed-off-by: Malcolm Priestley Cc: --- drivers/staging/rtl8192e/rtl819x_TSProc.c | 15 --- 1 file changed

[PATCH 3/5] staging: rtl8192e: HTSetConnectBwMode message replace with debug.

2017-05-13 Thread Malcolm Priestley
The flag status of bCurBW40MHz is printed as info and is only useful as debug message. Replace with netdev_dbg in line with rest of driver. Signed-off-by: Malcolm Priestley --- drivers/staging/rtl8192e/rtl819x_HTProc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a

[PATCH 2/5] staging: rtl8192e: print alg name as debug.

2017-05-13 Thread Malcolm Priestley
alg name will be printed a number times during a connection it is only really useful as a debug message. Change to netdev_dbg. Signed-off-by: Malcolm Priestley --- drivers/staging/rtl8192e/rtllib_wx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/rtl8192e

[PATCH 5/5] staging: rtl8192e: _rtl92e_dm_check_edca_turbo remove peername message.

2017-05-13 Thread Malcolm Priestley
This kinda reports this as if it was an error message. Now that bssid is reported at associate remove this piece of code serves no purpose as there is no code for peers so remove it. Signed-off-by: Malcolm Priestley --- drivers/staging/rtl8192e/rtl8192e/rtl_dm.c | 16 1 file

  1   2   >