Commit graph

580038 commits

Author SHA1 Message Date
Sameer Thalappil
58a7b9f532 icnss: Do not collect MSA0 dump during Modem WDOG bite
During modem WDOG bite scenarios, error handlers are not executed
in modem. So Adrastea may not be in reset when SSR notifications
are received in HLOS. Remapping MSA0 during SSR could cause SMMU
fault at Adrastea, as it may be still accessing it. Skip collecting
MSA0 dump in WDOG bite scenarios.

CRs-Fixed: 1102057
Change-Id: I9082d4d40b70d0ca8cc8fbc6aadf14b2f0aedd0c
Signed-off-by: Sameer Thalappil <sameert@codeaurora.org>
2016-12-16 11:53:16 -08:00
Satya Durga Srinivasu Prabhala
ef124ecde2 soc: qcom: ssr: add crash status to know why subsys crashed
In some specific cases, clients may want to know why subsystem
crashed, for example, in case of watch dog bite, subsystem may not
be able to execute error handling. Which would need different code
paths to be exercised on the apps processor.

Change-Id: I073733b8a56b57f14906b25cba08012c2f0b414a
Signed-off-by: Satya Durga Srinivasu Prabhala <satyap@codeaurora.org>
2016-12-16 10:53:56 -08:00
Ard Biesheuvel
4600adf60e arm64: kaslr: fix breakage with CONFIG_MODVERSIONS=y
As it turns out, the KASLR code breaks CONFIG_MODVERSIONS, since the
kcrctab has an absolute address field that is relocated at runtime
when the kernel offset is randomized.

This has been fixed already for PowerPC in the past, so simply wire up
the existing code dealing with this issue.

Change-Id: Ib01e32f2c5cd3d6feff6321a897ed8d276bc3be3
Cc: <stable@vger.kernel.org>
Fixes: f80fb3a3d508 ("arm64: add support for kernel ASLR")
Tested-by: Timur Tabi <timur@codeaurora.org>
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Signed-off-by: Will Deacon <will.deacon@arm.com>
Git-commit: 9c0e83c371cf4696926c95f9c8c77cd6ea803426
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
Signed-off-by: Runmin Wang <runminw@codeaurora.org>
2016-12-16 10:50:18 -08:00
Vinayak Menon
cfc8db22ae mm: vmpressure: make vmpressure window variable
Right now the vmpressure window is of constant size 2MB, which
works well with the following exceptions.
1) False vmpressure triggers are seen when the RAM size is greater
than 3GB. This results in lowmemorykiller, which uses vmpressure
events, killing tasks unnecessarily.
2) Vmpressure events are received late under memory pressure. This
behaviour is seen prominently in <=2GB RAM targets. This results in
lowmemorykiller kicking in late to kill tasks resulting in avoidable
page cache reclaim.

The problem analysis shows that the issue is with the constant size
of the vmpressure window which does not adapt to the varying memory
conditions. This patch recalculates the vmpressure window size at
the end of each window. The chosen window size is proportional to
the total of free and cached memory at that point.

Change-Id: I7e9ef4ddd82e2c2dd04ce09ec8d58a8829cfb64d
Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2016-12-16 20:25:45 +05:30
Laxminath Kasam
fe90883022 pinctrl: qcom: add pinctrl driver for LPI
Low Power Island(LPI) has a GPIO controller which can
support 32 GPIOs, add pinctrl driver to handle GPIOs of LPI.

Change-Id: Id7d5d9a9b3a0ced59e1cc893ce0eb27dab6674a6
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2016-12-16 17:55:29 +05:30
Raju P.L.S.S.S.N
2352f5e1b4 ARM: dts: msm: Enable APSS-RPM communication for msmfalcon
Remove rpm-standalone flag under rpm_bus to allow communication
between APPS and RPM processors for msmfalcon.

