Commit Graph

798 Commits

Author SHA1 Message Date
Shivani Bhardwaj 4188e5862f Staging: vt6655: mac: Remove extra braces
Remove braces from an if block as it comprises of a single statement.
Fix checkpatch warning: braces {} are not necessary for single statement
blocks

Signed-off-by: Shivani Bhardwaj <shivanib134@gmail.com>
Reviewed-by: Daniel Baluta <daniel.baluta@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-12 20:54:14 -07:00
Shivani Bhardwaj 45e68e45d3 Staging: vt6655: rxtx: Remove extra parentheses
Remove unnecessary parentheses around if test expressions.
Fixes checkpatch warning : unnecessary parentheses

Signed-off-by: Shivani Bhardwaj <shivanib134@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-12 20:54:14 -07:00
Shivani Bhardwaj b2d44fe3ec Staging: vt6655: rxtx: Remove extra space character
Remove unnecessary space character after the variable RATE_16M
preserving the alignment of all other variables and comments.
Fixes the warning by checkpatch:  space prohibited before
that ',' (ctx:WxW)

Signed-off-by: Shivani Bhardwaj <shivanib134@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-12 20:54:14 -07:00
Paul McQuade c1aa41dc7b Staging: vt6655: Renamed uRATE to rate
Renamed uRATE to rate to avoid camelcase

Signed-off-by: Paul McQuade <paulmcquad@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-12 20:54:14 -07:00
Amitoj Kaur Chawla 137e37d0ed staging: vt6655: Remove true comparison
Remove comparison to true in if statement. Problem found using
checkpatch.pl
CHECK: Using comparison to true is error prone

Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-08 10:25:32 +01:00
Malcolm Priestley 9f31b69559 staging: vt6655: device_tx_srv rename pTD
Following the convention elsewhere for vnt_tx_desc rename
desc.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-04 09:54:51 +01:00
Malcolm Priestley 12f2ee356e staging: vt6655: device_main replace pTDInfo with td_info.
Removing camel case.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-04 09:54:51 +01:00
Malcolm Priestley 480fc5b8f6 staging: vt6655: device_main replace pRD with rd.
Removing camel case.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-04 09:54:51 +01:00
Malcolm Priestley 5e011b4336 staging: vt6655: device_alloc_rx_buf replace pRDInfo with rd_info.
Removing camel case.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-04 09:54:51 +01:00
Malcolm Priestley 5e76c8f4aa staging: vt6655: device_main.c replace pDesc with desc.
Removing camel case.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-04 09:54:51 +01:00
Malcolm Priestley 78e0e85376 staging: vt6655: device_main replace pDevice with priv.
Removing camel case.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-04 09:54:51 +01:00
Arjun Krishna Babu 5f7a942495 staging: vt6655: Fixed two lines over 80 characters long
Two lines of code that were over 80 characters long is fixed
by splitting them across multiple lines.

The lines of code are now easier to comprehend.

Issue found by checkpatch.

Signed-off-by: Arjun Krishna Babu <arjunkrishnababu96@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-02 11:48:15 +02:00
Malcolm Priestley 113d6dc18e staging: vt6655: don't stop TX queue unless buffer full.
Presently the TX buffer stops while filling the buffer.

However, this does not make use of the available buffer
space, it also lags the speed of the TX troughtput.

Only stop the queue when the buffer becomes full. The
Interupt handler will start the queue again when a
buffer is available.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-29 04:19:53 +02:00
Malcolm Priestley a03b8b3e18 staging: vt6655: Move code in device_get_pci_info
Function always returns true and now only a few lines move
to vt6655_probe.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-14 08:50:46 -07:00
Malcolm Priestley 70d66a6a75 staging: vt6655: device_get_pci_info pcid already assigned.
pcid has already been assigned earlier in vt6655_probe.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-14 08:50:45 -07:00
Malcolm Priestley 41652a21b7 staging: vt6655: device_get_pci_info remove call to set master.
a call to PCI_COMMAND is used to set master.

However, a call to pci_set_master earlier in function which
does the same thing.

So remove the calls and variable b.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-14 08:50:45 -07:00
Malcolm Priestley 2ef1571b13 staging: vt6655: device_get_pci_info remove variable cis_addr.
cis_addr is never used remove its call to pci_resource_start.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-14 08:50:45 -07:00
Malcolm Priestley 7a95f96108 staging: vt6655: device_get_pci_info remove unused pci_read_config_*
These values are read from pci but never used.

