Commit Graph

143 Commits

Author SHA1 Message Date
Mahesh Kumar Kalikot Veetil
32e4fc75d1 qcacld-3.0: Cleanup IBSS feature
Fix compilation errors when turning off QCA_IBSS_SUPPORT

Change-Id: I3a493c710077bec0a8bc5521d0d433ccd62b4e74
CRs-Fixed: 1067029
2016-09-15 21:04:40 -07:00
Manjunathappa Prakash
fff753c12e qcacld-3.0: Add option to control Rx flow steering
Add ini configuration to enable/disable Rx flow steering.
Add HTT message to configure RX flow steering.

Change-Id: I80aab262c754716b28bfdae561d1cbf5e1d38e4d
CRs-Fixed: 1055179
2016-09-11 15:23:53 -07:00
Mohit Khanna
38d0e9335d qcacld-3.0: Maintain length for each TSO segment
In current codeflow, we are maintaining the length of the TSO segments
belonging to one jumbo packet inside tso_info, which is common for
all the segments of one jumbo packet. This works if the length of
the segments (frag[1]) is the same. In case it is not, it ends up
assigning incorrect length to all the segments. This is resulting
GMS login failure.
Fix issue by maintaining the total length of the segment in the
qdf_tso_seg_t structure.
Re-factor code for easy readability
Add TSO_DEBUG prints which can be enabled (compile time) to debug
TSO issues

Change-Id: Ie0cf8434902c0713ef8d36dc36c105afa6b5eabc
CRs-Fixed: 1062556
(cherry picked from commit 0a851f054171cf4b2f5bd7e8cd6841e90d999928)
2016-09-10 19:26:50 -07:00
Himanshu Agarwal
f03f81036d qcacld-3.0: Fix NULL pointer dereferencing issues
Fix below issues:
1) check cds_get_context results before use
2) remove function calls from ASSERTs
3) make sure variables are initialized before use
4) check pointers for NULL before dereferencing

Change-Id: Iac92e6f2d1030a7dd12469e34341135bea7c781f
CRs-Fixed: 1047286
(cherry picked from commit a2547fd35fc517abfbc96363768b5d036d59d057)
2016-09-10 19:08:39 -07:00
Service qcabuildsw
60f4f45df3 Merge "qcacld-3.0: Fix u32 paddrs" into wlan-cld3.driver.lnx.1.1-dev 2016-09-10 12:14:09 -07:00
Orhan K AKYILDIZ
5a36de324c qcacld-3.0: Fix u32 paddrs
Fix some remaining u32 paddr references in htt and make sure
that they are defined as qdf_dma_addr_t.
Fix print %x's for such variables, as per printk-formats
document (use %llx and explicitly typecast the vars to uul).

Change-Id: I4bc25e631986d8343a704ac48fb7bdfe1717b396
CRs-Fixed: 1064917
2016-09-08 21:32:40 -07:00
Houston Hoffman
088e4b94ae qcacld-3.0: Use atomic bit ops in ol_tx_desc_dup_detect functions
Bitmasks should use atomic operations when they can be
modified in multiple contexts.  Also sanitize msdu_id length
to avoid potential memory corruption.

Change-Id: I119916dba883ab7aa27d8c42035af5588774f535
CRs-Fixed: 1061195
2016-09-06 17:24:52 -07:00
Himanshu Agarwal
6d4c2be635 qcacld-3.0: Fix 32 bit compilation in IPA path
Compilation error is seen for 32 bit builds in htt_tx_ipa_uc_wdi_tx_buf_alloc
as buffer_paddr, which is defined as unsigned long and will be a 32 bit bit
variable for 32 bit builds, is right shifted by 32 to get the high 32 bits
for fragment descriptor.

Instead of right shifting buffer_paddr by 32, use APIs lower_32_bits
and upper_32_bits.

Change-Id: I283792333075c11219a491d305b2822849c025f3
CRs-Fixed: 1062916
2016-09-06 12:14:16 +05:30
Houston Hoffman
c2c4762062 qcacld-3.0: Use htc_pm_runtime put/get apis
The htc_pm_runtime provide a convenience wrapper arround
the hif modules put/get apis

Change-Id: Ic2ef437390501e269278e68aa3a219364de8b2c0
CRs-Fixed: 1058274
2016-09-05 01:23:18 -07:00
Dhanashri Atre
5e584fa2eb qcacld-3.0: Fix Defrag Address Compare
Fix the address compare operation that is used for defragmentation.
Also add hook to release the debug qdf node.