Change-Id: I1736dc8a2a34ece02aaec70c867c7a0993fa82c7
Signed-off-by: Raju P.L.S.S.S.N <rplsssn@codeaurora.org>
2016-12-16 17:18:35 +05:30
Srivatsa Vaddagiri
92dc28458c sched: Track average sleep time
Similar to tracking average burst length for tasks, average sleep time
indicates how much a task sleeps on an average before waking up to run.
Very low sleep and burst lengths indicates tasks that could be
sensitive to task-wake latencies and hence should not be packed.

Change-Id: Ife68a9a9a9e596246aab5029f60e41c5bad781e4
Signed-off-by: Srivatsa Vaddagiri <vatsa@codeaurora.org>
Signed-off-by: Pavankumar Kondeti <pkondeti@codeaurora.org>
2016-12-16 16:50:52 +05:30
Srivatsa Vaddagiri
0dee0d1411 sched: Avoid waking idle cpu for short-burst tasks
Introduce sched_short_burst tunable to classify "short-burst" tasks.
These tasks are eligible for packing to avoid overhead associated with
waking up an idle CPU. select_best_cpu() ignores power-cost and selects
the CPU with least wakeup latency which is not loaded with IRQs and
can accommodate this task without exceeding spill limits. The ties are
broken with load followed by previous CPU.

This policy does not affect cluster selection but only CPU selection
in the selected cluster. The tasks eligible for "wakeup-up-idle" and
"boost" are not considered for packing. This policy is applied for
both "fair" and "rt" scheduling class tasks.

Change-Id: I2a05493fde93f58636725f18d0ce8dbce4418a30
Signed-off-by: Srivatsa Vaddagiri <vatsa@codeaurora.org>
Signed-off-by: Pavankumar Kondeti <pkondeti@codeaurora.org>
2016-12-16 16:50:52 +05:30
Srivatsa Vaddagiri
f8c7c6ffdf sched: Track burst length for tasks
Track burst length for tasks as time they ran from wakeup to sleep.
This is used to predict average time a task may run when it wakes up
and thus avoid waking up idle cpu for "short-burst" tasks.

Change-Id: Ie71d3163630fb8aa0db8ee8383768f8748270cf9
Signed-off-by: Srivatsa Vaddagiri <vatsa@codeaurora.org>
Signed-off-by: Pavankumar Kondeti <pkondeti@codeaurora.org>
2016-12-16 16:50:51 +05:30
Manoj Prabhu B
c5b14abc0b diag: Initialize spin lock once per memory device channel
Initialize the spin lock only once per memory device channel
while initializing the channel and channel buffers.

Change-Id: Iabf2db03436102310ef85f04b59e6160d49ef5f5
Signed-off-by: Sreelakshmi Gownipalli <sgownipa@codeaurora.org>
Signed-off-by: Manoj Prabhu B <bmanoj@codeaurora.org>
2016-12-16 16:07:37 +05:30
Sandeep Panda
6a21dcc9bf clk: qcom: add common clock framework support for MDSS PLL
Model and configure MDSS DSI PLL using upstream clock framework
APIs. Add changes to define and register vco, divider, mux clcoks
as per common clock infrastructure.

Change-Id: Idc51070e2bb36d1a757d2714d2875a99901321a7
Signed-off-by: Sandeep Panda <spanda@codeaurora.org>
2016-12-16 15:51:27 +05:30
Mohit Aggarwal
4aaf2b8098 diag: dci: Protect the client list and command entries
Currently, on open and close notification for channels,
the dci clients are updated accordingly. The list
traversal for active dci clients are not mutex protected.
Also searching for command registration in table is not
properly protected. This patch mutex protect the list
traversal and command registration table search to avoid
stale entries.

Change-Id: I015d6674afd605c63cd01ceec0109d9da5462629
Signed-off-by: Mohit Aggarwal <maggarwa@codeaurora.org>
2016-12-16 02:04:17 -08:00
Lei Chen
9d34289a0b clk: msm: hdmi: HDMI 10nm HPG Rev2.0 update
HPG Rev 1.0 is a basic bring up implementation of HDMI PHY/PLL.
This change absorbs the changes upgrade to HPG Rev2.0.

