Commit graph

590985 commits

Author SHA1 Message Date
Manish Dewangan
f5a7555de3 qdspv2: Add latency calculation support in pcm offload path
Update cold and continuous latency debug fs entries for offload
path to support latency calculation for pcm offload path.

CRs-Fixed: 2059729
Change-Id: Ic59c7b2fec76e682837c89926595fb3262d01aa8
Signed-off-by: Manish Dewangan <manish@codeaurora.org>
2017-06-13 22:22:09 -07:00
Guchun Chen
bdac1e68ba msm: smmu: add re-route calling for specified iova when mapping
When calling smmu mapping, if iova is specified directly by user, not
allocated dynamically in dma-mapping.c, smmu driver needs to provide
support for this. This is needed in early display case. In this scenario,
LK has set physical memory to display hardware for fetching, so if iova
is not explicitly specified in kernel, but instead dynamically produced
by "alloc_iova" in dma-mapping.c, display hardware has no chance to know
this new iova, then smmu fault will happen if enabling the iommu stage-1
translation.
To fix this smmu fault problem, add re-routing to the right path when
iova specified by user is not 0 in smmu map function.

Change-Id: I555fe7ae44464f25245d2d0a6740a2411a8624ba
Signed-off-by: Guchun Chen <guchunc@codeaurora.org>
2017-06-14 11:18:47 +08:00
Xu Yang
564912b76b msm: mdss: Fix number accuracy for backlight to brightness
Fix the number accuracy when convert backlight to brightness.

CRs-Fixed: 2054751
Change-Id: I5d30b65e795ad84d2ba897a9d5be2a8bb36f32eb
Signed-off-by: Xu Yang <yangxu@codeaurora.org>
2017-06-13 19:04:58 -07:00
Aravind Venkateswaran
9982f7000f msm: mdss: dp: use fixed NVID for VGA dongles
Most VGA dongles expect the source to use a fixed NVID value of
0x8000 even though the source may be operating in a synchronous
clocking mode. Using any other values for NVID may result in
no display on the attached VGA sink. Add support for this by
calculating the correct MVID based on the fixed NVID value.

CRs-Fixed: 1095718
Change-Id: Icfef570c8584a51342015a9981b778436edaf84a
Signed-off-by: Aravind Venkateswaran <aravindh@codeaurora.org>
2017-06-13 16:50:26 -07:00
Linux Build Service Account
f19eadaabe Merge "drm/msm: Use per-ring submit lists" 2017-06-13 16:29:03 -07:00
Linux Build Service Account
076704b374 Merge "drm/msm: fix leak in failed submit path" 2017-06-13 16:29:01 -07:00
Linux Build Service Account
c65d7c1cd9 Merge "msm: thermal: Probe sensor info prior to other feature probe" 2017-06-13 16:29:00 -07:00
Linux Build Service Account
55e1e2ea4e Merge "defconfig: msm: Enable CONFIG_MMC_RING_BUFFER for msm8998" 2017-06-13 16:28:59 -07:00
Linux Build Service Account
30559277e9 Merge "diag: dci: Add NULL pointer checks for dci buffers" 2017-06-13 16:28:58 -07:00
Linux Build Service Account
0bb8d348da Merge "drm/msm: Fix possible overflow issue in submit_cmd" 2017-06-13 16:28:58 -07:00
Can Guo
196b77384e scsi: ufs: update ufs command logging infrastructure
This change increases the max command logging capability.
It also adds cmd log print if pwr ctrl failure detected.
Finally, it changes function name ufshcd_cmd_log_print to
ufshchd_print_cmd_log to align with the naming of other
ufshcd debug print functions.

Change-Id: Ia407b239a0e231c353cccf7e6acf87a5f73d7bd8
Signed-off-by: Can Guo <cang@codeaurora.org>
2017-06-13 14:55:03 -07:00
Animesh Kishore
b445e492f7 msm: mdss: Add cursor validation for hflip
Hflip is not supported on cursor pipes as there
is no flip buffer in the hardware. Invalidate
any commit request for cursor hflip.

Change-Id: I4b0ad28caffb75a4bd5a928a90daa6aa59f51848
Signed-off-by: Animesh Kishore <animeshk@codeaurora.org>
2017-06-14 01:04:34 +05:30
Zhen Kong
0ddb3d1fcf crypto: msm: fix rfc4309(ccm(aes)) issue on msm-4.4
In newer kernel (msm-4.4 or later), for AEAD ciphering, crypto api has
been re-worked and the assoclen defines the length of association data
and iv together. But for rfc4309(ccm(aes)), iv is not part of AAD.
Therefore, change qcrypto driver to remove the iv, by subtract 8 from
assoclen for rfc4309(ccm(aes)).