Change-Id: I782e0234d5b61bb118578788947aa8b13e8e189c
CRs-Fixed: 1059538
2016-09-02 17:24:32 -07:00
Himanshu Agarwal
19141bb676 qcacld-3.0: Add capability based logic to mark first packet after wakeup
Propagation from qcacld-2.0 to qcacld-3.0.

Add a capability in service bitmask to indicate that fw also supports
this feature of marking first packet after wow wakeup to maintain backward
compatibility.

Change-Id: I3d41f5425e3a170c046941a439d17e06df0c6bef
CRs-Fixed: 1021382
2016-08-27 16:02:41 -07:00
Himanshu Agarwal
053d4556d8 qcacld-3.0: Add support to mark first packet after wow wakeup
Propagation from qcacld-2.0 to qcacld-3.0.

Add support to mark the highest bit of the skb->mark for the first
packet after wow wakeup event from firmware

Change-Id: I877dd7af9a58ebc02d73461cc2a29e86a3945dec
CRs-Fixed: 989984
2016-08-27 16:01:58 -07:00
Deepak Dhamdhere
c47cfe8fa7 Revert "qcacld-3.0: Force delete peer entry during LFR3 roaming"
This reverts commit-id: "Ib028c29863d4e95ccac434f7d47bfedd59ef883f"
It caused peer object memory access after it was freed.

CRs-Fixed: 1057347
Change-Id: I99842eb646371e186ade3b126ea0e8f84b7f2187
2016-08-22 12:44:49 -07:00
Nirav Shah
d59b3b253e qcacld-3.0: Log rx packet in packetlog as per rx ind message
Log rx packet in packetlog as per HTT_T2H_MSG_TYPE_RX_IN_ORD_PADDR_IND
message from firmware.

CRs-Fixed: 970647
Change-Id: I5773b67a9269063531d038d46ac404c978818dcc
2016-08-20 10:36:59 -07:00
Nirav Shah
dcc4c875c4 qcacld-3.0: Changes to support WDI_EVENT_SW_EVENT for packetlog
Changes in host to support WDI_EVENT_SW_EVENT for packetlog.

Change-Id: I8936a408a7da21ad293b6da7af146298c049052d
CRs-fixed: 1047382
2016-08-20 10:36:52 -07:00
Deepak Dhamdhere
363c6bc5bf qcacld-3.0: Force delete peer entry during LFR3 roaming
While processing ROAM_OFFLOAD_SYNCH_IND, delete the peer entry
even if reference count is non-zero sine firmware has already
deleted that peer. It allows addition of new peer without waiting
for peer_unmap events. Fix the logic error in checking the timeout
in ol_txrx_peer_attach().

Change-Id: Ib028c29863d4e95ccac434f7d47bfedd59ef883f
CRs-Fixed: 1046754
2016-08-19 19:25:46 -07:00
Mohit Khanna
c6f03989a8 qcacld-3.0: Add USB bus support (DP)
Add datapath changes for USB bus support

Change-Id: Iabb6f5bbfa4d0c2a8026262d2ecb11cdc0533742
CRs-Fixed: 1023663
2016-08-19 18:33:24 -07:00
Mohit Khanna
47384bcd39 qcacld-3.0: fix peer map handler race condition
The existing peer_map_unmap_lock in ol_txrx_peer_find_add_id
does not include call to ol_txrx_peer_unref_delete. The peer addition
handling needs to be atomic with peer reference deletion (in case peer
ref deletion is required).

Move the peer_map_unmap_lock to include ol_txrx_peer_unref_delete.

CRs-Fixed: 1056442
Change-Id: Ica15ea70527f0ea116b960dd7958da73f304288b
2016-08-19 18:33:07 -07:00
Nirav Shah
c657ef50ea qcacld-3.0: Changes to update mac_id in packetlog
Changes to update mac_id in packetlog header
for DBS.

Change-Id: I602d399e1ef34077b5d7bfc867fb60678ed8612c
CRs-fixed: 1047382
2016-08-18 00:41:01 -07:00
Poddar, Siddarth
74178df581 qcacld-3.0: Add argument to ol_tx_queue_free for vdev or peer queues
qcacld-2.0 to qcacld-3.0 propagation