CRs-Fixed: 1033918
Change-Id: I768463aaad17f7be5d3fe11d7ca23d422833cfe5
Signed-off-by: Lei Chen <chenl@codeaurora.org>
2016-12-16 14:59:18 +08:00
Vic Wei
fe4987d544 smb-lib : Fix incorrect VALID_INPUT_POWER_SOURCE_BIT check
In smblib_get_prop_usb_online() and smblib_get_prop_dc_online(),
used incorrect VALID_INPUT_POWER_SOURCE_BIT check. Now change
to VALID_INPUT_POWER_SOURCE_STS_BIT check.

Change-Id: I70489775b2a99afff8b26366758834a98b1ffb30
Signed-off-by: Vic Wei <vwei@codeaurora.org>
CRs-Fixed: 1102132
2016-12-15 22:50:02 -08:00
Srinivas Ramana
8438f379fc arm: Move topology_init to postcore
Move topology_init to postcore initcall  to retrieve
cpu frequency table early in boot from OPP.

Change-Id: If715f611c48e91e360caa58f44e20ee17fcb6948
Signed-off-by: Srinivas Ramana <sramana@codeaurora.org>
2016-12-15 22:42:47 -08:00
Fenglin Wu
c665d840c7 qcom-charger: Add ship mode support
Add POWER_SUPPLY_PROP_SET_SHIP_MODE property to set ship mode. In
ship-mode, the bat-fet is opened and battery is completely disconnected
from the system.

CRs-Fixed: 1092969
Change-Id: Idc50342df8600f482a16f9a2f3a97773c3487eb8
Signed-off-by: Fenglin Wu <fenglinw@codeaurora.org>
2016-12-16 14:05:22 +08:00
Fenglin Wu
2a16792344 power: power_supply: Add property for ship mode
In ship mode the charger module opens the bat-fet and disconnects the
battery from the system. This is for the non-removable battery designs
to avoid them from being discharged when shipped/on-shelf.

The ship mode is enabled during the final stage of power-off typically
from the PON driver. Hence, add property POWER_SUPPLY_PROP_SET_SHIP_MODE
to force the device into ship-mode.

CRs-Fixed: 1092969
Change-Id: I43893355db063d99b6faf965093fad74ec0c9253
Signed-off-by: Fenglin Wu <fenglinw@codeaurora.org>
2016-12-16 13:43:59 +08:00
Johannes Berg
af16d9526a cfg80211: add checks for beacon rate, extend to mesh
The previous commit added support for specifying the beacon rate
for AP mode. Add features checks to this, and extend it to also
support the rate configuration for mesh networks. For IBSS it's
not as simple due to joining etc., so that's not yet supported.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>

Git-commit: 8564e38206de2ff005a27c8d7c2ce3869a44f0dd
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/jberg/mac80211-next.git
CRs-fixed: 1096202
Change-Id: I3bf27dc2f3f5ee035434da96b3b6caeda29bed7b
[pkushwah@codeaurora.org: an additional check for NULL chan in chandef is
added before the validation.
backport to 4.4-This commit includes the changes from following commits
in include/uapi/linux/nl80211.h to compile for msm-4.4.
0c9ca11b1ae8eb16c1b6bbae91991392d2321372 :
cfg80211: Add global RRM capability
c6e6a0c8be575c830a97b1942dabeab70f423fe0 :
nl80211: Add API to support VHT MU-MIMO air sniffer
1d76250bd34af86c6498fc51e50cab3bfbbeceaa :
nl80211: support beacon report scanning ]
Signed-off-by: Purushottam Kushwaha <pkushwah@codeaurora.org>
2016-12-15 20:47:36 -08:00
cyizhao
82cae8c8a6 ARM: dts: msm: Configure GPIO5 for home key for 8998 QRD interposer
GPIO5 on PMI8998 is used for home key on QRD8998HB device, configure it
to input and pull up for GPIO key detection.