Removing variables byRevId, SubSystemID, SubVendorID and pci_cmd.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-14 08:50:45 -07:00
Malcolm Priestley f31798266f staging: vt6655: remove and move vt6655_init_info
move code to vt6655_probe.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-14 08:50:45 -07:00
Malcolm Priestley e577474f3b staging: vt6655: vt6655_init_info remove memset.
vnt_private is allocated with kzalloc so is already zero.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-14 08:50:45 -07:00
Malcolm Priestley 73eb8a1127 staging: vt6655: remove unused multicast_limit.
multicast_limit is assigned a vale that is never used.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-14 08:50:45 -07:00
Malcolm Priestley 319755a722 staging: vt6655: Remove typedef struct __chip_info_tbl
Only two values that are assigned from this table.

DEVICE_FLAGS_TX_ALIGN and the value of io_size which is used
as the size of ioremap which is 256.

Remove all variables, DEVICE_FLAGS_TX_ALIGN check, apply io_size value
and chip_info_table.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-14 08:50:45 -07:00
Malcolm Priestley e77610a94c staging: vt6655: remove get_chip_name and info message.
This prints "VIA Networking Solomon-A/B/G Wireless LAN Adapter"
which has already printed once in vt6655_probe.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-14 08:50:45 -07:00
Malcolm Priestley c2c77eea18 staging: vt6655: vt6655_probe remove PCI debug info
Remove unnecessary debug PCI info that can be obtained
by lspci.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-14 08:50:44 -07:00
Malcolm Priestley 9cb693f6f3 staging: vt6655: replace typedef struct tagSRxDesc
with struct vnt_rx_desc and all members the same.

volatile is removed from pointers as this generates warning
message.

Only the first four members of vnt_rx_desc need to be volatile.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:26 -07:00
Malcolm Priestley 88defe2b35 staging: vt6655: replace typedef struct tagDEVICE_RD_INFO
with struct vnt_rd_info

volatile is removed because it will generate a warning
(in any case this member is not) and renaming rd_info.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:26 -07:00
Malcolm Priestley 9fc7091cc2 staging: vt6655: replace typedef struct tagRDES1
with struct vnt_rdes1 and members
wReqCount -> req_count
wReserved -> reserved

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:26 -07:00
Malcolm Priestley de1c1862ca staging: vt6655: replace typedef struct tagRDES0
with struct vnt_rdes0 replacing members as follows
wResCount -> res_count
f15Reserved -> f15_reserved
f1Owner -> owner

big endian
f8Reserved1 -> f8_reserved1
f7Reserved -> f7_reserved

Narrowing endian differences to inside structure.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:26 -07:00
Malcolm Priestley e235727173 staging: vt6655: Replace typedef struct tagSTxDesc
Replace with struct vnt_tx_desc with all members the same.

volatile is removed from pointers as this generates warning
message.

Only the first four members of vnt_tx_desc need to be volatile.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 19:31:11 -07:00
Malcolm Priestley 543828599a staging: vt6655: replace typedef struct tagDEVICE_TD_INFO and structure
Create struct vnt_td_info with members
mic_hdr
skb
buf
buf_dma
dwReqCount -> req_count
byFlags -> flags

In struct tagSTxDesc volatile is removed because it will generate a warning
(in any case this member is not) and renaming td_info.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 19:31:11 -07:00
Malcolm Priestley 3a0989bb6c staging: vt6655: struct tagDEVICE_TD_INFO remove dwHeaderLength
dwHeaderLength is assigned a value but that is never used.

Remove variable.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 19:31:10 -07:00
Malcolm Priestley 531a9c524a staging: vt6655: struct tagDEVICE_TD_INFO resize dwReqCount.
dwReqCount is no bigger than u16

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 19:31:10 -07:00
Malcolm Priestley 9cc8eac99c staging: vt6655: replaced typedef struct tagTDES1
Create struct vnt_tdes1 that replaces members
wReqCount -> req_count
byTCR -> tcr
byReserved -> reserved

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 19:31:10 -07:00
Malcolm Priestley 5235ff6a1d staging: vt6655: desc.h replace typedef struct tagTDES0
create struct vnt_tdes0 replacing used members
byTSR0 -> tsr0
byTSR1 -> tsr1
f1Owner -> owner