Add additional argument in ol_tx_queue_free to indicate whether
txq is vdev or peer queues to avoid extracting peer_id in case of
vdev txq queue in ol_tx_queue_log_free function.

Change-Id: Ic521c23b4001f15a382e9435413cdafca0c8b49f
CRs-Fixed: 1023457
2016-08-17 17:07:03 -07:00
Poddar, Siddarth
0cec8eaf67 qcacld-3.0: add NULL check and drop rx indication for a frame
qcacld-2.0 to qcacld-3.0 propagation

Add check to handle kernel NULL pointer dereference
during calling ol_rx_reorder_release.

Change-Id: If0367e0a7910d7ee460709fc8ae25ecc6de3485d
CRs-Fixed: 994435
2016-08-17 17:07:01 -07:00
Nirav Shah
5e74bb81d5 qcacld-3.0: Parse tx packets only once in tx datapath
Classify tx packets at one place and store packet type in
skb cb structure to avoid multiple check to determine
packet type at various layers.

Change-Id: Id2ea9b08bdcbc62b1d96d983d19bcf71becc9c42
CRs-Fixed: 1022454
2016-08-17 17:06:28 -07:00
Mohit Khanna
37ffb29390 qcacld-3.0: Fix for race condition in peer map/unmap handlers
In case there are multiple copy engines (for example in ihelium), the
peer map and unmap handlers may be executed on different CPUs
concurrently. These functions access global peer data structures and are
not SMP-safe.

Re-factor the existing code to make it SMP-safe.

Change-Id: I3f52e17a80d7eae8d4c2fb88da7f57f64455b031
CRs-Fixed: 1050653
2016-08-13 14:07:28 -07:00
Orhan K AKYILDIZ
b257bff22b qcacld-3.0: Make rx hash look-up SMP safe
Place a big spinlock on the rxhash so that only one
activity happens on it at a time.

Change-Id: Id1a020f508b6232d401d44da1cd0b9592288c81c
CRs-Fixed: 1048807
2016-08-13 14:07:28 -07:00
Houston Hoffman
5bf7482658 qcacld-3.0: Move memory free out of spinlock in ol_tso_seg_list_deinit
Assign the list to null inside the spinlock such that no one else
can access the free nodes. Then free the list outside of the spinlock.
This spinlock was causing a watchdog bark.

Change-Id: I9a34c8c3ea8451004814bcabfcbb81744d71ec45
CRs-Fixed: 1052458
2016-08-13 14:07:28 -07:00
Mohit Khanna
3aee13142b qcacld-3.0: Debug commit to track peer refcount
Add prints to track how peer->ref_cnt and peer_id_ref_cnt change

Change-Id: I518f58ec053e53ec2d82bcce85f872cd48029c99
CRs-Fixed: 1046458
2016-08-01 12:34:05 -07:00
Himanshu Agarwal
8903461b0f qcacld-3.0: Move QDF_NBUF_UPDATE_TX_PKT_COUNT before freeing netbuf
Propagation from qcacld-2.0 to qcacld-3.0.

Move QDF_NBUF_UPDATE_TX_PKT_COUNT in ol_tx_completion_handler to make
sure that netbuf is not accessed after it is freed.

Change-Id: Ifba9de788b11ce8cb323827d10f8005029609231
CRs-fixed: 1040612
2016-07-29 18:15:17 -07:00
Hardik Kantilal Patel
e9b97ea6ea qcacld-3.0: Address 32 bit specific compilation issue
Fixing 32 bit compliation issues due to improper print
format type.

CRs-Fixed: 1043823
Change-Id: I22330c4598532142f2c84636e7c890dcb4435e70
2016-07-25 00:33:48 -07:00
Leo Chang
bc24e6177e qcacld-3.0: ipa data path bug fix
WDI RX ring size should be larger than RX buffer count
RX2 ring free bug fix
WDI HTT message free bug fix

Change-Id: Ib3dda42ab46d07fab1847e2590d815c851524960
CRs-fixed: 1037977
2016-07-13 13:14:23 -07:00
Dhanashri Atre
41c0d28570 qcacld-3.0: Check inputs during vdev register
Change to ensure that the vdev and txrx operations passed to
data path during vdev registration are valid.

Change-Id: I912194184ae65229ddd7243afa58c56f4579959a
CRs-Fixed: 1035414
2016-07-11 19:27:44 -07:00
Naveen Rawat
c45d162627 qcacld-3.0: Remove IBSS from MAX_IBSS_PEERS macro
Remove IBSS from MAX_IBSS_PEERS, since this is a generic macro.