CRs-Fixed: 1098764
Change-Id: I3aa8da3222668739042215a55e2a10b582d44c8b
Signed-off-by: cyizhao <cyizhao@codeaurora.org>
2016-12-15 18:03:58 -08:00
Sahitya Tummala
8599d43e8a ARM: dts: msm: Add remote fs device node on msmfalcon
It is needed to enable remote file system on modem processor, which
needs access to store data onto eMMC/UFS device.

The shared memory size used by modem and apps for this purpose is 2MB
on msmfalcon.

Change-Id: Id0cdd7f27b42c261966bb5e92d8229fa234445c4
Signed-off-by: Sahitya Tummala <stummala@codeaurora.org>
2016-12-16 06:50:32 +05:30
Abhijeet Dharmapurikar
7210624955 smb-lib: report FULL regardless of charger presence
For a full battery, the driver currently reports battery full
only when the charger is online and switches back to reporting
discharging when charger is removed.

This is incorrect because a user might reinsert the charger
seeing discharging status right after he removes it only to
realize that the battery is full after he plugs it back.

So allow the full status to be reported even when no charger is
online.

Change-Id: I0c31e2fbe984420a6754e923cfc3abe77bc54991
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
2016-12-15 17:00:45 -08:00
Hemant Kumar
ba3a6e254d sound: usb: Handle audio control interface descriptor properly
usb audio qmi driver is incorrectly passing non-zero alternate
interface related class specific buffer to parse the UAC header.
This is causing driver to respond with incorrect bcdADC value.
Fix this issue by reading the cached audio control interface
context which is saved upon driver probe for the first audio
interface. Also differentiate UAC version of header when type
casting the UAC header descriptor.

Change-Id: Ice62887451e91901cb16a6356b64f554b95eacc4
Signed-off-by: Hemant Kumar <hemantk@codeaurora.org>
2016-12-15 14:25:28 -08:00
Venkat Gopalakrishnan
ef5666862f scsi: ufs-qcom: skip err message for optional clk
Don't print err message for clocks that are optional, this
leads to unnecessary confusion about failure.

Change-Id: Ieb16f2203210963d7035447547b5779fadb17f6d
Signed-off-by: Venkat Gopalakrishnan <venkatg@codeaurora.org>
2016-12-15 11:39:33 -08:00
Jeff Mahoney
3283aeeace Revert "ecryptfs: forbid opening files without mmap handler"
This reverts commit 2f36db71009304b3f0b95afacd8eba1f9f046b87.

It fixed a local root exploit but also introduced a dependency on
the lower file system implementing an mmap operation just to open a file,
which is a bit of a heavy hammer.  The right fix is to have mmap depend
on the existence of the mmap handler instead.

Change-Id: I78753c9cadef7b43cd277d4827a096b45697c288
Signed-off-by: Jeff Mahoney <jeffm@suse.com>
Cc: stable@vger.kernel.org
Signed-off-by: Tyler Hicks <tyhicks@canonical.com>
Git-repo: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git
Git-commit: 78c4e172412de5d0456dc00d2b34050aa0b683b5
Signed-off-by: Dennis Cagle <d-cagle@codeaurora.org>
2016-12-15 10:30:19 -08:00
Andrey Markovytch
0ea43de288 ext4 crypto: added support for O_DIRECT flag
In case of HW FBE, O_DIRECT flag can be supported since FS is not
required for crypto operations

Change-Id: I2e6a7abb56f0e3efdf314a57db131837d029de2e
Signed-off-by: Andrey Markovytch <andreym@codeaurora.org>
2016-12-15 06:38:04 -08:00
Vijayavardhan Vennapusa
442026d990 ARM: dts: msm: Update MPM pin mappings for USB for msmfalcon
Update required MPM pin mappings for USB for msmfalcon for remote wakeup
to be working during system suspend.

Change-Id: I26893b0d5974e8aff3c2ed7147560ba113af0155
Signed-off-by: Vijayavardhan Vennapusa <vvreddy@codeaurora.org>
2016-12-15 17:26:00 +05:30
Preetam Singh Ranawat
1dff02e08e ASoC: msm: fix ULL playback over a2dp
ULL playback is not working over a2dp.

