Commit graph

589401 commits

Author SHA1 Message Date
Ajay Agarwal
82fe037ea7 sound: usb: Fix format desc usage for BADD 3.0 devices
For a BADD device, the audioformat structure was directly
being populated without initialising the format type
descriptor. This can lead to a crash later when the
format  type and rates are being parsed but the NULL fmt
desc is dereferenced. Fix this by allocating a dummy copy
of fmt desc for BADD 3.0 devices and populating
necessary fields.

Change-Id: I80f33b0e400a9c522a800e989228da134100bb55
Signed-off-by: Ajay Agarwal <ajaya@codeaurora.org>
2017-05-05 17:24:12 +05:30
Linux Build Service Account
9416e47b01 Merge "msm: pcie: move PCIe enumerate sysfs init" 2017-05-04 17:44:33 -07:00
Linux Build Service Account
932034e5a1 Merge "diag: Validate memory device client's process descriptor" 2017-05-04 17:44:32 -07:00
Linux Build Service Account
96a33ee792 Merge "net: pppolac/pppopns: Add back the msg_flags" 2017-05-04 17:44:31 -07:00
Linux Build Service Account
06d9001dc4 Merge "msm: ipa: Add a support to retry uC send command" 2017-05-04 17:44:30 -07:00
Tony Truong
821a04092d msm: pcie: move PCIe enumerate sysfs init
PCIe enumerate sysfs initialization should be
done after all other resources are setup.

Change-Id: I33b43e39453eeee9ac9e22bd1a5463af9eb1fd05
Signed-off-by: Tony Truong <truong@codeaurora.org>
2017-05-04 10:17:39 -07:00
Linux Build Service Account
baf0fa8f1e Merge "wil6210: add option to ignore OTA regulatory hints" 2017-05-04 08:45:27 -07:00
Linux Build Service Account
da84e26540 Merge "ion:synchronize debugfs callback and ion_client_destroy" 2017-05-04 08:45:26 -07:00
Linux Build Service Account
303fb8a3ac Merge "btfm: Program multi channel registers in wcn3990 for Tx/Rx" 2017-05-04 08:45:25 -07:00
Linux Build Service Account
2cba763104 Merge "regulator: onsemi-ncp6335d: Add is_enabled API support" 2017-05-04 08:45:24 -07:00
Linux Build Service Account
a18fb0347b Merge "drm/msm: Fix the SNAPSHOT_HEADER macro" 2017-05-04 08:45:23 -07:00
Linux Build Service Account
66e4265f1d Merge "fs/mbcache: fix use after free issue in mb_cache_shrink_scan()" 2017-05-04 08:45:21 -07:00
Linux Build Service Account
6b10165796 Merge "ARM: dts: msm: Add batt_therm coefficients for QRD SDM660/630" 2017-05-04 08:45:20 -07:00
Linux Build Service Account
34c8633819 Merge "qbt1000: Initialize drvdata structure before usage" 2017-05-04 08:45:19 -07:00
Linux Build Service Account
b1abf6c73c Merge "qbt1000: Validate FP app name before qseecom_start_app" 2017-05-04 08:45:18 -07:00
Linux Build Service Account
8a82f9c18a Merge "msm: mdss: Add plane_count range check in mdss WFD" 2017-05-04 08:45:11 -07:00
Linux Build Service Account
af19d5218d Merge "msm: mdss: Add plane_count limit check for mdss_rotator buffer" 2017-05-04 08:45:10 -07:00
Linux Build Service Account
0e19770cb1 Merge "ARM: dts: msm: enable SMMU stage1 for 11AD devices on msm8998" 2017-05-04 08:45:09 -07:00
Linux Build Service Account
2fa5ce1a0a Merge "ASoC: msm: qdsp6v2: Add routing controls for fm over mi2s" 2017-05-04 08:45:08 -07:00
Linux Build Service Account
64b33916d2 Merge "ASoC: sdm660_cdc: Avoid unclocked register access to digital codec" 2017-05-04 08:45:07 -07:00
Linux Build Service Account
17178c9391 Merge "msm: ipa3: configure WLAN resource group on connect" 2017-05-04 08:45:05 -07:00
Gopikrishna Mogasati
b18e24a6f4 diag: Validate memory device client's process descriptor
This fix checks for valid process descriptor of a
memory device client before exporting information
from diag driver to memory device client's read buffer
for reliable data transfer.

CRs-Fixed: 2016396
Change-Id: I45aeb8fc9e2f6a678d48bbfcbb77c501adbbfce0
Signed-off-by: Gopikrishna Mogasati <gmogas@codeaurora.org>
2017-05-04 20:46:47 +05:30
Utkarsh Saxena
8a834f9977 msm: ipa: Add a support to retry uC send command
For the status IPA_HW_2_CPU_WDI_RX_FSM_TRANSITION_ERROR,
receive from the uC, add a logic to retry sending the same
command for maximum of 10 retires.