Change-Id: Ic50205e84890e6a3bda603ad0f54bebfb2a727ea
CRs-Fixed: 1039559
2016-07-11 16:59:53 -07:00
Poddar, Siddarth
21e7bf0a3a qcacld-3.0: Move NULL check before dereferencing pdev
Move NULL check before dereferencing pdev in ol_tx_create_flow_pool

Change-Id: I42398c9473690a0a8f70f35cc7d5aac87c4ec7e7
CRs-fixed: 1034748
2016-07-11 04:59:47 -07:00
Govind Singh
8c46db9759 qcacld-3.0: Correct fw common references in dp layer
FW common files needs to be in sync with host and fw.
Correct fw common references in dp layer with latest copy
of fw common files.

Change-Id: I194c25045ca978634027a94bc74f22253b1afc86
CRs-Fixed: 1012542
2016-07-08 06:12:06 -07:00
Himanshu Agarwal
879a3bec5c qcacld-3.0: Add NULL checks before dereferencing
Add NULL checks before dereferencing in:
1) BMI layer
2) HTT layer
3) EPPING layer.

Change-Id: I9998d4aeb983dc101121a71d791d7ec626e3f5d4
CRs-Fixed: 1036390
2016-07-06 13:30:39 -07:00
Nirav Shah
bf1b033062 qcacld-3.0: Add per CPU interrupt statistics
Add per CPU per copy engine interrupt statistics.

Change-Id: I397733ca9c46274f9b5c0026f032e3345100a98d
CRs-Fixed: 1017437
2016-06-30 14:49:30 +05:30
Leo Chang
cc923e2771 qcacld-3.0: IPA WDI TX buffer allocation on coherent memory
IPA WDI TX buffer should be used by IPA HW/WLAN FWHW during
WLAN activated. This memory is not used by HLOS. Then
coherent memory allocation is better for usage.

Change-Id: Icc96c54aca9fc986c231ac3173f54cf7c7f253aa
CRs-fixed: 1019762
2016-06-29 21:53:13 -07:00
Nirav Shah
da008344a6 qcacld-3.0: Enhance data path related statistics
Enhance data path related statistics
- Add per reason pause time
- Enahnce TSO stats
- clear DPTRACE buffer

Change-Id: Ia59fa5ba326504eb54e14d44f42a335c6b835ee4
CRs-Fixed: 1017437
2016-06-24 14:30:49 -07:00
Siddarth Poddar
b2011f6435 qcacld-3.0: Add txrx apis for High Latency systems (Part 2 - HL Datapath)
Add tx schedular module, tx classify module within the data SW,
tx frame queues logging,  group credit support and
send-recieve tx frames instance for HL system.

CRs-Fixed: 975526
Change-Id: If1655d4d832f88e565ab946ef9e9719f256ab7b1
2016-06-23 12:27:50 -07:00
Siddarth Poddar
1df1cd85b4 qcacld-3.0: Add htt apis for High Latency systems (Part 1 - HL Datapath)
Add support for HTT instance creation, initialization and
deletion, Host -> Target and Target -> Host HTT messages
exchange, receive and transmit aspects of HTT.

CRs-Fixed: 975526
Change-Id: Ie66a83b6efe216df192b033c9d137a93fdce688f
2016-06-23 12:27:43 -07:00
Nirav Shah
2e583a0344 qcacld-3.0: Datapath changes for WiSA specification
Datapath changes for WiSA specification.
- Multicast packets with 50000 as destination
  port should go at 6Mbps.
- Multicast packets with 50001 as destination
  port should go at 24Mbps.

Change-Id: Ic219f58f3e8b2f6863a275928429153defe63b5a
CRs-Fixed: 1010412
2016-06-14 14:28:44 -07:00
Nirav Shah
1da7768385 qcacld-3.0: Remove PROTO_TRACE feature
Remove PROTO_TRACE feature and add MGMT packet
logging in DPTRACE.

Change-Id: I9bc019bb03e703cb8044cb5d4290fd438b1c3e69
CRs-Fixed: 1008087
2016-06-14 14:28:41 -07:00
Nirav Shah
0d58a7ef5f qcacld-3.0: Enhance DPTRACE to support RX path
Enhance DPTRACE to support RX path and
add support for live mode.
Live mode will print info in kmsg and
log it in buffer as well.
To enable live mode use below command.
iwpriv wlan0 dump_dp_trace 1 0