Add DAPM widget in routing driver for ULL playback
over SLIM_7_RX backend.

CRs-Fixed: 1101825
Change-Id: I9a9bcbf52ccb1f48b4e37e674a29c8c312b5ba1a
Signed-off-by: Preetam Singh Ranawat <apranawat@codeaurora.org>
2016-12-15 03:03:12 -08:00
Wei Ding
7dcadefa9c msm: camera: add logic to support sensor compatibility
Add logic to support sensor compatibility to fix same
slave address of sensor but different modules on one platform.

Change-Id: I6c6721e8ff890feaf2d618c8170e346367a68c28
Signed-off-by: penliu <pengfeiliu@codeaurora.org>
Signed-off-by: Wei Ding <weiding@codeaurora.org>
2016-12-15 00:14:53 -08:00
Harry Yang
841179fa16 ARM: dts: msm: set boost current threshold on PMI8998
A boost current threshold will be referenced in deciding
optimal boost switching frequency for efficiency.

CRs-Fixed: 1095917
Change-Id: I1e738e66cdfb72305dd4256dc0a6e05b03de585e
Signed-off-by: Harry Yang <harryy@codeaurora.org>
2016-12-15 00:00:41 -08:00
Harry Yang
e18221c7d0 qcom-charger: set optimal boost switching frequency
Currently, the default boost switching frequency is fixed at 800KHz,
which shows low efficiency in low USB load.

To improve it, only use the default 800KHz when boost current goes
above 100mA; otherwise, switch to 2MHz.

CRs-Fixed: 1095917
Change-Id: Iebb62303febfb78738ada4553fdb9b9eb4810ed5
Signed-off-by: Harry Yang <harryy@codeaurora.org>
2016-12-14 23:59:57 -08:00
Abinaya Selvaraj
5dd85a95f8 ARM: dts: msm: Add NFC device node for msm8998 QRD platforms
Add NFC device tree node for msm8998 QRD VR1 and SKUK
platforms. Add PMIC GPIO configurations associated with it.

Change-Id: I5b265ecd403bf09924ae6c58e56171f3a4d7e3d7
Acked-by: Umesh Jagga <ujagga@qti.qualcomm.com>
Signed-off-by: Abinaya Selvaraj <abinayas@codeaurora.org>
2016-12-15 09:55:13 +05:30
Walter Yang
23a11e9c28 ASoC: wcd-mbhc: check HPH PA status before impedance detection
If HPH PA is on, the result of impedance detection is not
reliable. So check the HPH PA status before impedance detection.

CRs-Fixed: 1100622
Change-Id: I9c2063011247cca8105b39c913633cd7619a89eb
Signed-off-by: Walter Yang <yandongy@codeaurora.org>
2016-12-14 19:00:41 -08:00
Syed Rameez Mustafa
3366a508ff Revert "sched/cputime: Fix steal time accounting vs. CPU hotplug"
This reverts commit 2a8225ef46
("sched/cputime: Fix steal time accounting vs. CPU hotplug").

The commit introduces a bug in scheduler book-keeping whereby if a CPU
is hotplugged out for a small duration of time, subsequent time spent
executing tasks gets mis-attributed to interrupts. This in turn results
in unfair scheduling whereby a task can keep executing for a very long
time without any update to it's vruntime. This revert has no side
effects for msm based systems.

Change-Id: Ibb506824c4223551bceb449594ac99f9dfd8064b
Signed-off-by: Syed Rameez Mustafa <rameezmustafa@codeaurora.org>
2016-12-14 14:56:27 -08:00
Qidan He
b9e5da8b6f net: ping: Fix stack buffer overflow in ping_common_sendmsg()
In ping_common_sendmsg(), when len < icmph_len, memcpy_fromiovec()
will access invalid memory because msg->msg_iov only has 1 element
and memcpy_fromiovec() attempts to increment it. KASAN report:

