Commit graph

585336 commits

Author SHA1 Message Date
Linux Build Service Account
c1906072dc Merge "ARM: dts: msm: config SD card GPIO on SDM660 QRD" 2017-03-07 06:24:59 -08:00
Linux Build Service Account
5bd32b9102 Merge "power: qcom: smb-lib: enable HVDCP auth IRQ before APSD rerun" 2017-03-07 06:24:54 -08:00
Linux Build Service Account
3e5d23c301 Merge "mmc: sdhci: add err_state to sdhci_dumpregs func" 2017-03-07 06:24:53 -08:00
Manaf Meethalavalappu Pallikunhi
db2c9496c8 drivers: lmh_dcvsh: Use allocated variable for LMH DCVSh sensor name
LMH DCVSh device uses stack memory for sensor name and passes
this stack variable pointer as devname argument while registering
LMH DCVSh interrupt. But interrupt framework saves this pointer and
try to dereference data in a different context. It leads to a
stack-out-of-bounds issue.

To fix this issue, use allocated memory variable to store sensor
name and pass the same while registering interrupt.

==================================================================
BUG: KASAN: stack-out-of-bounds in strcpy+0x24/0x50 at
addr ffffffc0d37e3ac0
Read of size 1 by task kworker/0:1H/593
==================================================================
page dumped because: kasan: bad access detected
kworker/0:1H Tainted: G  W  4.4.21+ #1
------------------------------------------------------------------
Call trace:
[<ffffff900808a78c>] dump_backtrace+0x0/0x2c0
[<ffffff900808aa70>] show_stack+0x24/0x30
[<ffffff90084bd8c4>] dump_stack+0xbc/0xf8
[<ffffff9008263ce8>] kasan_report+0x3b0/0x4f8
[<ffffff900826308c>] __asan_load1+0x24/0x50
[<ffffff90084c8c54>] strcpy+0x24/0x50
[<ffffff90080b2fc8>]
		trace_event_raw_event_irq_handler_entry+0x134/0x180
[<ffffff900813e718>] handle_irq_event_percpu+0x33c/0x3e0
[<ffffff900813e828>] handle_irq_event+0x6c/0xb0
[<ffffff9008143bf4>] handle_fasteoi_irq+0x10c/0x1d4
[<ffffff900813d750>] generic_handle_irq+0x40/0x50
[<ffffff900813dbcc>] __handle_domain_irq+0xb0/0xe4
[<ffffff9008081ab8>] gic_handle_irq+0xd8/0x1a0
Memory state around the buggy address:
ffffffc0d37e3980: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 f1 f1
ffffffc0d37e3a00: f1 f1 04 f4 f4 f4 f2 f2 f2 f2 00 f4 f4 f4 f2 f2
ffffffc0d37e3a80: f2 f2 00 00 00 00 00 00 f4 f4 f2 f2 f2 f2 00 00
                                           ^
ffffffc0d37e3b00: 00 00 00 00 00 00 f2 f2 f2 f2 00 00 00 00 00 00
ffffffc0d37e3b80: 00 00 f3 f3 f3 f3 00 00 00 00 00 00 00 00 00 00
==================================================================

CRs-Fixed: 2015855
Change-Id: I22bd8ff4cd6d6a2389be37c35e23fb86221de5c6
Signed-off-by: Manaf Meethalavalappu Pallikunhi <manafm@codeaurora.org>
2017-03-07 04:37:23 -08:00
Manu Gautam
3e96eebc6b usb: xhci: Set bulk EP maxpacket to 8 for buggy FS devices
Some FS devices report maxpacket size as 4 for their BULK EPs
which is incorrect as per USB specification. This results in
ep_config command to controller timing out and enumeration fails.
As minimum maxpacket size for FS is 8, override the same for such
devices.