Narrowing endian differences to inside structure.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 19:31:10 -07:00
Greg Kroah-Hartman f70d631832 Merge 4.2-rc6 into staging-next
We want the IIO and staging fixes in here as well.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-10 09:07:25 -07:00
Lior Pugatch fce7f39356 staging: vt6655: Fixed C99 style comment to C89 style.
Patch created to satisfy checkpatch.pl

Signed-off-by: Lior Pugatch <buzz5800@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-05 11:55:44 -07:00
Malcolm Priestley 1f17124006 staging: vt6655: vnt_bss_info_changed check conf->beacon_rate is not NULL
conf->beacon_rate can be NULL on association. So check conf->beacon_rate

BSS_CHANGED_BEACON_INFO needs to flagged in changed as the beacon_rate
will appear later.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Cc: <stable@vger.kernel.org> # v3.19+
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-03 17:54:51 -07:00
Malcolm Priestley 03c44dd62e staging: vt6655: desc.h remove dead strctures
Remove these unsed structures.
typedef struct tagSTxSyncDesc
typedef struct tagSRrvTime_atim
typedef struct tagSTxBufHead
typedef struct tagSBEACONCtl
typedef struct tagSSecretKey
typedef struct tagSKeyEntry

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-22 20:51:40 -07:00
Malcolm Priestley c5c7bd269d staging: vt6655: s_cbFillTxBufHead replace STxBufHead
vnt_tx_fifo_head has now replaced STxBufHead

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-22 20:51:40 -07:00
Malcolm Priestley d5806c53fe staging: vt6655: always set 32 bit dma mask
The device is limited to 32 bit address space.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-22 20:51:40 -07:00
Malcolm Priestley 1cf0a47c8c staging: vt6655: fix tagTDES1 -> wReqCount type
should be __le16

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-22 20:51:40 -07:00
Malcolm Priestley 7135d9a76f staging: vt6655: Fix wReqCount to __le16
Should be __le16 and do and correct endian conversion.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-22 20:51:39 -07:00
Malcolm Priestley f1e3e92135 staging: vt6655: fix tagSRxDesc -> next_desc type
Should always be __le32

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-22 20:51:39 -07:00
Malcolm Priestley f0fb87fba0 staging: vt6655: Fix tagSRxDesc -> buff_addr type
Should always be __le32.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-22 20:51:39 -07:00
Malcolm Priestley db1ade7cee staging: vt6655: remove unused tagDEVICE_RD_INFO -> curr_desc
variable is assigned a value that is never used.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-22 20:51:38 -07:00
Malcolm Priestley 5fa9d9898d staging: vt6655: fix tagSTxDesc -> next_desc type
Should always be __le32 type

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-22 20:51:38 -07:00
Malcolm Priestley 75a8eee2d7 staging: vt6655: fix tagDEVICE_TD_INFO -> buff_addr type
Should always be __le32 type

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-22 20:51:38 -07:00
Malcolm Priestley eae6377eb0 staging: vt6655: Remove unused tagDEVICE_TD_INFO curr_desc
The variable is assigned a value that is never used.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-22 20:51:38 -07:00
Malcolm Priestley 06f716a57e staging: vt6655: remove unnecessary variable skb_dma
skb_dma flips from 0 to the contents buf_dma.

This is nolonger necessary so use buf_dma directly
and remove skb_dma altogether.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-22 20:51:37 -07:00
Malcolm Priestley 3a00033ee8 staging: vt6655: dead code tx path remove dma_unmap_single
When pTDInfo->skb_dma not equal to pTDInfo->buf_dma, pTDInfo->skb_dma
equals zero.

as mentioned in comment pre-allocated buf_dma can't be unmapped
so remove dead code.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-22 20:51:37 -07:00
Malcolm Priestley fd43585b64 staging: vt6655: remove unused DBG_PORT80 and VIAWET_DEBUG
VIAWET_DEBUG is never defined so DBG_PORT80 is empty and never used.

Remove both macros.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-22 20:51:37 -07:00
Malcolm Priestley 217ed3abf1 staging: vt6655: Remove ununsed macro ASSERT
VIAWET_DEBUG is not defined so macro is empty.

Remove the macro.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-22 20:51:37 -07:00
Greg Kroah-Hartman ed15e8880f Merge 4.2-rc3 into staging-next
We need the staging fixes in here as well.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-20 13:21:28 -07:00
Maninder Singh 4d4d138a3e staging:vt6655: remove checks around dev_kfree_skb
dev_kfree_skb checks for NULL pointer itself,
Thus no need of explicit NULL check.