BUG: KASAN: stack-out-of-bounds in memcpy_fromiovec+0x60/0x114 at addr ffffffc071077da0
Read of size 8 by task trinity-c2/9623
page:ffffffbe034b9a08 count:0 mapcount:0 mapping:          (null) index:0x0
flags: 0x0()
page dumped because: kasan: bad access detected
CPU: 0 PID: 9623 Comm: trinity-c2 Tainted: G    BU         3.18.0-dirty #15
Hardware name: Google Tegra210 Smaug Rev 1,3+ (DT)
Call trace:
[<ffffffc000209c98>] dump_backtrace+0x0/0x1ac arch/arm64/kernel/traps.c:90
[<ffffffc000209e54>] show_stack+0x10/0x1c arch/arm64/kernel/traps.c:171
[<     inline     >] __dump_stack lib/dump_stack.c:15
[<ffffffc000f18dc4>] dump_stack+0x7c/0xd0 lib/dump_stack.c:50
[<     inline     >] print_address_description mm/kasan/report.c:147
[<     inline     >] kasan_report_error mm/kasan/report.c:236
[<ffffffc000373dcc>] kasan_report+0x380/0x4b8 mm/kasan/report.c:259
[<     inline     >] check_memory_region mm/kasan/kasan.c:264
[<ffffffc00037352c>] __asan_load8+0x20/0x70 mm/kasan/kasan.c:507
[<ffffffc0005b9624>] memcpy_fromiovec+0x5c/0x114 lib/iovec.c:15
[<     inline     >] memcpy_from_msg include/linux/skbuff.h:2667
[<ffffffc000ddeba0>] ping_common_sendmsg+0x50/0x108 net/ipv4/ping.c:674
[<ffffffc000dded30>] ping_v4_sendmsg+0xd8/0x698 net/ipv4/ping.c:714
[<ffffffc000dc91dc>] inet_sendmsg+0xe0/0x12c net/ipv4/af_inet.c:749
[<     inline     >] __sock_sendmsg_nosec net/socket.c:624
[<     inline     >] __sock_sendmsg net/socket.c:632
[<ffffffc000cab61c>] sock_sendmsg+0x124/0x164 net/socket.c:643
[<     inline     >] SYSC_sendto net/socket.c:1797
[<ffffffc000cad270>] SyS_sendto+0x178/0x1d8 net/socket.c:1761
Memory state around the buggy address:
 ffffffc071077c80: f3 f3 f3 f3 00 00 00 00 00 00 00 00 00 00 f1 f1
 ffffffc071077d00: f1 f1 04 f4 f4 f4 f2 f2 f2 f2 04 f4 f4 f4 f2 f2
>ffffffc071077d80: f2 f2 00 00 f4 f4 f2 f2 f2 f2 00 00 00 00 00 00
                               ^
 ffffffc071077e00: 00 f4 f2 f2 f2 f2 00 00 00 00 00 00 00 00 00 00
 ffffffc071077e80: 00 00 00 00 00 00 f3 f3 f3 f3 00 00 00 00 00 00

Bug: 31349935
Change-Id: Ib7385fc26dfe7e07e9bab42a10ff65a37cbaab54
Signed-off-by: Siqi Lin <siqilin@google.com>
Git-repo: https://android.googlesource.com/kernel/msm
Git-commit: 5459140fb7c8cbb588e06dadb4dc721f0d115c53
Signed-off-by: Dennis Cagle <d-cagle@codeaurora.org>
2016-12-14 13:57:36 -08:00
Osvaldo Banuelos
2d5df4af1a clk: msm: clock-osm: fix read-modify-write for LLM volt vote register
Currently, LLM_INTF_DCVS_DISABLE register is written values
directly instead of doing a read-modify-write. Fix this.

CRs-Fixed: 1101488
Change-Id: I1f99dc4b37e809cdc6fb4cafe7fb0b6d585cbd76
Signed-off-by: Osvaldo Banuelos <osvaldob@codeaurora.org>
2016-12-14 12:17:00 -08:00
Runmin Wang
cf58ac692b defconfig: msm: disable AIO support for msm8998
Disable the aio interface as we do not use this for performance
benefits.

