Commit graph

581044 commits

Author SHA1 Message Date
cyizhao
7e65ab057d ARM: dts: msm: Set WLED string number for SDM660 QRD
Specify the number of strings in WLED properly according to hardware
connection.

CRs-Fixed: 1108198
Change-Id: I39d3a0ba05a78d0d3204ffb56df64830d0fdedce
Signed-off-by: cyizhao <cyizhao@codeaurora.org>
2017-01-08 17:53:18 -08:00
Linux Build Service Account
08a95e6878 Merge "drm/msm: remove clock framework dependency" 2017-01-08 16:32:11 -08:00
Prasad Sodagudi
adcb849731 arm64: Add TLB conflict fault handler
Add TLB conflict fault handler and try to handle
gracefully. Check whether TLB fault can be handled
by EL2 and cause panic if EL2 is not able to handle.

Change-Id: I276ec5413411932bd8a67ed4c85ebbf66f4affcf
Signed-off-by: Runmin Wang <runminw@codeaurora.org>
Signed-off-by: Prasad Sodagudi <psodagud@codeaurora.org>
2017-01-08 12:56:28 -08:00
Linux Build Service Account
e51c3cc83f Merge "defconfig: msm: compile video drivers as builtins" 2017-01-08 08:05:53 -08:00
Linux Build Service Account
dfa7c4abac Merge "ASoC: wcd934x: Fix out of bounds for mad input value" 2017-01-08 08:05:53 -08:00
Linux Build Service Account
827cd4f6bb Merge "drivers: mfd: Add support for direct apps interrupt" 2017-01-08 08:05:52 -08:00
Linux Build Service Account
99286f0b5d Merge "ARM: dts: msm: add a new panel driver for sdm660 QRD" 2017-01-08 08:05:51 -08:00
Linux Build Service Account
824a1a6d2a Merge "ARM: dts: msm: Enable volume up key for qrd sdm660" 2017-01-08 08:05:50 -08:00
Linux Build Service Account
1f52cde69c Merge "qseecom: Rename clock handle names" 2017-01-08 08:05:46 -08:00
Linux Build Service Account
082aa733d8 Merge "msm: cpp: Fix for integer overflow in cpp" 2017-01-07 23:00:03 -08:00
Linux Build Service Account
96f3cc94dd Merge "media: dvb-core: Fix for dvb_ringbuffer merge conflict" 2017-01-07 13:44:17 -08:00
Linux Build Service Account
fc0faf1b5e Merge "msm: isp: Handle ping pong mismatch error" 2017-01-07 13:44:16 -08:00
Linux Build Service Account
ccf3c89458 Merge "input: move qpnp-power-on driver into input/misc directory" 2017-01-07 05:24:01 -08:00
Linux Build Service Account
ad65eb0904 Merge "ARM: dts: msm: Add support for pwr/perf supply for sdm660" 2017-01-07 05:24:00 -08:00
Linux Build Service Account
2330401695 Merge "spcom: free all SKP ION buffers on SSR" 2017-01-07 05:23:57 -08:00
Linux Build Service Account
8964db0fd5 Merge "clk: qcom: osm: remove ioremaps from panic callback" 2017-01-07 05:23:56 -08:00
John zhao
22f9774b40 sched: add the max_freq comparing for evaluating the mitigation
trace_sched_get_task_cpu_cycles traces max_freq during the tracing of
OSM cycle considering mitigated such as thermal etc.

Change-Id: If134630e293ceaf8faf2aa0ed7d4cfdfe7b3a4d6
CRs-Fixed: 1108711
Signed-off-by: John zhao <yuankuiz@codeaurora.org>
2017-01-07 16:54:38 +08:00
Pavankumar Kondeti
add97fe0da sched: fix a bug in handling top task table rollover
When frequency aggregation is enabled, there is a possibility of
rolling over the top task table multiple times in a single
window.

For example