Signed-off-by: Maninder Singh <maninder1.s@samsung.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-14 22:48:29 -07:00
Malcolm Priestley 8e8e919892 staging: vt6655: check ieee80211_bss_conf bssid not NULL
Sometimes bssid can go null on failed association.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Cc: <stable@vger.kernel.org> # v3.19+
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-14 19:34:57 -07:00
Nicholas Parkanyi 11208b0b3a Staging: vt6655: Remove do { } while (0) from single-statement macros in upc.h.
This patch fixes checkpatch.pl warnings in upc.h regarding single-statement macros
embedded within do { } while (0) blocks.

Signed-off-by: Nicholas Parkanyi <n.parkanyi@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-14 19:28:40 -07:00
Nicholas Parkanyi 353710ce90 Staging: vt6655: Replace C99 comments in rf.h and rf.c.
This patch replaces C99 comments in rf.h and rf.c, with
C89 comments, fixing the checkpatch.pl errors.

Signed-off-by: Nicholas Parkanyi <n.parkanyi@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-14 19:28:40 -07:00
Malcolm Priestley eda01f6161 staging: vt6655: Fix missing power saving support
Add IEEE80211_HW_SUPPORTS_PS to ieee80211_hw flags
enabling this feature.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-14 19:27:27 -07:00
Malcolm Priestley 3e7921a094 staging: vt6655: Correct listen interval TBTT wake up
PSbIsNextTBTTWakeUp is called at beacon intervals.

The should listen to next beacon on count down of wake_up_count == 1.

This restores this back to vendors code but modified for mac80211.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-14 19:26:35 -07:00
Malcolm Priestley 4fdae0d9fe staging: vt6655: vnt_tx_packet don't wakeup from power saving.
mac80211 changes the wake state before attempting to tx data

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-14 19:26:35 -07:00
Linus Torvalds 23908db413 Staging driver patches for 4.2-rc1
Here's the big, really big, staging tree patches for 4.2-rc1.
 
 Loads of stuff in here, almost all just coding style fixes / churn, and
 a few new drivers as well, one of which I just disabled from the build a
 few minutes ago due to way too many build warnings.
 
 Other than the one "disable this driver" patch, all of these have been
 in linux-next for quite a while with no reported issues.
 
 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v2
 
 iEYEABECAAYFAlWNpc0ACgkQMUfUDdst+ym8EgCg0pL1Qcf9Se3jAc96fLt+itpv
 Rd0AoI9uJcq8Qm7d+IXnz3ojLnN9xvN3
 =xt0u
 -----END PGP SIGNATURE-----

Merge tag 'staging-4.2-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging

Pull staging driver updates from Greg KH:
 "Here's the big, really big, staging tree patches for 4.2-rc1.

  Loads of stuff in here, almost all just coding style fixes / churn,
  and a few new drivers as well, one of which I just disabled from the
  build a few minutes ago due to way too many build warnings.

  Other than the one "disable this driver" patch, all of these have been
  in linux-next for quite a while with no reported issues"

* tag 'staging-4.2-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging: (1163 commits)
  staging: wilc1000: disable driver due to build warnings
  Staging: rts5208: fix CHANGE_LINK_STATE value
  Staging: sm750fb: ddk750_swi2c.c: Insert spaces before parenthesis
  Staging: sm750fb: ddk750_swi2c.c: Place braces on correct lines
  Staging: sm750fb: ddk750_swi2c.c: Insert spaces around operators
  Staging: sm750fb: ddk750_swi2c.c: Replace spaces with tabs
  Staging: sm750fb: ddk750_swi2c.h: Shorten lines to under 80 characters
  Staging: sm750fb: ddk750_swi2c.h: Replace spaces with tabs
  Staging: sm750fb: modedb.h: Shorten lines to under 80 characters
  Staging: sm750fb: modedb.h: Replace spaces with tabs
  staging: comedi: addi_apci_3120: rename 'this_board' variables
  staging: comedi: addi_apci_1516: rename 'this_board' variables
  staging: comedi: ni_atmio: cleanup ni_getboardtype()
  staging: comedi: vmk80xx: sanity check context used to get the boardinfo
  staging: comedi: vmk80xx: rename 'boardinfo' variables
  staging: comedi: dt3000: rename 'this_board' variables
  staging: comedi: adv_pci_dio: rename 'this_board' variables
  staging: comedi: cb_pcidas64: rename 'thisboard' variables
  staging: comedi: cb_pcidas: rename 'thisboard' variables
  staging: comedi: me4000: rename 'thisboard' variables
  ...