CRs-fixed: 1002876
Change-Id: I70c2210b4eb93f557eef306fcbc11308b7b33e07
Signed-off-by: Manu Gautam <mgautam@codeaurora.org>
2017-03-07 04:05:13 -08:00
Amit Nischal
3e6f31c583 clk: qcom: Fix null pointer exception
Add null pointer check before dereferencing pointers.

Change-Id: I9d96a3d0e7d00ffc2c2eb83a0d2384a21fe994ae
Signed-off-by: Amit Nischal <anischal@codeaurora.org>
2017-03-07 17:05:51 +05:30
Utkarsh Saxena
03cbd472f6 msm: ipa: Fix updating the repl_trig_thresh for LAN_CONS
Replenish trigger threshold for LAN_CONS is calculated
before updating the rx_pool_sz. This can result into
division by 0 which can make the system unstable.
Make a change to update the rx_pool_sz before updating
the replenish trigger threshold.

Change-Id: I62f6c114ce7aee571833ef05146ab75cab0fb5d2
Acked-by: Chaitanya Pratapa <cpratapa@qti.qualcomm.com>
Signed-off-by: Utkarsh Saxena <usaxena@codeaurora.org>
2017-03-07 16:44:12 +05:30
Manish Poddar
3a76e4df0b defconfig: msm: Enable camera for SDM660 32bit variant
Enable camera in the kernel by enabling camera
specific CONFIG_* macros in the kernel defconfig.

Change-Id: I875846e948363283fcde2ebeeee913059771325a
Signed-off-by: Manish Poddar <mpoddar@codeaurora.org>
2017-03-07 03:11:48 -08:00
Shantanu Jain
0ead35930f input: touchscreen: remove data pointer from driver structure
Remove data pointer from the driver structure which is obtained
from user-space. Exclude it from driver structure and move it
outside as another global data pointer.
The definition of CMD_HEAD_LENGTH is meant to exclude the
last member (*data) from the copy from userspace. This change
is meant to keep the definition of CMD_HEAD_LENGTH simple,
and handle the data separately.

Change-Id: I62f14c744e5c331718b6d84f67a4e89b511c9f44
Signed-off-by: Shantanu Jain <shjain@codeaurora.org>
2017-03-07 16:36:42 +05:30
Manaf Meethalavalappu Pallikunhi
ec2354506c ARM: dts: msm: No need to disable CXIP LM feature in KTM for sdm630
This reverts commit f4070db5b9
("ARM: dts: msm: Disable CXIP LM feature for sdm630") since
CXIP LM hardware feature is disabled by default for sdm630.

Change-Id: I3a2e033ce3e7f22f4b87e3e63b1942555ce8d7d4
Signed-off-by: Manaf Meethalavalappu Pallikunhi <manafm@codeaurora.org>
2017-03-07 02:56:26 -08:00
Ingrid Gallardo
26c3c0aa7c msm: mdss: update check bw check for ab/ib
Update the bandwidth check for those cases where only
ab changes and ib is greater than ab. The current
logic takes the max of both and since ib is max, the
vote will not kick-in. This change is intended to
solve this problem.

Change-Id: Icbd6d9aa5221784bc1c88ae1965c944503ac78dc
Signed-off-by: Ingrid Gallardo <ingridg@codeaurora.org>
2017-03-07 16:07:39 +05:30
Taniya Das
161b113017 clk: qcom: Add separate aggre2_noc clock voters for SDM660/630
Separate out the aggre2_noc voters so that individual voters could vote on
these clocks and voter clock would aggregate the clock rates before sending
a request to RPM.

Change-Id: I8ef30af257d2f37ec5af6aa5e3d1b69e5ba8ec8c
Signed-off-by: Taniya Das <tdas@codeaurora.org>
2017-03-07 15:58:32 +05:30
Tharun Kumar Merugu
1d18a9fdb5 msm: ADSPRPC: Handle SSR, daemon kill for audio PD
Handle SSR, daemon kill and restart scenarios for audio PD

