Commit graph

602557 commits

Author SHA1 Message Date
Padmanabhan Komanduru
423d0998bb ARM: dts: msm: enable dynamic bit clock for SDM660 MTP panel
Add DT properties to enable support for dynamic DSI bit clock
feature on NT35597 dual DSI video mode panel on SDM660.

Change-Id: I9b382a7a79ba546c8f99889a5a14d2733ea8771f
Signed-off-by: Padmanabhan Komanduru <pkomandu@codeaurora.org>
2018-12-26 07:58:26 +01:00
Padmanabhan Komanduru
22e10c082a msm: mdss: add support to switch the DSI clock dynamically
Add change to support changing the DSI bit clock dynamically
for video mode panels. This helps to avoid interference of
DSI clock with other subsystems runtime.

Change-Id: I05790a6dd9d8a2fc3cf31727d032e5220d6164e5
Signed-off-by: Padmanabhan Komanduru <pkomandu@codeaurora.org>
2018-12-26 07:58:26 +01:00
Padmanabhan Komanduru
8a2a881b50 ARM: dts: msm: add DT properties for dynamic refresh for SDM660/SDM630
Add the DT properties in DSI controller/PLL nodes/memory nodes which
are needed for supporting dynamic refresh feature for SDM660/SDM630.

Change-Id: Iccfaf219705de28eb4bd721987075eab09b0120f
Signed-off-by: Padmanabhan Komanduru <pkomandu@codeaurora.org>
2018-12-26 07:54:00 +01:00
Padmanabhan Komanduru
16f501e1ac clk: qcom: mdss: add support for dynamic refresh on DSI 14nm PLL
Add CLK_SET_RATE_NO_REPARENT flag for the software mux clocks in
DSI 14nm PLL driver which is needed for dynamic refresh feature.
Update the dynamic fps structure to align the PLL codes with
vco frequency instead of fps.

Change-Id: I533f615ce51be7229171b6accac3f14ab2dca949
Signed-off-by: Padmanabhan Komanduru <pkomandu@codeaurora.org>
2018-12-26 07:54:00 +01:00
Amine Najahi
c6077ea2a2 fbdev/msm: sanitize debugfs inputs when reading mdp memory
Sanitize debugfs inputs to only allow access to mdp memory block
specified in dtsi file. This change will allow only one single block
to be read at the time and will avoid accessing memory outside of valid
decode space which can trigger AHB error bus response.

Change-Id: Icede9a8939a66faa59d674c18183fb0ebcf67908
Signed-off-by: Amine Najahi <anajahi@codeaurora.org>
2018-12-26 07:54:00 +01:00
Mohammed Javid
1d0bfe3b3e msm: ipa: Protect ipa default routing table
Protect ipa default routing table from
addition, deletion and modification once after
default rule added by ipa-driver.

Change-Id: I045d9c29fed23edf796d826e440b81124e1f666a
Signed-off-by: Mohammed Javid <mjavid@codeaurora.org>
2018-12-26 07:54:00 +01:00
Vipin Deep Kaur
53d41a76e1 i2c-msm-v2: Handle Null pointer de-reference
Zero message may be passed causing null pointer de-reference.
Adding check on the number of messages passed to handle the issue.

Change-Id: I7cef6dd2070c5eaaa748698c45540f8aa1d96116
Signed-off-by: Vipin Deep Kaur <vkaur@codeaurora.org>
2018-12-26 07:54:00 +01:00
Fei Mao
a430609f8f ARM: dts: msm: remove HOME gpio key for qrd devices
For qrd devices, remove HOME gpio key to fix driver probe issue.