2015-06-26 15:46:08 -07:00
Malcolm Priestley e75e8cacba staging: vt6655: use module_pci_driver helper
Remove  vt6655_init_module and vt6655_cleanup_module and replace
module_pci_driver

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-06-17 21:26:45 -07:00
Malcolm Priestley b51c88171e staging: vt6655: remove suspend struct notifier_block.
The only thing this does is vt6655_suspend which is already been called
upon suspend.

Remove function device_notify_reboot and structure device_notifier.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-06-17 21:26:45 -07:00
matt mooney e968542ced staging: vt6655: fix c99 comments and line length
Change comment style and remove extra spaces before macro names to
avoid exceeding 80 characters.

Signed-off-by: matt mooney <mfm@muteddisk.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-06-15 21:50:22 -07:00
Harisangam Sharvari 441b3e45c2 Staging: vt6655: Remove unnecessary equality checks in rxtx.c
The unnecessary equality checks for bool variable are removed in rxtx.c.
These changes were detected with the help of coccinelle tool

Signed-off-by: Harisangam Sharvari <sharisan@visteon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-06-12 17:10:47 -07:00
Johannes Berg 30686bf7f5 mac80211: convert HW flags to unsigned long bitmap
As we're running out of hardware capability flags pretty quickly,
convert them to use the regular test_bit() style unsigned long
bitmaps.

This introduces a number of helper functions/macros to set and to
test the bits, along with new debugfs code.

The occurrences of an explicit __clear_bit() are intentional, the
drivers were never supposed to change their supported bits on the
fly. We should investigate changing this to be a per-frame flag.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2015-06-10 16:05:36 +02:00
Malcolm Priestley b5eeed8cb6 staging: vt6655: device_rx_srv check sk_buff is NULL
There is a small chance that pRD->pRDInfo->skb could go NULL
while the interrupt is processing.

Put NULL check on loop to break out.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Cc: <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-06-01 06:24:58 +09:00
Malcolm Priestley 41b9e5e516 staging: vt6655: replace and resize dwIsr
dwIsr is not used outside vnt_interrupt_process and should
be u32.

Move to function and resize to u32.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-06-01 06:24:57 +09:00
Malcolm Priestley 2995dfe68a staging: vt6655: vnt_interrupt_process remove camel case.
pDevice -> priv

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-06-01 06:24:57 +09:00
Malcolm Priestley f33d8d63fc staging: vt6655: vnt_interrupt_process remove page 0 select
Page 1 is fully proctected by lock there is no need
to check for it. Page 0 is selected at other times.

Remove byOrgPageSel and its calls from function.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-06-01 06:24:57 +09:00
Malcolm Priestley ff1ce1a81e staging: vt6655: use workqueue for interrupt handling
Introduce vnt_interrupt to handle interrupt and use workqueue
to queue and queue on vif.

Convert device_intr to void call vnt_interrupt_process
from vnt_interrupt_work providing vif is valid.

This removes troublesome heavy code from the interupt handler and
allows to remove atomic from other areas of driver.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-06-01 06:24:57 +09:00
Malcolm Priestley da74dbac16 staging: vt6655: remove mib.c/h dead code.
Remove from makefile and dead variables

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-06-01 06:24:57 +09:00
Malcolm Priestley 7e4786d1ab staging: vt6655: Remove call to STAvUpdateIsrStatCounter.
This function does not provide any data to users.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-06-01 06:24:57 +09:00
Malcolm Priestley 19327367de staging: vt6655: dead code remove STAvUpdate802_11Counter
This function is nolonger of any future use.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-06-01 06:24:57 +09:00
Malcolm Priestley 700f6c0258 staging: vt6655: implement ieee80211_low_level_stats
Collect low level stats from mib counter for mac80211 call.

Replacing the unused function STAvUpdate802_11Counter.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-06-01 06:24:56 +09:00
David S. Miller 36583eb54d Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Conflicts:
	drivers/net/ethernet/cadence/macb.c
	drivers/net/phy/phy.c
	include/linux/skbuff.h
	net/ipv4/tcp.c
	net/switchdev/switchdev.c

Switchdev was a case of RTNH_H_{EXTERNAL --> OFFLOAD}
renaming overlapping with net-next changes of various
sorts.