Change-Id: I37eb1934d7817b5b5c33440122b68e5d37854960
Signed-off-by: Zhen Kong <zkong@codeaurora.org>
2017-06-13 11:37:43 -07:00
Abhijit Kulkarni
02bb9a64ee drm/msm/sde: add support to select secure context bank
Add support in the sde plane component to select the secure context
bank based on the fb_mode plane property. This changes also sets the
correct hw settings for the secure plane src address.

CRs-Fixed: 2053654
Change-Id: Iacdfbb366b3ff56fcd5036fb9157547542095cde
Signed-off-by: Abhijit Kulkarni <kabhijit@codeaurora.org>
2017-06-13 11:20:03 -07:00
Linux Build Service Account
f32e95c637 Merge "ARM: dts: msm: Add clock config entry to vmem device on MSM8996" 2017-06-13 08:48:42 -07:00
Linux Build Service Account
c13834210f Merge "ARM: dts: msm: Align CB size to 128MB for SDM660 and SDM630" 2017-06-13 08:48:41 -07:00
Linux Build Service Account
379f393033 Merge "msm: vidc: Perform cache operations only on filled length" 2017-06-13 08:48:40 -07:00
Linux Build Service Account
57a66a97cf Merge "msm: vidc: Allocate memory dynamically for debugfs info_reads" 2017-06-13 08:48:39 -07:00
Linux Build Service Account
4d3e69274e Merge "msm: vidc: Return only active state VBs during flush" 2017-06-13 08:48:38 -07:00
Linux Build Service Account
650bcc069b Merge "diag: Synchronize mdlog read and write threads" 2017-06-13 08:48:37 -07:00
Linux Build Service Account
984393cfae Merge "ASoC: msm: qdspv6: Fix wrong smmu sid for ULL playback" 2017-06-13 08:48:37 -07:00
Linux Build Service Account
5d52e10d48 Merge "sdm660: adsprpc: Map uncached buffers as non-coherent" 2017-06-13 08:48:36 -07:00
Srinivas Ramana
531d60d85c defconfig: msm: Enable RCU_FAST_NO_HZ for sdm660
Enable RCU fast for better performance.

Change-Id: I2754849dea0190456ff7bd6bec7f4d675b2bb5c4
Signed-off-by: Srinivas Ramana <sramana@codeaurora.org>
2017-06-13 13:17:40 +05:30
Gaurav Kohli
6ab2197424 firmware_class: Avoid memory leak when FW_OPT_NOCACHE is set
During call of request_firmware_into_buf, if FW_OPT_NOCACHE is
set then release_firmware skip freeing of fw_id. So explicitly
freeing the same to avoid memory leak.

Change-Id: I7e1d6f8f06c4532b2bcbf256267fd1e90f5ced70
Signed-off-by: Gaurav Kohli <gkohli@codeaurora.org>
2017-06-13 00:02:17 -07:00
Hareesh Gundu
71c3b2e17c msm: kgsl: Defer issue commands to worker thread
Currently submit ioctl getting blocked till the commands
gets added to ringbuffer incase inflight count is less
than context burst count. If the submit command happens
in GPU slumber state, it will add the GPU wakeup time to
submit IOCTL. This will add latency in preparing next frame
in CPU side. Defer commands submission to dispatcher worker,
if the GPU is in slumber state.

CRs-Fixed: 2055107
Change-Id: I099ba721e02bbcd8ccadb1bc518c7c1ef4fb7e21
Signed-off-by: Hareesh Gundu <hareeshg@codeaurora.org>
2017-06-13 12:03:27 +05:30
Rohit Kumar
4282bbbb81 ASoC: msm: qdspv6: Fix wrong smmu sid for ULL playback
SMMU sid is set to 0 in q6asm_set_shared_circ_buff and
q6asm_set_shared_pos_buff in 32 bit arch. Fix it to
send proper SID to ADSP when sharing buffer.