Change-Id: Id309a4d75cec93654b4acac51e5be42eae7f0b35
CRs-Fixed: 1008087
2016-06-14 14:28:38 -07:00
Himanshu Agarwal
a6cedee349 qcacld-3.0: Change unsigned long to uint64_t
Change unsigned long to uint64_t while updating intra bss forwarded
packets count to make sure that the assignment is compatible for all
architectures.

Change-Id: I6bc0e2d7524c117ce199b4a373f541fd06fc9ef8
CRs-Fixed: 996735
2016-06-14 14:28:06 -07:00
Manjunathappa Prakash
c8e756412e qcacld-3.0: Enable DEBUG_Rx_RING_BUFFER to keep track of posted buffers
This enables the tracking of posted rx ring buffers. With this we can
identify if host/fw is wrong when we hit below issue:
"wlan: [0:E :QDF] rx hash: htt_rx_hash_list_lookup: no entry found for"
<physical address>

Change-Id: Ib973a2e2a69e881beddea23cdc1d2d994eeb1e12
CRs-Fixed: 864569
2016-06-14 14:28:02 -07:00
Manjunathappa Prakash
92db771024 qcacld-3.0: Do not modify vdev Rx callback in peer (de)init functions
Do not reset vdev->rx callback in peer modification functions, same vdev
corresponds to multiple peer.
Without this TDLS handshake fails, vdev->rx null callback function
results in dropping of datapath packets.

Change-Id: I39b51d2596cde494bee888009583a42f12a3f068
CRs-Fixed: 1024298
2016-06-14 14:27:59 -07:00
Poddar, Siddarth
27b1a60e64 qcacld-3.0: Add datapath layer changes for sdio bus (Part 4 - HIF SDIO)
Remove bus specific calls from data path layer.
Add sdio specific target address
Add sdio bundling rates in datapath layer.
Fix rx data callback for UMP system.

CRs-Fixed: 969334
Change-Id: I0cd45479ca89b97455b4a9c71ce326646f38a5f3
2016-06-14 14:27:53 -07:00
Dhanashri Atre
5166d573eb qcacld-3.0: Higher 32 bits in the dma address are ignored
In TSO the higher bits in the 64 bit dma address are being ignored.
This is resulting in an incorrect address being programmed in the
fragment descriptor.

Change-Id: Id015e81212d2ded3f0716ca5cc06ae2220952270
CRs-Fixed: 1024169
2016-06-09 22:10:03 -07:00
Himanshu Agarwal
5ac2f7bef9 qcacld-3.0: Refactor intra bss forwarded packets count
Propagation from qcacld-2.0 to qcacld-3.0.

Initially, when a packet is forwarded from txrx layer, it is added in
count only once although the count should increase by 2 as there is one
rx packet and one tx packet that is not getting considered in the hdd
packet count.

Add code to ensure that when packet is forwarded from lower layers,
it get considered accurately in the packet count.

Change-Id: I47bc1e0ecfa2e831438534cf34d37086a306b4e9
CRs-Fixed: 996735
2016-06-06 18:45:27 -07:00
Himanshu Agarwal
8c66df3699 qcacld-3.0: Remove error print from kmsg
Propagation from qcacld-2.0 to qcacld-3.0.

Remove error print from kmsg as this print is unnecessary and
may flood the kmsg.

Change-Id: I0978f88af6677cb0c1e1db5eae7e5d6a69bd4b70
CRs-Fixed: 997243
2016-06-06 18:45:25 -07:00
Himanshu Agarwal
11c874abae qcacld-3.0: Add intra bss forwarded packets count
Propagation from qcacld-2.0 to qcacld-3.0.

In lpm qos voting, no. of packets or bytes sent or received in a
particular amount of time is recorded and decision of disabling
or enabling lpm is done based on that. These packets are recorded
in HDD layer. In case when packets are forwarded to tx only, packets
don't come upto HDD layer and so in case of intra bss forwarding,
lpm qos voting is not being executed appropriately.

Add code to calculate the intra bss forwarded packets in txrx layer
and update them in calculating lpm qos voting.

Change-Id: I805663688cb300c8735b3e2f9680818a7b50bc9f
CRs-Fixed: 990868
2016-06-06 18:45:21 -07:00