phy.c was a case of two changes, one adding a local
variable to a function whilst the second was removing
one.

tcp.c overlapped a deadlock fix with the addition of new tcp_info
statistic values.

macb.c involved the addition of two zyncq device entries.

skbuff.h involved adding back ipv4_daddr to nf_bridge_info
whilst net-next changes put two other existing members of
that struct into a union.

Signed-off-by: David S. Miller <davem@davemloft.net>
2015-05-23 01:22:35 -04:00
Greg Kroah-Hartman 936a0cd52a Merge 4.1-rc4 into staging-next
We want the fixes in here for testing and merge issues.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-18 13:52:44 -07:00
Malcolm Priestley 664a5c1d1e staging: vt6655: lock MACvWriteBSSIDAddress.
This function selects page 1 and cause intermittent problems on
interrupt handler.

lock call with spin_lock_irqsave.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Cc: <stable@vger.kernel.org> # v3.19+
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-08 14:35:23 +02:00
Malcolm Priestley 032ed34a84 staging: vt6655: CARDbUpdateTSF bss timestamp correct tsf counter value.
The TSF counter is not set correctly.

Use sync_tsf for last beacon value and get tsf local value.

Remove qwLocalTSF variable and call CARDbGetCurrentTSF.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-08 14:35:22 +02:00
Malcolm Priestley d65d2b25d2 staging: vt6655: vnt_tx_packet Correct TX order of OWNED_BY_NIC
The state of m_td0TD0.f1Owner should change after the buff_addr
has been filled otherwise the device grabs the buffer too early.

m_td0TD0.f1Owner is protected by memory barriers on both sides
of change.

iTDUsed is best incremented after MACvTransmit.

It appears that f1Owner actually polls to do the memory transfer.

A back port patch will be needed for v3.19

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Cc: <stable@vger.kernel.org> # v4.0+
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-08 14:35:22 +02:00
Malcolm Priestley ad3fee9b17 staging: vt6655: Fix 80211 control and management status reporting.
Currently only TD_FLAGS_NETIF_SKB are reported back to mac80211.

Move vnt_int_report_rate to report all frame types.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Cc: <stable@vger.kernel.org> # v3.19+
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-08 14:28:05 +02:00
Malcolm Priestley 6e44dc4be0 staging: vt6655: implement IEEE80211_TX_STAT_NOACK_TRANSMITTED
Make use of this macro for non ack frames.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Cc: <stable@vger.kernel.org> # v4.0
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-08 14:28:05 +02:00
Malcolm Priestley 3fa0917beb staging: vt6655: device_free_tx_buf use only ieee80211_tx_status_irqsafe
TD_FLAGS_NETIF_SKB is only for data.

Fixes issue of ack frames not being reported.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Cc: <stable@vger.kernel.org> # v3.19+
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-08 14:28:05 +02:00
Guillaume Brogi d4855fe18e staging: vt6655: Checkpatch fix: lines longer than 80 columns
This patch fixes lines longer than 80 columns in mac.c.
5 lines longer than 80 columns remain for the sake of readability.

Signed-off-by: Guillaume Brogi <gui-gui@netcourrier.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-08 09:24:12 +02:00
Carlos E. Garcia 69e98df782 Staging: fixed multiple spelling errors.
Fixed multiple spelling errors.

Signed-off-by: Carlos E. Garcia <carlos@cgarcia.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-08 09:23:58 +02:00
Malcolm Priestley 32b249b0f5 staging: vt6655: device_intr check for vif on while loop
vif should never be or go null while in loop.

Fixes race condition where interrupts are late and when
interface is not present.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-04-30 16:57:32 +02:00
Johannes Berg df1404650c mac80211: remove support for IFF_PROMISC
This support is essentially useless as typically networks are encrypted,
frames will be filtered by hardware, and rate scaling will be done with
the intended recipient in mind. For real monitoring of the network, the
monitor mode support should be used instead.

Removing it removes a lot of corner cases.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2015-04-24 11:14:13 +02:00
Malcolm Priestley a6388e6832 staging: vt6655: use ieee80211_tx_info to select packet type.
Information for packet type is in ieee80211_tx_info

band IEEE80211_BAND_5GHZ for PK_TYPE_11A.

IEEE80211_TX_RC_USE_CTS_PROTECT via tx_rate flags selects PK_TYPE_11GB