Change-Id: I00cc0f881acd7a4a52292e65360ea7b03f2f0212
Signed-off-by: Rohit Kumar <rohitkr@codeaurora.org>
2017-06-12 23:02:49 -07:00
Vijayavardhan Vennapusa
c09e5063e1 ARM: dts: msm: Add tune2_efuse_addr for SDM660/630
Pass tune2_efuse_addr register and bit field to be read from the register
from the device tree, which will be used to read HS_TRIM value and update
the value to QUSB2_PHY_TUNE2_REGISTER for eye-diagram test passing.

Change-Id: I64b4febf41f2e2c027c1d220e7037d8eeec27d46
Signed-off-by: Vijayavardhan Vennapusa <vvreddy@codeaurora.org>
2017-06-13 11:27:56 +05:30
Linux Build Service Account
c0f6993430 Merge "msm: ipa: fix hdr table full condition" 2017-06-12 21:43:19 -07:00
Linux Build Service Account
cfec669251 Merge "power: qpnp-fg-gen3: Qualify aborting capacity learning" 2017-06-12 21:43:18 -07:00
Linux Build Service Account
a5ab1b911f Merge "drm/msm: Fix kernel address issue of profile buffer" 2017-06-12 21:43:17 -07:00
Linux Build Service Account
54726d07cd Merge "qseecom: Fix accessing userspace memory in kernel space" 2017-06-12 21:43:16 -07:00
Linux Build Service Account
dd7a94047f Merge "msm: kgsl: Log clk set, enable and prepare failure" 2017-06-12 21:43:15 -07:00
Linux Build Service Account
b9d279f54f Merge "soc: qcom: update return value for minidump add region" 2017-06-12 21:43:14 -07:00
Linux Build Service Account
91e88c87dd Merge "clk: qcom: Add regmap mux-div clocks support" 2017-06-12 21:43:13 -07:00
Yunyun Cao
916012368c drm: msm: Enable asynchronous driver probing
Do asynchronous driver probing of drm msm driver
to improve the device boot-up time.

Change-Id: I19e12a8330b35efb3d89abf9ba825637b08e71f3
Signed-off-by: Yunyun Cao <yunyunc@codeaurora.org>
2017-06-12 18:38:28 -07:00
Jordan Crouse
7d46546d28 drm/msm: Add per-instance submit queues
Currently the priority and other behavior of a command stream
is provided by the user application during submission and
the application is expected to internally maintain the settings
for each 'context' or 'rendering queue' and specify the correct
ones.

This works okay for simple cases but as applications become more
complex we will want to set context specific flags and do various
permisson checks to allow certain contexts to enable additional
privileges.

Add kernel-side submit queues to be analogous to 'contexts' or
'rendering queues' on the application side. Each file descriptor
instance will maintain its own list of queues. Queues cannot be
shared between file descriptors.

For backwards compatibility context id '0' is defined as a default
context specifying middle priority and no special flags. This is
intended to be the usual configuration for 99% of applications so
that a garden variety application can function correctly without
creating a queue. Only those applications requiring the specific
benefit of different queues need create one.

In addition to the basic infrastructure, allow the user to specify
the queue priority - this will be used in lieu of the legacy
flags to set priority during the submission. Only the master DRM
instance can set the highest priority, but all the others are open
to all processes.

Change-Id: Ic0dedbad02fa27c0ba20c1157a05ddb143e46357
Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org>
2017-06-12 15:11:52 -06:00
Jordan Crouse
7851820e84 drm/msm: Use per-ring submit lists
To make it easier to determine what submit(s) are currently active
on any given ring, store the active submits in per-ring lists instead
of a master list.

Change-Id: Ic0dedbadb331cd8e4e85dfcfa51cb1ceabe6efa9
Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org>
2017-06-12 15:11:51 -06:00
Rob Clark
5fb0642400 drm/msm: fix leak in failed submit path
Change-Id: Ic0dedbadf485dd63ef727402b653a9d996a13632
Signed-off-by: Rob Clark <robdclark@gmail.com>
Git-commit: 40e6815bba6e34e5560e8855b43cd3eb17b24b09
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
[jcrouse@codeaurora.org: fix merge conflicts and initialize node at create]
Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org>
2017-06-12 15:11:51 -06:00
Jordan Crouse
8416e67721 drm/msm: Improved rd_full buffer dumping
Always print the iova and size for every buffer in a commit when
rd_full is enabled but only dump the contents for input buffers.
Also make imported buffers work with vmap so that they can be
safely dumped.