Change-Id: Ibbe1845c673f3a422b013d17492790c79c78d076
Signed-off-by: Runmin Wang <runminw@codeaurora.org>
2016-12-14 11:07:41 -08:00
Harry Yang
cfd44286e5 qcom-charger: smblib: drop the BOOST PFM Threshold change
The original change to set 200mV boost PFM threshold at request
of a HW workaround is no longer needed, set as default now in
SBL.  Remove it.

CRs-Fixed: 1095917
Change-Id: I4e041dafa83d935a5c16c96bea7a3ea488e80d87
Signed-off-by: Harry Yang <harryy@codeaurora.org>
2016-12-14 10:52:37 -08:00
Skylar Chang
c5301546e5 msm: ipa: fix split packet handling
Fix packet handling in case packet received from IPA hardware
is scattered across multiple buffers.

Change-Id: I4935ecb8eaa438d259c1c27a66f62c78f874c9ee
CRs-Fixed: 1097420
Acked-by: Ady Abraham <adya@qti.qualcomm.com>
Signed-off-by: Skylar Chang <chiaweic@codeaurora.org>
2016-12-14 09:11:17 -08:00
Hareesh Gundu
6b8b2d1a05 msm: kgsl: Get pages from the system incase mempool is not configured
Allow driver to get pages from the system incase mempool configuration
is not defined from the device tree. This will fix kgsl driver probe
failure for without gpu mempool configuration devices.

Change-Id: I3142a5d2e13ed40f643c91594fd868c37620ce54
Signed-off-by: Hareesh Gundu <hareeshg@codeaurora.org>
2016-12-14 09:01:22 -08:00
Rama Krishna Phani A
884c1cb85a hwmon: qpnp-adc: Initialize variables in get_devicetree function
Properly initialize variables at the time of declaration.

Change-Id: I6eab6b08cb9ec7bfa6523ab3ed66d086eab89544
Signed-off-by: Rama Krishna Phani A <rphani@codeaurora.org>
2016-12-14 20:00:12 +05:30
Gaurav Kohli
90491d775b ARM: dts: msm: Update smem id of CDSP PIL for MSMFALCON
Update smem id of CDSP PIL for MSMFALCON.

Change-Id: I8d76958b07d5cdd9f139bba21eae00e676bc9d96
Signed-off-by: Gaurav Kohli <gkohli@codeaurora.org>
2016-12-14 18:39:56 +05:30
Gaurav Kohli
f03bf11b39 ARM: dts: msm: Remove write of acc register for MSMFalcon/Triton/8998
Remove the write of acc strap register by default value during Q6 reset
as per Hardware Programming Guide.

Change-Id: Id5b8aaae0783893290e95626b394841a7d3808a3
Signed-off-by: Gaurav Kohli <gkohli@codeaurora.org>
2016-12-14 17:22:21 +05:30
Ajay Agarwal
fc6f256ae8 usb: gadget: Add DPL support using IPA over BAM2BAM
This change adds DPL support using IPA over BAM2BAM.
Initialises two instances of the RmNet Opts structure,
one for RmNet itself and one for DPL. Uses APIs for
QTI and IPA support from RmNet driver.

Change-Id: I76e0c86643331b9623d634bb462faaeb816c0935
Signed-off-by: Ajay Agarwal <ajaya@codeaurora.org>
2016-12-14 17:15:18 +05:30
Vijayavardhan Vennapusa
48f731aacb ARM: dts: msm: Add QMP PHY init sequence for msmfalcon
Add required QMP PHY initialization sequence for msmfalcon for
USB SS mode working.