- utra() is called with PUT_PREV_TASK for task 'A' which does not
belong to any related thread grp. Lets say window rollover happens.
rq counters and top task table rollover is done.

- utra() is called with PICK_NEXT_TASK/TASK_WAKE for task 'B' which
belongs to a related thread grp. Lets say this happens before
the grp's cpu_time->window_start is in sync with rq->window_start.
In this case, grp's cpu_time counters are rolled over and the
top task table is also rolled over again.

Roll over the top task table in the context of current running task
to fix this.

Change-Id: Iea3075e0ea460a9279a01ba42725890c46edd713
Signed-off-by: Pavankumar Kondeti <pkondeti@codeaurora.org>
2017-01-07 13:50:04 +05:30
Pavankumar Kondeti
432662eb4d sched: fix stale predicted load in trace_sched_get_busy()
When early detection notification is pending, we skip calculating
predicted load. Initialize it to 0 so that stale value does not
get printed in trace_sched_get_busy().

Change-Id: I36287c0081f6c12191235104666172b7cae2a583
Signed-off-by: Pavankumar Kondeti <pkondeti@codeaurora.org>
2017-01-07 13:49:22 +05:30
Manikanta Sivapala
0124613ef0 defconfig: msm: compile video drivers as builtins
Video kernel modules as LKM make the T32 debugging difficult.
So, make video drivers as part of boot image.

Change-Id: I229eba78f883d7656ac1bd64487dccc70bb0d43c
Signed-off-by: Manikanta Sivapala <msivap@codeaurora.org>
Signed-off-by: Deepak Kushwah <dkushwah@codeaurora.org>
2017-01-06 22:37:56 -08:00
Manikanta Sivapala
47c3da9b77 ARM: dts: msm: Enable early firmware loading for SDM660
This will ensure that the FW is always loaded and will
save the load time.

CRs-Fixed: 1103405
Change-Id: I40341f50852fb1df418c72fd0fa952af5670be23
Signed-off-by: Manikanta Sivapala <msivap@codeaurora.org>
Signed-off-by: Deepak Kushwah <dkushwah@codeaurora.org>
2017-01-06 22:11:10 -08:00
Siddartha Mohanadoss
c5fd9dbe9d thermal: tsens: Switch from usleep_range() to msleep
On certain cases we have seen usleep_range() return before
the intended minimum time parameter passed to this function.
There is no protection against wakeups and we may return
early. msleep() already has code to handle this cases since
it loops as long as there is still time.

Change-Id: I3cf1e2d7f61f5a6d42d66afb86ae3b3fe141a9e7
Signed-off-by: Siddartha Mohanadoss <smohanad@codeaurora.org>
2017-01-06 16:04:55 -08:00
Derek Chen
97f8286b25 ASoC: msm: qdsp6v2: add support for ADM_OPEN_V6 for multi-mic ec
Add support for ADM_CMD_DEVICE_OPEN_V6 when the mixer path
specifies to use the multi-mic-echo-reference, which configures
the EndPoint2 for Echo Reference.

CRs-fixed: 1022080
Change-Id: I474f39a3437fa18003f4342e003d689b95837699
Signed-off-by: Derek Chen <chenche@codeaurora.org>
2017-01-06 13:38:55 -08:00
Karthikeyan Mani
145c630b36 ASoC: msm: qdsp6v2: Fix out-of-bounds access in put functions
Add out of bounds check in routing put functions
for the mux value before accessing the texts
pointer of soc_enum struct with mux as index.

CRs-fixed: 1097569
Change-Id: If1161ea918680deacc0d322d11f42637f377a9ab
Signed-off-by: Karthikeyan Mani <kmani@codeaurora.org>
2017-01-06 12:26:10 -08:00
David Collins
07f2f9952c input: move qpnp-power-on driver into input/misc directory
Move the qpnp-power-on driver from the drivers/input directory
into the drivers/input/misc directory.  This is the standard
location where other power key drivers are kept.