Change-Id: I4b241311e0699aea0e24b3a279622a8a1aaa737d
Acked-by: Mohammed Javid <mjavid@qti.qualcomm.com>
Signed-off-by: Utkarsh Saxena <usaxena@codeaurora.org>
2017-05-04 16:27:52 +05:30
Satish Kodishala
413d2ae9fe btfm: Program multi channel registers in wcn3990 for Tx/Rx
For A2DP/SCO Rx, SCO/FM Tx use cases, we need to program
multi channel registers. Without this there would be
glitches and random silence during A2DP playback.

While at it, add the function name to the debug print macro.

CRs-Fixed: 2027268
Change-Id: Ia8e5fde48bb94e97346fe323e92dc32ed60b0e65
Signed-off-by: Satish Kodishala <skodisha@codeaurora.org>
2017-05-04 02:19:39 -07:00
Neil Zhang
2136b67dc6 ion:synchronize debugfs callback and ion_client_destroy
There are race condition B/T ion_client_destroy and debugfs callbacks.
Let's use a mutex to synchronize them.

Change-Id: I3373dc1dbb551b615105a485cc2d3c4bcc0e5e99
Signed-off-by: Neil Zhang <neilzhang1123@hotmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Git-commit: 948c4db4ee10d85fe78ed3755dcaeb85cd37a148
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
[guptap@codeaurora.org: resolve trivial merge conflicts and
 change usage of %p with %pK]
Signed-off-by: Prakash Gupta <guptap@codeaurora.org>
2017-05-04 14:45:01 +05:30
Prakash Gupta
026cbd8d2a ion: revert downstream fix for debugfs synchronization
revert msm specific changes conflicting with commit I3373dc1dbb5
("ion:synchronize debugfs callback and ion_client_destroy")