This ensures that the packet is always the right type.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Cc: <stable@vger.kernel.org> # v3.19+
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-04-03 15:12:54 +02:00
Malcolm Priestley df18480650 staging: vt6655: s_vGenerateTxParameter Replace PSTxBufHead with struct vnt_tx_fifo_head
With endian correction on fifo_ctl and current_rate.

Removing pTxBufHead, pFifoHead and wFifoCtl

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-04-03 15:12:54 +02:00
Greg Kroah-Hartman 807dc0668e Merge 4.0-rc5 into staging-testing
We want the staging tree fixes that are upstream here as well to prevent
merge conflicts from people trying to clean up code.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-23 21:36:48 +01:00
Hatice ERTÜRK 7a48a09196 Staging: vt6655: changed C99 // comments
// erased and replace it with /**/ used.
Error found with checkpatch.pl

Signed-off-by: Hatice ERTURK <haticeerturk27@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-20 13:42:22 +01:00
Quentin Lambert a1c6dcda80 staging: vt6655: remove deprecated use of pci api
Replace occurences of the pci api by appropriate call to the dma api.

A simplified version of the semantic patch that finds this problem is as
follows: (http://coccinelle.lip6.fr)

@deprecated@
idexpression id;
position p;
@@

(
  pci_dma_supported@p ( id, ...)
|
  pci_alloc_consistent@p ( id, ...)
)

@bad1@
idexpression id;
position deprecated.p;
@@
...when != &id->dev
   when != pci_get_drvdata ( id )
   when != pci_enable_device ( id )
(
  pci_dma_supported@p ( id, ...)
|
  pci_alloc_consistent@p ( id, ...)
)

@depends on !bad1@
idexpression id;
expression direction;
position deprecated.p;
@@

(
- pci_dma_supported@p ( id,
+ dma_supported ( &id->dev,
...
+ , GFP_ATOMIC
  )
|
- pci_alloc_consistent@p ( id,
+ dma_alloc_coherent ( &id->dev,
...
+ , GFP_ATOMIC
  )
)

Signed-off-by: Quentin Lambert <lambert.quentin@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-20 13:41:38 +01:00
Himani Agrawal 5b4ac54fd5 staging: vt6655: Fixes the checkpatch.pl warning
warning fixed:

WARNING: line over 80 characters

The function call containing several variables is broken to make it fit
in 80 characters.

Signed-off-by: Himani Agrawal <himani93@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-15 18:41:10 +01:00
Malcolm Priestley 1f51d58018 vt6655: Fix late setting of byRFType.
byRFType is not set prior to registration of mac80211 causing
unpredictable operation after channel scans.

With byRFType unset all channels are enabled this causes tx power
to be set to values not present its eeprom.

Move setting of this variable to vt6655_probe.

byRFType must have a mask set. byRevId not used by driver and
is removed.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Cc: <stable@vger.kernel.org> # v3.19+
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-09 11:33:13 +01:00
Malcolm Priestley 40c8790bcb vt6655: RFbSetPower fix missing rate RATE_12M
When the driver sets this rate a power of zero value is set causing
data flow stoppage until another rate is tried.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Cc: <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-09 11:33:13 +01:00
Malcolm Priestley c312530589 staging: vt6655: vnt_tx_packet fix dma_idx selection.
There is still a problem that dma_idx is causing packets to
go onto the wrong tx path.

Protect dma_idx fully with the present first lock and
use pTDInfo->byFlags TD_FLAGS_NETIF_SKB to set MACvTransmit.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-09 08:12:40 +01:00
Matteo Semenzato 9ab81fb7a9 Staging: vt6655: fix C99 comments
This patch fixes the following warning:
do not use C99 // comments

Signed-off-by: Matteo Semenzato <mattew8898@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-06 16:28:19 -08:00
Alex W Slater bb72dd53d7 staging: vt6655: Cleanup C99 comments
Fix checkpatch.pl errors:

"ERROR: do not use C99 // comments"

Signed-off-by: Alex W Slater <alex.slater.dev@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-06 16:26:58 -08:00
Matt 7e59b047cc Staging: vt6655 fix C99 style comments
Signed-off-by: Matteo Semenzato <mattew8898@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-06 16:26:58 -08:00
Ivan Stankovic 636cd16806 staging: vt6655: fix coding style issues in channel.c
Observe the line length limit to make checkpatch.pl happy.

Signed-off-by: Ivan Stankovic <pokemon@fly.srk.fer.hr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-06 16:26:58 -08:00