Also make a small fix to use octal instead of symbolic
permissions for the ship_mode_en module parameter.

Change-Id: I4d80c2ca0f161bd443dbfe0fcef822459c9fe44b
Signed-off-by: David Collins <collinsd@codeaurora.org>
2017-01-06 10:52:46 -08:00
Yan He
642effc4f6 msm: sps: add the checking of userspace input length
Add the checking of the input length from userspace so kernel space
will not copy any content outside the input buffer.

Change-Id: I3cef834ed1df836356ba40e6e950a534ec49819d
Signed-off-by: Yan He <yanhe@codeaurora.org>
2017-01-06 10:27:45 -08:00
Linux Build Service Account
e4e95be265 Merge "ARM: dts: msm: Add an entry to the Silver memlat table for msm8998" 2017-01-06 08:11:50 -08:00
Krishna Chaitanya Devarakonda
c388e8fc06 msm: mdss: Fix panel orientation handling for split displays
For split display panels, when panel has 180 flip or HFLIP,
the source layers needs to be swapped instead of the mixers.
SDM will take care of the source swap and rectangle
recalculations.
This change is to remove the mixer swap, and to expose the panel
flip property through sysfs, so that SDM can flip the source
layers to maintain pipe priority.

Change-Id: I47a7dd38dc1e45dd3f7edbd189c9403900b74eea
Signed-off-by: Krishna Chaitanya Devarakonda <kdevarak@codeaurora.org>
2017-01-06 20:11:12 +05:30
Marty Faltesek
896bb81297 ath10k: cache calibration data when the core is stopped
Commit 0b8e3c4ca29f ("ath10k: move cal data len to hw_params") broke retrieving
the calibration data from cal_data debugfs file. The length of file was always
zero. The reason is:

    static ssize_t ath10k_debug_cal_data_read(struct file *file,
                                          char __user *user_buf,
                                          size_t count, loff_t *ppos)
    {
        struct ath10k *ar = file->private_data;
        void *buf = file->private_data;

This is obviously bogus, private_data cannot contain both struct ath10k and the
buffer. Fix it by caching calibration data to ar->debug.cal_data. This also
allows it to be accessed when the device is not active (interface is down).

The cal_data buffer is fixed size because during the first firmware probe we
don't yet know what will be the lenght of the calibration data. It was simplest
just to use a fixed length. There's a WARN_ON() in
ath10k_debug_cal_data_fetch() if the buffer is too small.

Tested with qca988x and firmware 10.2.4.70.56.

Reported-by: Nikolay Martynov <mar.kolya@gmail.com>
Fixes: 0b8e3c4ca29f ("ath10k: move cal data len to hw_params")
Cc: stable@vger.kernel.org # 4.7+
Signed-off-by: Marty Faltesek <mfaltesek@google.com>
[kvalo@qca.qualcomm.com: improve commit log and minor other changes]
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-01-06 15:59:10 +05:30
Mohammed Shafi Shajakhan
c0466f0d4a ath10k: Ignore SWBA event for a vif if its marked for no beacon
Ignore processing further in SWBA event scheduled for a vif, if mac80211
has marked the particular vif for stop beaconing and brought the vdev
down in 'ath10k_control_beaconing'. This should potentially avoid ath10k
warning/error messages while running continuous wifi down/up with max
number of vaps configured. Found this change during code walk through
and going through other beacon configuration related functions in ath10k

Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qti.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-01-06 15:59:10 +05:30
Wei Yongjun
f3adb5a356 ath10k: fix error return code in ahb
Fix to return a negative error code from the error handling case
instead of 0, as done elsewhere in function ath10k_ahb_probe() or
ath10k_ahb_resource_init().

Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-01-06 15:59:10 +05:30
Ben Greear
0d1f3862c2 ath10k: support up to 64 vdevs
The (1 << x) - 1 trick won't work when you
are trying to fill up all 64 bits, so add special
case for that.

Signed-off-by: Ben Greear <greearb@candelatech.com>
[kvalo@qca.qualcomm.com: remove the sentence about moving limits]
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-01-06 15:59:09 +05:30
Ben Greear
ee506f6cf8 ath10k: document cycle count related counters
They are not necessarily named in an intuitive manner,
so at least add some comments to help the next person.

Signed-off-by: Ben Greear <greearb@candelatech.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-01-06 15:59:09 +05:30
Ben Greear
35f205af90 ath10k: fix typo in logging message
Signed-off-by: Ben Greear <greearb@candelatech.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-01-06 15:59:09 +05:30
Vasanthakumar Thiagarajan
5398a4bf90 ath10k: fix rfc1042 header retrieval in QCA4019 with eth decap mode
Chipset from QCA99X0 onwards (QCA99X0, QCA9984, QCA4019 & future)
rx_hdr_status is not padded to align in 4-byte boundary. Define a
new hw_params field to handle different alignment behaviour between
different hw. This patch fixes improper retrieval of rfc1042 header
with QCA4019. This patch along with "ath10k: Properly remove padding
from the start of rx payload" will fix traffic failure in ethernet
decap mode for QCA4019.

Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qti.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-01-06 15:59:09 +05:30
Masahiro Yamada
13c4268345 ath10k: do not check if reset is NULL
Since reset_control_get() never returns NULL, we can use IS_ERR()
instead of IS_ERR_OR_NULL().  The return statements can be simpler
as well.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-01-06 15:59:09 +05:30
Masahiro Yamada
0084e4e632 ath10k: use devm_reset_control_get() instead of reset_control_get()
Use the managed variant of reset_control_get() to simplify the
failure path and the .remove callback.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-01-06 15:59:09 +05:30
Masahiro Yamada
0b2a53d3d8 ath10k: use devm_clk_get() instead of clk_get()
Use the managed variant of clk_get() to simplify the failure path
and the .remove callback.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-01-06 15:59:08 +05:30
Joe Perches
594c5966ed ath10k: spelling and miscellaneous neatening
Correct some trivial comment typos.
Remove unnecessary parentheses in a long line.

Signed-off-by: Joe Perches <joe@perches.com>
[kvalo@qca.qualcomm.com: drop the change for return]
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-01-06 15:59:08 +05:30
Vasanthakumar Thiagarajan
8a3b24b244 ath10k: remove 4-addr padding related hw_param configuration
hw_4addr_pad was added to handle different types of padding
in 4-address rx frame. But this padding is not very specific
to 4-address, it can happen even with three address + ethernet
decap mode. Since the  padding information can be obtained
through Rx desc for QCA99X0 and newer chips, this hw_param
is not needed any more.

Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qti.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-01-06 15:59:08 +05:30
Vasanthakumar Thiagarajan
6b9e4071c0 ath10k: properly remove padding from the start of rx payload
In QCA99X0 (QCA99X0, QCA9984, QCA9888 and QCA4019) family chips,
hw adds padding at the begining of the rx payload to make L3
header 4-byte aligned. In the chips doing this type of padding,
the number of bytes padded will be indicated through msdu_end:info1.
Define a hw_rx_desc_ops wrapper to retrieve the number of padded
bytes and use this while doing undecap. This should fix padding
related issues with ethernt decap format with QCA99X0, QCA9984,
QCA9888 and QCA4019 hw.

Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qti.qualcomm.com>
[Rename operations to hw_ops for other purposes]
Signed-off-by: Benjamin Berg <benjamin@sipsolutions.net>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-01-06 15:59:08 +05:30
Vasanthakumar Thiagarajan
be5f270756 ath10k: add provision for Rx descriptor abstraction
There are slight differences in Rx hw descriptor information
among different chips. So far driver does not use those new
information for any functionalities, but there is one important
information which is available from QCA99X0 onwards to indicate
the number of bytes that hw padded at the begining of the rx
payload and this information is needed to undecap the rx
packet. Add an abstraction for Rx desc to make use of the
new desc information available. The callback that this patch
defines to retrieve the padding bytes will be used in follow-up
patch.

Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qti.qualcomm.com>
[Rename operations to hw_ops for other purposes]
Signed-off-by: Benjamin Berg <benjamin@sipsolutions.net>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-01-06 15:59:08 +05:30
Vasanthakumar Thiagarajan
be0c3a2985 ath10k: move ath10k_hw_params definition to hw.h
This is to prepare for rx descriptor abstraction where we'll
be dereferencing ath10k_hw_params member in hw.h. Moreover
hw.h looks more suitable to house ath10k_hw_params definition
than core.h

Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qti.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-01-06 15:59:08 +05:30
Ben Greear
ec43571a51 ath10k: improve logging message
Helps to know the sta pointer.

Signed-off-by: Ben Greear <greearb@candelatech.com>
[kvalo@qca.qualcomm.com: add %pK and remove the colon]
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-01-06 15:59:07 +05:30
Thomas Pedersen
cd1bd67343 ath10k: enable peer stats by default
IFTYPE_MESH_POINT need to rely on these for accurate path
selection metrics. Other modes will probably also find
them useful. Enabling peer stats has the side effect of
reducing max number of STAs from 128 to 118. There should
be negligible performance impact.

If users really need 128 STAs and don't mind losing out on
peer stats, they can still disable them:

echo 0 > debugfs/ieee80211/phyn/ath10k/peer_stats

Signed-off-by: Thomas Pedersen <twp@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-01-06 15:59:07 +05:30
Chaehyun Lim
3d0a0c7707 ath10k: remove unused variable ar_pci
Trival fix to remove unused variable ar_pci in ath10k_pci_tx_pipe_cleanup
when building with W=1:
drivers/net/wireless/ath/ath10k/pci.c:1696:21: warning: variable
'ar_pci' set but not used [-Wunused-but-set-variable]

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-01-06 15:59:07 +05:30
Colin Ian King
c8fc66f029 ath10k: fix memory leak on caldata on error exit path
caldata is not being free'd on the error exit path, causing
a memory leak and data definitely should not be freed. Free
caldata instead of data.

Thanks to Kalle Valo for spotting that data should not be
free'd.

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-01-06 15:59:07 +05:30
Ashok Raj Nagarajan
28b29f207b ath10k: fix reporting channel survey data
When user requests for survey dump data, driver is providing wrong survey
information. This information we sent is the survey data that we have
collected during previous user request.

This issue occurs because we request survey dump for wrong channel. With
this change, we correctly display the correct and current survey
information to userspace.

Fixes: fa7937e3d5c2 ("ath10k: update bss channel survey information")
Signed-off-by: Ashok Raj Nagarajan <arnagara@qti.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-01-06 15:59:07 +05:30
Mohammed Shafi Shajakhan
b5b49e0c40 ath10k: remove unnecessary error code assignment
The error assigned does not seems to be used anywhere,
fixes nothing just a small cleanup

Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qti.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-01-06 15:59:07 +05:30
Rajkumar Manoharan
1e6f1b14f1 ath10k: fix throughput regression in multi client mode
commit 7a0adc83f34d ("ath10k: improve tx scheduling") is causing
severe throughput drop in multi client mode. This issue is originally
reported in veriwave setup with 50 clients with TCP downlink traffic.
While increasing number of clients, the average throughput drops
gradually. With 50 clients, the combined peak throughput is decreased
to 98 Mbps whereas reverting given commit restored it to 550 Mbps.

Processing txqs for every tx completion is causing overhead. Ideally for
management frame tx completion, pending txqs processing can be avoided.
The change partly reverts the commit "ath10k: improve tx scheduling".
Processing pending txqs after all skbs tx completion will yeild enough
room to burst tx frames.

Fixes: 7a0adc83f34d ("ath10k: improve tx scheduling")
Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-01-06 15:59:06 +05:30