Change-Id: I14a9f7a1079956efcb3b31ffeca1235a62856bf5
Signed-off-by: Vijayavardhan Vennapusa <vvreddy@codeaurora.org>
2016-12-14 16:10:59 +05:30
Gaurav Kohli
19740f9d53 soc: qcom: pil-q6v5: Update the reset sequence for qdspv62.1.2/1.5
Update the reset sequence to read each write while enabling QDSP6 memory
bank one at a time. This will make sure whether write is complete or not.
Also add logs during Mss shutdown, It will help to debug Mss restart
and shutdown case.

Change-Id: I9f2cb058a7e59b573fc64662ee7b5bff49b18ea7
Signed-off-by: Gaurav Kohli <gkohli@codeaurora.org>
2016-12-14 01:02:53 -08:00
Amir Samuelov
28d23d4d79 spcom: check size before calling copy_to_user()
Calling copy_to_user(to, from, size) with negative value
might cause heap overflow since size is unsigned parameter
and negative value is cast to big unsigned value.

CRs-Fixed: 1092683
Change-Id: I9b4a0710aa33942de2976f7ee158a8025dd6a20e
Signed-off-by: Amir Samuelov <amirs@codeaurora.org>
2016-12-13 22:26:38 -08:00
Vijayavardhan Vennapusa
e6b5a58c7d USB: composite: Send stall when no config is active
Whenever composition switch happens, android driver stops data transfers &
removes configuation before disabling pullup. Due to this, there is small
window during which pullup is active and device ends up sending device
descriptor with zero confiurations in certain scenarios of Host PC reboot.
Hence fix the issue by stalling control endpoint in this scenario.

Change-Id: I3d3c0321d9311617c6ee492c55809f36de6ae412
Signed-off-by: Vijayavardhan Vennapusa <vvreddy@codeaurora.org>
Signed-off-by: Chandana Kishori Chiluveru <cchiluve@codeaurora.org>
2016-12-13 21:02:32 -08:00
Vijayavardhan Vennapusa
d4d45536ae usb: gadget: composite: Add spinlock protection for usb config descriptor
During composition switch, android driver stops data transfers first and
removes configuration before disabling pullup for USB3 controller. With
this sequence there is a possibility for a race where usb_remove_config is
in progress during which pullup is active and sending the setup request for
configuration descriptor with zero configuration value. Hence fix the issue
by adding spinlock protection for get_config descriptor.

CRs-Fixed: 1052608
Change-Id: I65d38387f77addc9a8894a74f427d97313f90a9e
Signed-off-by: Vijayavardhan Vennapusa <vvreddy@codeaurora.org>
Signed-off-by: Chandana Kishori Chiluveru <cchiluve@codeaurora.org>
2016-12-13 20:58:03 -08:00
Vijayavardhan Vennapusa
7d36ce0b84 Revert "USB: dwc3-msm: Enable power event irq in case of host bus suspend"
Commit 3dd2172dfecc ("USB: dwc3-msm: Enable power event irq in case of
host bus suspend") is added to enable power_event_irq during host bus
suspend. This is to map MPM pin for DM to power_event_irq to wakeup during
system suspend in host mode. Currently MPM driver has support for mapping
multiple MPM pins to single IRQ. Hence it is not required to enable
power_event_irq during host bus suspend.

Change-Id: I5c7d6b4d43baa0b387342a8bd261361a5c07fe23
Signed-off-by: Vijayavardhan Vennapusa <vvreddy@codeaurora.org>
2016-12-13 20:55:37 -08:00
Vijayavardhan Vennapusa
98eba6ebf2 USB: gadget: f_qdss: Add proper checks in usb_qdss_close()
On qdsss channel close, driver is dequeuing endless request without
checking whether qdss is active or not. This might crash if qdss channel
is closed when non QDSS composition is active. Fix the issue by having
proper checks and if qdss is not active, just return without performing
dequeue operation.

Change-Id: I667ea843f77794e9384c22ece218853331751db6
Signed-off-by: Vijayavardhan Vennapusa <vvreddy@codeaurora.org>
Signed-off-by: Chandana Kishori Chiluveru <cchiluve@codeaurora.org>
2016-12-13 20:55:21 -08:00