Change-Id: Ic0dedbad6ed5c426dc85a9c089b6c86c95c727cc
Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org>
2017-06-12 15:11:50 -06:00
Rob Clark
8691a54109 drm/msm/rd: add module param to dump all bo's
By default, if using $debugfs/.../rd to log cmdstream, only the
cmdstream buffers themselves are logged.  But in some cases we want
to capture other buffers in the submit (to see VBO's or shaders).
So add a mod-param knob to control this.

Change-Id: Ic0dedbadf993d9ab2c7a44f14e7720e7567a6da1
Signed-off-by: Rob Clark <robdclark@gmail.com>
Git-commit: 79c21187ca370f37302f0d5c16c387985d7b8ba1
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
[jcrouse@codeaurora.org: fix minor merge conflicts]
Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org>
2017-06-12 15:11:50 -06:00
Rob Clark
fdde54c4d4 drm/msm/rd: split out snapshot_buf helper
(reduce the noise in next patch)

Change-Id: Ic0dedbadd4b1100ff7b203f120f4acd0c4bf8d09
Signed-off-by: Rob Clark <robdclark@gmail.com>
Git-commit: 6507e799f432d9fa86ba398b095ef1139a70deac
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
[jcrouse@codeaurora.org: fixed minor merge conflicts]
Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org>
2017-06-12 15:11:50 -06:00
Skylar Chang
6e0ccc547b msm: ipa: fix hdr table full condition
The header table is managed by IPA driver and header cannot be
moved. Instead a "free list" is maintained for deleted headers.
This change fixes a bug on header addition where the table is considered
full only if it is full and the free list is empty.

Change-Id: Ief8a384ea105c6f0179faaf95a98b9731fe6a01e
CRs-Fixed: 2048799
Acked-by: Ady Abraham <adya@qti.qualcomm.com>
Signed-off-by: Skylar Chang <chiaweic@codeaurora.org>
2017-06-12 14:11:45 -07:00
Jordan Crouse
7949249042 drm/msm: Fix possible overflow issue in submit_cmd
When verifying that the submit_cmd offset and size do not exceed the
bounds of the GEM object make sure to cast the math operation
into a suitably large buffer to account for overflow.

Change-Id: Ic0dedbad97513ee538d539e771038b3cf0405e91
Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org>
2017-06-12 15:08:08 -06:00
Subbaraman Narayanamurthy
b9c7f08657 power: qpnp-fg-gen3: Qualify aborting capacity learning
Currently, capacity learning algorithm is aborted when the
charging status goes to not charging. This can happen with qnovo
enabled charging where stopping the pulsing can lead to charging
status change. Qualify aborting capacity learning based on the
qnovo enable status and input presence.

While at it, abort the capacity learning when the charging status
goes to discharging and charger is removed.

Change-Id: I4546e8880be0658748157cb13f048610eee932a3
Signed-off-by: Subbaraman Narayanamurthy <subbaram@codeaurora.org>
2017-06-12 12:04:39 -07:00
Subbaraman Narayanamurthy
1a3659dcd4 power: qpnp-fg-gen3: fix an unbalanced irq disable for delta_bsoc irq
Currently, rerun_election() is called on delta_bsoc_irq_en
votable to disable delta_bsoc interrupt during probe. However, it
doesn't set the internal variable for votable to not allow a
similar vote again. When a vote is made later to disable the
interrupt again, it can end up in invoking the callback again.

This leads to an unbalanced interrupt disable warning. Fix it.

CRs-Fixed: 2058754
Change-Id: I30c35be5275b5b310cf9b17ea4660a3e2e89c59a
Signed-off-by: Subbaraman Narayanamurthy <subbaram@codeaurora.org>
2017-06-12 12:04:38 -07:00
Linux Build Service Account
85baaeb2e2 Merge "Policy_engine: Add module parameter to disable PD" 2017-06-12 10:41:38 -07:00
Linux Build Service Account
5a580b8916 Merge "diag: Remove BOM in file" 2017-06-12 10:41:37 -07:00
Linux Build Service Account
584b2405fd Merge "usb: gadget: Bind android devices for all UDC gadgets" 2017-06-12 10:41:36 -07:00
Linux Build Service Account
0b271fdd58 Merge "ARM: dts: msm: specify a PWM mode threshold for BoB on SDM660" 2017-06-12 10:41:35 -07:00
Linux Build Service Account
86bcb4d5ab Merge "SDM660: ADSPRPC: Handle NULL pointer dereference" 2017-06-12 10:41:34 -07:00