- revert commit I7bc7562400d ("ion: destroy ion handles under
  client->lock")
- revert commit Ic4c2f9dff90 ("ion: validate ion client in
  ion_debug_client_show() and extract data")
- revert dev->lock usage in ion_debug_heap_show.

Change-Id: Iba5f527b57f39d628b8cd833f627481cc56f6617
Signed-off-by: Prakash Gupta <guptap@codeaurora.org>
2017-05-04 14:45:01 +05:30
Kiran Gunda
8f48ec6a5a regulator: onsemi-ncp6335d: Add is_enabled API support
Without is_enabled function support, regualtor framework treats
it as an always on regulator and does not invoke the regulator enable
function call. Hence, add support for it.

Also, define a parent supply ("vin") for the regulator. This parent
can be used to pin-control the regulator. While at it, change the initcall
level to subsys_init. so that the driver registers after the parent supply
("vin" - provided by fixed-regualtor).

Change-Id: I93e870d2e4b89f7874c3e17be91bc417dadf1777
Signed-off-by: Kiran Gunda <kgunda@codeaurora.org>
2017-05-04 14:33:41 +05:30
Linux Build Service Account
2db428de0b Merge "drm/msm: Add preemption records to QTI GPU snapshot" 2017-05-03 23:32:11 -07:00
Linux Build Service Account
48a0c93e1d Merge "msm: camera: ispif: extend interface with line width" 2017-05-03 23:32:10 -07:00
Linux Build Service Account
6669dae7d1 Merge "msm: camera: Allow driver file to be opend only once." 2017-05-03 23:32:08 -07:00
Linux Build Service Account
a1e1d01429 Merge "msm: camera2: cpp: Fix out-of-bounds frame or command buffer access" 2017-05-03 23:32:06 -07:00
Linux Build Service Account
9d0c2b4690 Merge "iommu/iommu-debug: Add validation support for per-buffer coherent mappings" 2017-05-03 23:32:05 -07:00
Linux Build Service Account
2f04bcd6dc Merge "Revert "smb138x: introduce support for smb1355"" 2017-05-03 23:31:51 -07:00
Linux Build Service Account
7e299cee46 Merge "Revert "smb138x: use chg src bit to disable parallel charger"" 2017-05-03 23:31:50 -07:00
Linux Build Service Account
7d2dbd9538 Merge "Merge branch 'android-4.4@e4528dd' into branch 'msm-4.4'" 2017-05-03 23:31:48 -07:00
Linux Build Service Account
bf5ab4a6aa Merge "defconfigs: Sync up defconfigs" 2017-05-03 23:31:47 -07:00
Linux Build Service Account
de0bc8ca46 Merge "soc: qcom: minidump: move elf global variables to structure" 2017-05-03 23:31:45 -07:00
Linux Build Service Account
5020492d4f Merge "soc: qcom: minidump: update error message log level" 2017-05-03 23:31:44 -07:00
Linux Build Service Account
3015e7db67 Merge "icnss: Initialize the structure member properly" 2017-05-03 23:31:13 -07:00
Linux Build Service Account
2496676424 Merge "regulator: onsemi-ncp6335d: Fix compilation issues" 2017-05-03 23:31:08 -07:00
Linux Build Service Account
495301846e Merge "profiler: Reorder the bandwidth counter structure" 2017-05-03 23:31:06 -07:00
Abir Ghosh
13ccb392c3 qbt1000: Initialize drvdata structure before usage
Fix uninitialized local variable error which might have lead to
crash.

CRs-Fixed: 2030137
Change-Id: I3fd95cb343c3175e4190c8ebfe209399db0602a6
Signed-off-by: Abir Ghosh <abirg@codeaurora.org>
2017-05-03 23:21:25 -07:00
Abir Ghosh
07f699a324 qbt1000: Terminate fingerprint TA name with null
Terminate the string, coming from userspace and containing the name
of fingerprint trusted app, with null character, to make sure kernel
memory does not leak into logs

Change-Id: I1668a64fcb6747ce3ef3b1ee6321fa5fa4a1798a
CRs-Fixed: 2029409
Signed-off-by: Abir Ghosh <abirg@codeaurora.org>
2017-05-03 23:21:12 -07:00
Abir Ghosh
9f6e16f245 qbt1000: Validate FP app name before qseecom_start_app
Validate the name of the client app before passing it to
qseecom_start_app.

CRs-Fixed: 2006695
Change-Id: I9c6b16050d4f6fc94827021c7b0f2ab292452f60
Signed-off-by: Abir Ghosh <abirg@codeaurora.org>
2017-05-03 23:20:55 -07:00
Sahitya Tummala
d07d314e7d fs/mbcache: fix use after free issue in mb_cache_shrink_scan()
Fix the below potential race between these two contexts -
mb_cache_entry_get() and mb_cache_shrink_scan(), which results
into use after free issue.

			     task a:
			     mb_cache_shrink_scan()
			       |--if(!list_empty(&mb_cache_lru_list))
				      |--get the ce entry
				      |--list_del_init(&ce->e_lru_list);
				      |--check ce->e_used, ce->e_queued,
					 ce->e_refcnt and continue
				      -> gets prempted here
task b:
ext4_xattr_release_block()
 |--mb_cache_entry_get()
    |--get ce from hlist_bl_for_each_entry()
      |--increment ce->e_used and
         list_del_init(&ce->e_lru_list)
 |--mb_cache_entry_free()
				      |--hlist_bl_lock(ce->e_block_hash_p);
				      -> results into use after free

Also, fix similar potential race between mb_cache_entry_alloc() and
mb_cache_entry_get() in case if cache->c_max_entries is reached.

Change-Id: I01049bae5d914cfb8494ab299ec2e068745d1110
Signed-off-by: Sahitya Tummala <stummala@codeaurora.org>
2017-05-04 09:41:48 +05:30
Yingwei Zhao
fe26f221ff ARM: dts: msm: Add batt_therm coefficients for QRD SDM660/630
Configure battery thermal coefficients for QRD660/630 to make sure the
device could read the correct battery temperatures.

CRs-Fixed: 2038922
Change-Id: I21d0eedfec0a0529d8864d11b703659f4ba43b6a
Signed-off-by: Yingwei Zhao <cyizhao@codeaurora.org>
2017-05-03 20:23:21 -07:00
Abhijeet Dharmapurikar
b65544bd63 Revert "smb138x: introduce support for smb1355"
This reverts commit 566b44214c (smb138x:
introduce support for smb1355).

This is not required since smb1355 support is moved to its own driver.

Change-Id: Ibad8595c09a865e273adb6f30d6a75f931220131
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
2017-05-03 13:51:53 -07:00
Abhijeet Dharmapurikar
df7b29506b Revert "smb138x: use chg src bit to disable parallel charger"
This reverts commit 0f0e36134d ("smb138x:
use chg src bit to disable parallel charger)

This is not required, since smb1355 support is moved to its own driver.

Change-Id: I1bd454030d29195f03be132d167ec8294169b9d5
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
2017-05-03 13:51:53 -07:00
Abhijeet Dharmapurikar
9d0fdc3738 qpnp-smb2: Support faking input current limited state
Support faking input current limited state. This is very helpful
in testing/debugging the software based vbus changing algorithms.

Change-Id: I7cf548c94397ee680c9d65343c49ec7b16873e88
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
2017-05-03 13:51:52 -07:00
Fenglin Wu
15a68a61bd power: qcom: smb2: Add REAL_TYPE property for usb power_supply
Add POWER_SUPPLY_PROP_REAL_TYPE property for usb_psy to present its real
charger type. POWER_SUPPLY_PROP_TYPE in usb_psy is always set to
POWER_SUPPLY_TYPE_USB_PD for healthd to recognize it as an AC charger.
Also add usb_port_psy with POWER_SUPPLY_TYPE_USB type is added for healthd
to recognize it as an USB host. Their ONLINE properties will be updated
according to the VBUS status, type-c mode and real charger type.
With this type being set statically, update the usb phy and pd policy
engine code to look at real type.

Change-Id: I90aa69325cc82b09dfb513c0eeecbc61e092a57f
Signed-off-by: Fenglin Wu <fenglinw@codeaurora.org>
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
2017-05-03 13:48:19 -07:00