Change-Id: If9c9e98642ad69866b19a7c0ea19160dcb357d34
Acked-by: Chenna Kesava Raju <chennak@qti.qualcomm.com>
Signed-off-by: Tharun Kumar Merugu <mtharu@codeaurora.org>
2017-03-07 01:48:04 -08:00
Avaneesh Kumar Dwivedi
fb7aadf142 soc: qcom: Free qmi handle in a worker thread
This change on arrival of ssr event schdule a worker thread,
which when run carry out task of qmi handle destruction.
It is a desired change to make ssr notification callback as
light as possible and avoid blocking it for long in corner cases.

Change-Id: I832fabce7569b1b8b966b7c49cda1b00cff2c472
Signed-off-by: Avaneesh Kumar Dwivedi <akdwived@codeaurora.org>
2017-03-07 15:13:31 +05:30
Vijayavardhan Vennapusa
59b6f20843 USB: composite: Fix double release of spin_unlock_irqsave
Commit b953b45ed08c ("USB: composite: Release spinlock before
WARN()") introduced a bug where it leads to calling spin_unlock_
irq_save twice in case of delayed_status zero. Hence fix the issue
by returning from composite_setup_continue() right after WARN() in
case of delayed_status zero.

Change-Id: I33c77ec8a2f97fcd94cffb416e57f3c77d6789f2
Signed-off-by: Vijayavardhan Vennapusa <vvreddy@codeaurora.org>
2017-03-07 14:56:20 +05:30
Saranya Chidura
849360cef4 ARM: dts: msm: removed gpu_dl and wcss tpdm, tpda and funnels for sdm660
The funnel_gpu_dl and funnel_wcss restrict the use of AUTHSTATUS registers
for knowing status of Coresight fuses. The funnels, tpdm, tpda are removed
as they are also not in use.

Change-Id: I3b7e17565d279dcd985c392a3033c4a542c3f458
Signed-off-by: Saranya Chidura <schidura@codeaurora.org>
2017-03-07 12:30:02 +05:30
Linux Build Service Account
4ffd6a18c4 Merge "drm/msm/sde: fix color component order for UBWC formats" 2017-03-06 22:43:48 -08:00
Linux Build Service Account
dc255d3cee Merge "ARM: dts: msm: Setting alignment size of adsp cma region to 8MB for SDM660" 2017-03-06 22:43:42 -08:00
Linux Build Service Account
67d173f7e9 Merge "ARM: dts: msm: Add SPDM feature for sdm660" 2017-03-06 22:43:41 -08:00
Linux Build Service Account
05cbf8d351 Merge "ARM: dts: msm: setting alignment size of adsp cma region to 8MB for SDM630" 2017-03-06 22:43:41 -08:00
Linux Build Service Account
00f85231bc Merge "ARM: dts: msm: Allow modem MBA to be loaded in carveout for SDM630" 2017-03-06 22:43:40 -08:00
Linux Build Service Account
2ab20ffb7b Merge "ARM: dts: msm: add MBA carveout for sdm630" 2017-03-06 22:43:39 -08:00
Linux Build Service Account
5f92ec65b9 Merge "lpm-levels: Return from idle enter for negative mode" 2017-03-06 22:43:39 -08:00
Linux Build Service Account
fb2e8b97fa Merge "clk: qcom: Update the source clock for 24MHz MCLK" 2017-03-06 22:43:38 -08:00
Linux Build Service Account
f3ecd02343 Merge "msm: camera: Validate size param before allocating memory" 2017-03-06 22:43:37 -08:00
Linux Build Service Account
f35c117cc0 Merge "msm:cci: Add protection for race condition in cci queue access" 2017-03-06 22:43:36 -08:00
Linux Build Service Account
4ce3eaf877 Merge "msm: camera: add check to ensure user task wont hog CPU" 2017-03-06 22:43:35 -08:00
Linux Build Service Account
e53669c282 Merge "msm: camera: isp: enable/disable hvx only if the state changed" 2017-03-06 22:43:34 -08:00
Linux Build Service Account
84d7cb53a5 Merge "msm: isp: fix for potentitial array out of bound access" 2017-03-06 22:43:33 -08:00
Linux Build Service Account
1cb56eedff Merge "msm: isp: Fix dummy print which may leak address" 2017-03-06 22:43:32 -08:00
Linux Build Service Account
789bdd5b54 Merge "ARM: arch_timer: force re-selection of the best clocksource" 2017-03-06 22:43:31 -08:00
Linux Build Service Account
4a9008031c Merge "ARM: dts: msm: update device nodes for SDM658" 2017-03-06 22:43:31 -08:00
Linux Build Service Account
50047fdad2 Merge "ARM: dts: msm: lpass cti removed on sdm660" 2017-03-06 22:43:30 -08:00
Linux Build Service Account
88e4d16567 Merge "soc: qcom: glink: Move channel to dummy xprt with lock" 2017-03-06 22:43:29 -08:00
Xu Yang
6baec9abc0 msm: mdss: Add support to update backlight when display commit
1. Add support to update backlight when display commit. Backlight
level is sent from userspace. And sync to set PP config, kickoff,
and set backlight in the same vsync period.

2. Add support to get current backlight level through sysfs node.

Change-Id: Icf264299ecf8edd3831938745a471c2655c23542
Signed-off-by: Xu Yang <yangxu@codeaurora.org>
2017-03-07 14:36:54 +08:00
Sarada Prasanna Garnayak
4af1b577f9 icnss: set vdd-0.8-cx-mx regulator optional for icnss driver
The wlan firmware is configuring the clk and voltage regulator
for hardware power on and hardware reset sequence.

The icnss platform driver is configuring this clk and regulators
to avoid invalid access to copy engine register during the wlan
recovery.

As platform driver is not configuring this regulator to power on
or reset the WLAN hardware, So no need to define the voltage
regulators are the required properties for the ICNSS platform driver.

Define vdd-0.8-cx-mx as an optional voltage regulator for
the icnss platform driver.

CRs-Fixed: 2014965
Change-Id: I74a1445522997ba4e7a52da5a29e9afb57ad12df
Signed-off-by: Sarada Prasanna Garnayak <sgarna@codeaurora.org>
2017-03-06 22:26:09 -08:00
Venkatesh Yadav Abbarapu
0b6529f408 defconfig: msm: Enable KASLR on sdm660 target
Enable kernel address space layout randomization for
better protection.

Change-Id: Ie92bcf606a28c146ecbf19a7fc89088079d0beb0
Signed-off-by: Venkatesh Yadav Abbarapu <vabbar@codeaurora.org>
2017-03-07 11:31:21 +05:30
Purushottam Kushwaha
92eb55da1c msm: wlan: Define CFG80211_CONNECT_TIMEOUT_REASON_CODE
To indicate, presence of cfg80211_connect_timeout() api to wlan driver
with additional parameter, CFG80211_CONNECT_TIMEOUT_REASON_CODE is
defined and depends on commit eadbd4a4290b ("cfg80211: Specify the
reason for connect timeout") which adds reason while indicating timeout.

When CFG80211_CONNECT_TIMEOUT_REASON_CODE is defined and if wlan
connection attempt failed due to timeout, then wlan driver invokes
cfg80211_connect_timeout() with reason of timeout.

CRs-Fixed: 2004380
Change-Id: I0ba392e05fa9db82de75abd8c29df0b7570066d6
Signed-off-by: Purushottam Kushwaha <pkushwah@codeaurora.org>
2017-03-06 21:19:33 -08:00
Purushottam Kushwaha
ddeaf3780a cfg80211: Specify the reason for connect timeout
This enhances the connect timeout API to also carry the reason for the
timeout. These reason codes for the connect time out are represented by
enum nl80211_timeout_reason and are passed to user space through a new
attribute NL80211_ATTR_TIMEOUT_REASON (u32).

Signed-off-by: Purushottam Kushwaha <pkushwah@qti.qualcomm.com>
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
[keep gfp_t argument last]
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Git-commit: 3093ebbeabcdddc9a982950052f2151df43c7aa2
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/jberg/mac80211-next.git
CRs-Fixed: 2004380
Change-Id: If25dbf99d08d6ee658782fb08bd0ac670e95584a
Signed-off-by: Purushottam Kushwaha <pkushwah@codeaurora.org>
2017-03-06 21:19:16 -08:00
Purushottam Kushwaha
4f74effbf0 msm: wlan: Define CFG80211_CONNECT_TIMEOUT
To indicate, presence of cfg80211_connect_timeout() api to wlan driver,
CFG80211_CONNECT_TIMEOUT is defined and depends on
commit 48f3dee442d9 ("cfg80211: Allow cfg80211_connect_result() errors
to be distinguished") which implements cfg80211_connect_timeout().

When CFG80211_CONNECT_TIMEOUT is defined and if wlan connection attempt
failed due to timeout, then wlan driver invokes
cfg80211_connect_timeout().

CRs-Fixed: 2004380
Change-Id: Ie2c16eb9c1a1330264daf843848c7da43da49b6c
Signed-off-by: Purushottam Kushwaha <pkushwah@codeaurora.org>
2017-03-06 21:19:06 -08:00
Jouni Malinen
dcfe151610 cfg80211: Allow cfg80211_connect_result() errors to be distinguished
Previously, the status parameter to cfg80211_connect_result() was
documented as using WLAN_STATUS_UNSPECIFIED_FAILURE (1) when the real
status code for the failure is not known. This value can be used by an
AP (and often is) and as such, user space cannot distinguish between
explicitly rejected authentication/association and not being able to
even try to associate or not receiving a response from the AP.

Add a new inline function, cfg80211_connect_timeout(), to be used when
the driver knows that the connection attempt failed due to a reason
where connection could not be attempt or no response was received from
the AP. The internal functions now allow a negative status value (-1) to
be used as an indication of this special case. This results in the
NL80211_ATTR_TIMED_OUT to be added to the NL80211_CMD_CONNECT event to
allow user space to determine this case was hit. For backwards
compatibility, NL80211_STATUS_CODE with the value
WLAN_STATUS_UNSPECIFIED_FAILURE is still indicated in the event in such
a case.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
[johannes: fix cfg80211_connect_bss() prototype to use int for status,
 add cfg80211_connect_timeout() to docbook, fix docbook]
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Git-commit: bf1ecd210541ef5f3a110e88e8ca5d33b4aa5c23
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/jberg/mac80211-next.git
CRs-Fixed: 2004380
Change-Id: I43e2a7d588ee86a8470cf72ac0a95daaae569fa0
Signed-off-by: Purushottam Kushwaha <pkushwah@codeaurora.org>
2017-03-06 21:18:26 -08:00
Vishnuvardhan Prodduturi
abf8e86fe6 msm: mdss: set interface stopped flag properly during suspend
In current implementation while disabling interface, the
interface stopped flag is not keeping the correct value. This
is causing issues when later if we use this flag during command
autorefresh feature disable. So update the flag properly after
wiping out display context structure to store correct value.

Change-Id: Id2cc64e3f10711b92f8b8f4f36f73f716c9ac831
Signed-off-by: Sandeep Panda <spanda@codeaurora.org>
Signed-off-by: Vishnuvardhan Prodduturi <vproddut@codeaurora.org>
2017-03-07 10:43:21 +05:30
Vishnuvardhan Prodduturi
6ab42d60d1 msm: mdss: fix conditional check for panel LP configuration
Add change to correct the conditional check for entering the
panel in and out of LP configurations. Remove the unused enum
structure related to panel blank status.

Change-Id: Ic1140eafcc7cdd8d64c107bddc824eeca844462d
Signed-off-by: Padmanabhan Komanduru <pkomandu@codeaurora.org>
Signed-off-by: Vishnuvardhan Prodduturi <vproddut@codeaurora.org>
2017-03-07 10:42:14 +05:30
Vishnuvardhan Prodduturi
eb973791c0 msm: mdss: enable tearcheck while entering LP1 state
In current implementation we disable tear check block when
transitioning into ultra low power or power off state for
doze mode. But it is not enabled back when moving from
ultra low power state(LP2) to low power state(LP1), after
which updates are expected. This change enables back tearcheck
block when transitioning to LP1 from LP2 state.

Change-Id: Ic0d8f97752ccf88470da2423f3f8d56a32de227f
Signed-off-by: Sandeep Panda <spanda@codeaurora.org>
Signed-off-by: Vishnuvardhan Prodduturi <vproddut@codeaurora.org>
2017-03-07 10:41:01 +05:30
Vishnuvardhan Prodduturi
4072ee7757 msm: mdss: do not report overflow errors during read commands
During a DSI DMA read command transaction, it is expected to have
DSI FIFO overflow if the read operation duration exceeds one BLLP
line time frame. Make sure not to trigger DSI FIFO overflow recovery
sequence for such cases where DSI FIFO overflow error is masked.

Change-Id: I0762a0f51d580a44cfa24ffac60cc465c241c733
Signed-off-by: Padmanabhan Komanduru <pkomandu@codeaurora.org>
Signed-off-by: Vishnuvardhan Prodduturi <vproddut@codeaurora.org>
2017-03-07 10:39:46 +05:30
Ray Zhang
8249ee7f55 ARM: dts: msm: add rm67195 panel driver for SDM630/SDM660 PM660A QRD
rm67195 AMOLED FHD display panel will be used for SDM630/SDM660
PM660A QRD, so add a new panel dtsi file to support that.

Change-Id: Icbdb68874e2e119b3a805a8959b01045e0dd63c9
Signed-off-by: Ray Zhang <rayz@codeaurora.org>
Signed-off-by: Yahui Wang <yahuiw@codeaurora.org>
2017-03-07 12:20:30 +08:00
xiaonian
85c766e037 ARM: dts: msm: config SD card GPIO on SDM660 QRD
As GPIO 54 has already been connected to an external
pull up resistor, config it to no pull to save power
consumption.

CRs-Fixed: 2015121
Change-Id: Id13588be53b8756e4d9792035bcc6adfbaa8c3f7
Signed-off-by: xiaonian <xiaonian@codeaurora.org>
2017-03-07 09:30:37 +08:00
Walter Yang
05f4374845 ASoC: Add backend user count checking
Add backend user count checking to protect the index
boundary.

Change-Id: Ic1b61d1f7130252cc54da0b16553858714988dbd
CRs-Fixed: 2009216
Signed-off-by: Walter Yang <yandongy@codeaurora.org>
2017-03-06 16:33:34 -08:00
Walter Yang
3ef1c4591b ASoC: wcd934x: mark AIF4 MAD TX as ignore suspend
Mark AIF4 MAD TX as ignore suspend so that MAD path
will not power down during suspend mode.

CRs-Fixed: 2003858
Change-Id: Iae55e2778edcdd8efa6ae13b746795d8a1594a41
Signed-off-by: Walter Yang <yandongy@codeaurora.org>
2017-03-06 16:33:28 -08:00
Walter Yang
b91bc18535 ARM: dts: msm: remove hph_en nodes for sdm660 qrd
HIFI headphone path is not present in sdm660 qrd board.
So there is no need to add these two hph_en nodes under tasha node.
These two nodes get initialized by msm_cdc_pinctrl driver and make
gpio24/25 as output low, which causes some power leakage.
Remove these two hph_en nodes for sdm660 qrd.

Change-Id: I527ce45296cd3b168bea67804e0909f668f74221
CRs-Fixed: 2011375
Signed-off-by: Walter Yang <yandongy@codeaurora.org>
2017-03-06 16:33:21 -08:00