Change-Id: I46ba4ef05c795fced67f2db59a3f5ce183bdeba8
Signed-off-by: Fei Mao <feim1@codeaurora.org>
2018-12-26 07:54:00 +01:00
Liam Mark
062f85fd05 ion: Ensure non-HLOS memory cannot be mapped by CPU
Currently it is possible for an ION client to allocate non-HLOS memory
(ie memory which isn't assigned to the HLOS vmid), map this memory, and
then attempt to access this memory from the CPU.
Attempting to access non-HLOS memory from the CPU will cause a
stage-2 fault.

Fix ION so that non-HLOS memory cannot be mapped by the CPU.

Change-Id: Ifb51de2eabc076cddc744c13f01ef97b4a7c6874
Signed-off-by: Liam Mark <lmark@codeaurora.org>
2018-12-26 07:54:00 +01:00
Ajay Agarwal
140713e20e usb: dwc3-msm: Release PM wakelock in host mode only for auto targets
Currently the driver releases PM wakelock in host mode. This
causes pm_suspend to get triggered. Although pm_suspend bails out
but xhci_bus_suspend transitions the bus to a bad state leading
to host mode failure.
Fix this by releasing wakelock only for targets on which we allow
PM suspend in host mode irrespective of runtimePM.

Change-Id: I6648991272c0f22b032b526bce3a76864fec63a5
Signed-off-by: Ajay Agarwal <ajaya@codeaurora.org>
2018-12-26 07:54:00 +01:00
Laxminath Kasam
74157fe0fb soc: soundwire: Fix wsa mute issue for stereo playback
When stereo playback start and temperature read
initiated at same time, one of speaker PA bits are
not set in particular race scenario. Handle the
broadcast check in soundwire framework to ensure
broadcast is disabled only when respective gr_sid
slave calls swr_remove_from_group.

CRs-Fixed: 2282230
Change-Id: I6f82a8c3c0f39dc20c1def09c1728ce4c26c2f5d
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2018-12-26 07:53:59 +01:00
Laxminath Kasam
6ab53a6bd6 soc: swr-wcd-ctrl: Fix wsa mute issue for stereo playback
When temperature on a single wsa881x device is being read,
then soundwire master wakes up both wsa881x devices but
regcache_sync is happening only for one wsa881x device on
which the temperature is being read. This results in
audio playback mute after temperature read. Fix the
regcache sync during temperature read and playback usecase.

CRs-Fixed: 2282230
Change-Id: I856b96517c629ac685bbc25caabee841037106c8
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2018-12-26 07:53:59 +01:00
Laxminath Kasam
9da7997716 ASoC: wsa881x: Fix regcache sync issue during playback
When temperature on a single wsa881x device is being read,
then soundwire master wakes up both wsa881x devices but
regcache_sync is happening only for one wsa881x device on
which the temperature is being read. This results in
audio playback mute after temperature read. Fix the
regcache sync during temperature read and playback usecase.

CRs-Fixed: 2282230
Change-Id: I054f4432d7ae7bce922341ad62b20544cccd5865
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2018-12-26 07:53:58 +01:00
Anurag Chouhan
b025cdfd53 icnss: Add check for rejuvenate in fw_down
Currently, fw_down is not getting set in case of rejuvenate
since the qmi server never exit or arrive in case of rejuvenate.
Add ICNSS_REJUVENATE flag to take care of rejuvenate.

Change-Id: If85e8048cbad9a15e1c94af1c8d0012e004e6150
Signed-off-by: Anurag Chouhan <achouhan@codeaurora.org>
2018-12-26 07:53:57 +01:00
liochen
8148b9d900 Synchronize codes for OnePlus5 & 5T OxygenOS 9.0.0
kernel device tree source code for OnePlus 5 & 5T P device

Change-Id: I84f40e66833ea1ce30eb1d9a710d6e1529e9e637
2018-12-26 11:02:39 +08:00
Tharun Kumar Merugu
19194c8ef8 msm: adsprpc: allocate all remote memory in kernel
Allocate all memory given to remote subsystem in the kernel
instead of mapping memory allocated in userspace.

Change-Id: I79c1f40d426e271403afa67514714fe6af26cf4e
Acked-by: Thyagarajan Venkatanarayanan <venkatan@qti.qualcomm.com>
Signed-off-by: Tharun Kumar Merugu <mtharu@codeaurora.org>
2018-12-24 01:34:01 -08:00
Linux Build Service Account
3828b1c330 Merge f2f687dfa1 on remote branch
Change-Id: I89822242cfeeb7ba1f57e01dece5cda71dcfae25
2018-12-23 01:15:58 -08:00
Abhishek Abbanaveni
3a1e5f4ce9 msm: camera: Fix for OOB security CR
If user passes an aribitary command with _IOC_DIR(cmd) == _IOC_NONE,
"arg" should point to any arbitrary address.

Check for invalid command and return error.

Change-Id: If60191a07bb80939af2d471a5acf1b17dd68aa58
CRs-Fixed: 2299567
Signed-off-by: Abhishek Abbanaveni <aabban@codeaurora.org>
2018-12-23 00:02:21 -08:00
Linux Build Service Account
b9806258a2 Merge "msm: camera: Fix for OOB security CR" 2018-12-21 04:35:58 -08:00
Linux Build Service Account
088a3bfea3 Merge a590550e57 on remote branch
Change-Id: Ic26420b5dbd86f96c3a81c2a093804abdae572ec
2018-12-21 03:42:18 -08:00
Abhishek Abbanaveni
bb6a5a5148 msm: camera: Fix for OOB security CR
If user passes an aribitary command with _IOC_DIR(cmd) == _IOC_NONE,
"arg" should point to any arbitrary address.

Check for invalid command and return error.

Change-Id: If60191a07bb80939af2d471a5acf1b17dd68aa58
CRs-Fixed: 2299567
Signed-off-by: Abhishek Abbanaveni <aabban@codeaurora.org>
2018-12-20 21:01:57 -08:00
Linux Build Service Account
f2f687dfa1 Merge "msm: camera: Fix invalid type conversion" 2018-12-20 20:26:14 -08:00
Linux Build Service Account
5dcebc91f4 Merge "msm: ais: Fix for OOB security CR" 2018-12-20 20:26:13 -08:00
Linux Build Service Account
e0eeefd674 Merge "drm/msm/sde: sanitize debugfs inputs when reading mdp memory" 2018-12-20 20:26:11 -08:00
Abhishek Abbanaveni
6a3cde9d17 msm: camera: Fix invalid type conversion
Invalid type conversion with x64 bit command VIDIOC_MSM_LASER_LED_CFG
passed in,for which the type should be "msm_laser_led_cfg_data_t"

Change-Id: I43e112224c612fb5390fa5fc23e8ae9c0e553288
CRs-Fixed: 2299699
Signed-off-by: Abhishek Abbanaveni <aabban@codeaurora.org>
Signed-off-by: E V Ravi <evenka@codeaurora.org>
2018-12-20 11:22:54 -08:00
Linux Build Service Account
e5e5f57a02 Merge "ARM: dts: msm: Remove Out-of-Bound access" 2018-12-20 11:22:20 -08:00
E V Ravi
f4cc27b8cd msm: ais: Fix for OOB security CR
If the user passes the arbitrary command with _IOC_DIR(cmd) == _IOC_NONE,
"arg" should point to any arbitrary address.
Check for invalid command and return error.

CRs-Fixed: 2299567
Change-Id: Ibd77adfe53ef0777ff4eb96c914e21f43dfd6749
Signed-off-by: E V Ravi <evenka@codeaurora.org>
2018-12-20 11:17:42 -08:00
Amine Najahi
a72d8d872d drm/msm/sde: sanitize debugfs inputs when reading mdp memory
Sanitize debugfs inputs to only allow access to mdp memory block
specified in dtsi file. This change will allow only one single block
to be read at the time and will avoid accessing memory outside of valid
decode space which can trigger AHB error bus response.

Change-Id: I91b91ac2b31eac4facb0c402c92ed8fcfc01d91e
Signed-off-by: Amine Najahi <anajahi@codeaurora.org>
2018-12-20 11:04:46 -08:00
Hardik Arya
c3852a5d61 diag: Mark Buffer as NULL after freeing
There is a possibility of use-after-free and
double free because of not marking buffer as
NULL after freeing. The patch marks buffer
as NULL after freeing in error case.

Change-Id: Iacf8f8a4a4e644f48c87d5445ccd594766f2e156
Signed-off-by: Hardik Arya <harya@codeaurora.org>
2018-12-19 01:31:51 -08:00
Teng Fei Fan
7f1241f188 ARM: dts: msm: Add initial dts support for SDM455 RCM devices
Add initial device trees for SDM455 RCM devices for both external
and internal codec variant.

Change-Id: Idd6034727acc8b9ef600da421963becf5f2305cd
Signed-off-by: Teng Fei Fan <tengfei@codeaurora.org>
Signed-off-by: Maria Yu <aiquny@codeaurora.org>
Signed-off-by: Tengfei Fan <tengfeif@codeaurora.org>
2018-12-17 02:34:41 -08:00
Linux Build Service Account
12e1988e9a Merge "msm: ipa3: fix holb sequence for SSR" 2018-12-13 23:13:22 -08:00
Linux Build Service Account
87b7ba44f5 Merge "msm: camera: isp: Reset request queue at stop" 2018-12-13 15:20:36 -08:00
Linux Build Service Account
5cbc009fef Merge "msm: camera: isp: Handle frame drop due to delay " 2018-12-13 15:20:34 -08:00
Meera Gande
475b454dd2 msm: camera: isp: Reset request queue at stop
In few scenarios where the buffers are not
queued from HAL, request queue overflow is seen.
Added changes to reset the queue at destroy and
when the buffer is not available to process.

Change-Id: I7239175dda9cbc26fb65f568cbc5f7183ceaa24d
Signed-off-by: Meera Gande <mgande@codeaurora.org>
2018-12-13 06:25:56 -08:00
Meera Gande
8d4b7f9a0e msm: camera: isp: Fix drop frame due to reg update miss
In few scenarios, where the register update ioctl is
missed, the handling of frame drop is not working
in such scenarios as the frame drop pattern is not
set correctly. Once the epoch handling is done,
we need to re-configure the buffer and pattern.

Change-Id: I87b2cecda7e7e1addc68511dad6a80498051f87a
Signed-off-by: Meera Gande <mgande@codeaurora.org>
2018-12-13 06:20:18 -08:00
Meera Gande
5bf83ce8c3 msm: camera: isp: Handle frame drop due to delay
In few scenarios, the request frame may get
delayed and current and request frame id may
become same. To handle such scenarios, made
changes to inform user to delay a frame and
process the request.

Change-Id: I31fa04c386922c48a043c511a163c76316e21987
Signed-off-by: Meera Gande <mgande@codeaurora.org>
2018-12-13 06:11:21 -08:00
Skylar Chang
34e75f5628 msm: ipa3: fix holb sequence for SSR
The correct sequence for enabling HOLB drop is first
to suspend the pipe and then to HOLB drop.

Change-Id: I78b7b268eec230a4993e446bd90846f800364e06
CRs-Fixed: 2141518
Acked-by: Ady Abraham <adya@qti.qualcomm.com>
Signed-off-by: Skylar Chang <chiaweic@codeaurora.org>
2018-12-12 23:45:54 -08:00
Linux Build Service Account
df805abc50 Merge "msm: mdss: serialize dynamic fps and dynamic bit clock updates" 2018-12-10 13:22:27 -08:00
Linux Build Service Account
d07ffb8fe2 Merge "usb: gadget: Fix double free of device descriptor pointers" 2018-12-10 06:00:39 -08:00
Linux Build Service Account
514525a5b7 Merge "dwc3-msm: Do not resume usb3 phy if max speed is HS only" 2018-12-10 06:00:38 -08:00
Padmanabhan Komanduru
30d6ebe136 msm: mdss: serialize dynamic fps and dynamic bit clock updates
Dynamic refresh update and dynamic bit clock switch cannot happen
on the same vsync boundary. Serialize them in the commit thread
to avoid vsync timeout issues.

Change-Id: I55077eca7415bf307ddd30040024b3716a78f6fd
Signed-off-by: Padmanabhan Komanduru <pkomandu@codeaurora.org>
2018-12-08 22:53:13 -08:00
Laxminath Kasam
87a0712ca2 soc: swr-wcd: Apply div2 setting on slave side before bank switch
In soundwire controller, bank switch happen twice
for a playback session with stereo speakers. Ensure
the setting of div2 applied to inactive bank before
bank switch occurs to avoid impact based on bank chosen.

Change-Id: I033b19e78309485ca9da85ec67b54409e6fe22cc
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2018-12-05 23:30:07 -08:00
Monika Singh
9432c10726 ARM: dts: msm: Remove Out-of-Bound access
Remove the out of bound access vulnerability in the qce
driver reachable via ioctl.

Change-Id: I4320cd27334eaae975f4a6ad07fb7b2e5ebccffd
Signed-off-by: Monika Singh <monising@codeaurora.org>
2018-12-05 13:25:49 +05:30
Hemant Kumar
23db5b808c usb: gadget: Fix double free of device descriptor pointers
Upon driver unbind usb_free_all_descriptors() function frees all
speed descriptor pointers without setting them to NULL. In case
gadget speed changes (i.e from super speed plus to super speed)
after driver unbind only upto super speed descriptor pointers get
populated. Super speed plus desc still holds the stale (already
freed) pointer. As a result next composition switch results into
double free of super speed plus descriptor. Fix this issue by
setting all descriptor pointers to NULL after freeing them in
usb_free_all_descriptors(). Also clean up gsi_unbind() which is
setting up descriptor pointers to NULL already.

Change-Id: I4f28294c165bb3b5dc9feb4f22d819f527ad4d50
Signed-off-by: Hemant Kumar <hemantk@codeaurora.org>
Signed-off-by: Sriharsha Allenki <sallenki@codeaurora.org>
2018-12-04 21:38:53 -08:00
Vamsi Krishna Samavedam
eccbac9335 dwc3-msm: Do not resume usb3 phy if max speed is HS only
usb3 phy is needed when core is operating at super speed or
higher. Do not turn on usb3 phy clocks even when core is
programmed to work at high speed only mode. While at it,
remove redundant module parameter to control max speed. Speed
can be controlled using existing sysfs entry.

Example: To set High speed only:
echo "high" > /sys/devices/platform/soc/<devname>/speed

To set super speed:
echo "super" > /sys/devices/platform/soc/<devname>/speed

Change-Id: I24a9a869d97e6efc3ebc0d7a1374805139c65648
Signed-off-by: Vamsi Krishna Samavedam <vskrishn@codeaurora.org>
Signed-off-by: Sriharsha Allenki <sallenki@codeaurora.org>
2018-12-04 21:36:24 -08:00
Linux Build Service Account
30f0a18bb2 Merge "ANDROID: sdcardfs: Change current->fs under lock" into kernel.lnx.4.4.r35-rel 2018-12-02 08:46:11 -08:00
Linux Build Service Account
ea079e2458 Merge "msm: mdss: dsi: fix slab-out-of-bounds issue" into kernel.lnx.4.4.r35-rel 2018-12-02 08:46:03 -08:00
Linux Build Service Account
210920e31e Merge "icnss: Remove WARN_ON during self recovery trigger" 2018-12-02 07:30:30 -08:00
Narender Ankam
2827d8bc19 msm: mdss: dsi: fix slab-out-of-bounds issue
While handling dsi_gen_read_status, status buffer
was xlogging without checking for its max size.
Add proper conditional check to xlog status buffer.

Change-Id: Ia5a1fe18de123d2911c31ae79492b96f67e1273d
Signed-off-by: Narender Ankam <nankam@codeaurora.org>
2018-12-01 23:09:17 -08:00
Daniel Rosenberg
62b5592573 ANDROID: sdcardfs: Change current->fs under lock
Adjusted from previous version to add missing include

bug: 111641492

Change-Id: I321d83f5d599efb3abdfaf2f3a4900ac512beca6
Reported-by: Jann Horn <jannh@google.com>
Signed-off-by: Daniel Rosenberg <drosen@google.com>
Git-commit: f6d0920c41a732be06d284177311b57335227bd1
Git-repo: https://android.googlesource.com/kernel/common/
Signed-off-by: Ritesh Harjani <riteshh@codeaurora.org>
2018-12-01 22:27:57 -08:00