Commit graph

878,439 commits

Author SHA1 Message Date
Isaac J. Manjarres
d12ac73e1a haven: Add support for the MEM_QCOM_LOOKUP_SGL call
The MEM_QCOM_LOOKUP_SGL RM call is required to retrieve
handles for memparcels created through hyp assign. Thus,
add support for it in the RM driver.

Change-Id: Ib854187daffa13a44c948111ef560c3479f2590c
Signed-off-by: Isaac J. Manjarres <isaacm@codeaurora.org>
2020-02-13 16:26:18 -08:00
Isaac J. Manjarres
53f0964dce haven: Add support for the mem-buf driver's message queue
Expose the label used for the mem-buf message queue.

Change-Id: I6f7c7629f9f6a4aefaea65653187ba210ef6ceb8
Signed-off-by: Isaac J. Manjarres <isaacm@codeaurora.org>
2020-02-13 16:26:18 -08:00
Isaac J. Manjarres
c58ff8669f haven: Add the memparcel handle as a well known haven type
The memparcel handles are standard in the haven interface,
so expose them to the rest of the kernel.

Change-Id: Id8eafd5f3fe0f1403b9b76b9a0176c11d6546707
Signed-off-by: Isaac J. Manjarres <isaacm@codeaurora.org>
2020-02-13 16:26:17 -08:00
Amir Vajid
ba4792aae1 PM / devfreq: Remove dependencies between sysfs nodes and suspend count
This change reverts commit 5e33579a6a ("devfreq: Do not allow tunable
updates when device is suspended") and commit db4f4a0933 ("PM/devfreq:
Do not switch governors from sysfs when device is suspended").

Userspace updates to sysfs nodes like governor and polling_interval are
currently not allowed when there is a non-zero suspend count. This
requirement existed in the past due to hardware dependencies in some
devfreq drivers. However, these hardware dependencies should be handled
by the relevant devfreq drivers rather than the devfreq framework so
remove the suspend count checks in these devfreq framework sysfs APIs.

Change-Id: I8010b519d72784a6b90955acc7899c1a520aa7e7
Signed-off-by: Amir Vajid <avajid@codeaurora.org>
2020-02-13 16:04:38 -08:00
Elliot Berman
e3f87b092f soc: qcom: Remove incorrect error check from Guest VM PIL Loader
Incorrect error check and return value in guestvm_load_start causes
kernel to loop this function indefinitely.

Change-Id: I483cc084b4caa02c3478abcc856123dfa14216e9
Signed-off-by: Elliot Berman <eberman@codeaurora.org>
2020-02-13 15:52:52 -08:00
Mayank Rana
57b851d2af eud: Handle multiple events with eud interrupt
With USB spoof connect functionality, eud hardware is generating
interrupt with status register updated with VBUS present and TX
buffer empty. Current eud ISR expects to have only single event
generated with each interrupt. It doesn't handle received valid
events. Fix this ISR logic to handle multiple events.

Change-Id: I819b8a7f5be5b32753467495416103b690a4a83e
Signed-off-by: Mayank Rana <mrana@codeaurora.org>
2020-02-13 11:24:13 -08:00
qctecmdr
e8c9c4f0ab Merge "arm64: defconfig: Enable Haven HVC Driver" 2020-02-13 11:21:05 -08:00
qctecmdr
0e3751b095 Merge "defconfig: Enable ARCH_QTI_VM config" 2020-02-13 11:21:05 -08:00
Subramanian Ananthanarayanan
8a857c7140 i3c: i3c-master-msm-geni: Support for 3.4 Mhz,400 Khz
The change involes support for 3.4 Mhz and modified clk values for 400 Khz
to support NFC enumeration. Also changed open drain frequency to be used
from i2c clk freq passed from DTSI.

Change-Id: Iee75cfcd630e905b10bff790de84b1da2efdc042
Signed-off-by: Subramanian Ananthanarayanan <skananth@codeaurora.org>
2020-02-13 11:19:39 -08:00
Rishabh Bhatnagar
8878f18eff kernel_headers: Fix headers not detected in incremental builds
Currently the Soong logic doesn't kick in if a change updates
headers but doesn't update gen_headers_arm*.bp files for
incremental builds. Fix the issue by making inputs to the
kernel_headers.py script as variables instead of a list.

Change-Id: I9737f6d655848458bfda70b8c6f4d9aa896a98fc
Signed-off-by: Rishabh Bhatnagar <rishabhb@codeaurora.org>
2020-02-13 10:22:22 -08:00
Isaac J. Manjarres
4bb0643878 dma-mapping-fast: Align memory allocation to dma_alloc_attrs expectations
On newer kernels, memory allocated by dma_alloc_attrs() is
expected to be zeroed out upon allocation. The allocation
paths in fastmap do not currently account for this new
requirement, so update them to zero out memory, unless
the client explicitly asks for memory to not be zeroed out.

Change-Id: I5c7fa81ab4b8fa98890036082883769ab12443c6
Signed-off-by: Isaac J. Manjarres <isaacm@codeaurora.org>
2020-02-13 10:11:33 -08:00
George Shen
797b31ce1f msm: cvp: Disable CVP power collapse
While investigating hardware issue, disabling CVP power collapse
to unblock CVP clients' integration tests.

Change-Id: I463e6216d390296ff958abb7382de4829f87e386
Signed-off-by: George Shen <sqiao@codeaurora.org>
2020-02-13 09:59:34 -08:00
qctecmdr
4c93b2bdf0 Merge "serial: msm_geni_serial: Manage HSUART clocks when read HW Ver" 2020-02-12 23:42:26 -08:00
Shyam Kumar Thella
47bdf1e475 leds: qti-flash: Add individual APIs to enable and disable switch
Currently qti_flash_led_switch_brightness_set() is used to enable or
disable switch. Split it into separate APIs to enable and disable
switch. This will make it easier to control switches which is required
for implementing slow-sync flash feature.

Change-Id: I668ab872d1d646f97ed8fbfba4dfca6b4db5bc70
Signed-off-by: Shyam Kumar Thella <sthella@codeaurora.org>
2020-02-13 10:55:21 +05:30
Jack Pham
874b3e3188 defconfig: lahaina-gki: Enable USB Audio QMI Service driver
Enable QMI service driver used to support ADSP tunneling of
USB host mode audio.

Change-Id: I5632e2918a87441d717e5d7a0e5a8242bd4d607e
Signed-off-by: Jack Pham <jackp@codeaurora.org>
2020-02-12 20:18:30 -08:00
Jack Pham
e61d2a2116 sound: usb: Fix incorrect type assignments
Change the map_pcm_format() helper to return a snd_pcm_format_t
instead of a plain int to fix the following sparse warnings:

 sound/usb/usb_audio_qmi_svc.c:1135:26: expected restricted
  snd_pcm_format_t [usertype] pcm_format
	subs->pcm_format = pcm_format;

 sound/usb/usb_audio_qmi_svc.c:1135:26: got int [assigned] pcm_format
	subs->pcm_format = pcm_format;

 sound/usb/usb_audio_qmi_svc.c:1135:26: warning: incorrect type in
  assignment (different base types)
	subs->pcm_format = pcm_format;

 sound/usb/usb_audio_qmi_svc.c:962:24: expected int
		return SNDRV_PCM_FORMAT_S8;

 sound/usb/usb_audio_qmi_svc.c:962:24: got restricted snd_pcm_format_t
  [usertype]
		return SNDRV_PCM_FORMAT_S8;

 sound/usb/usb_audio_qmi_svc.c:962:24: warning: incorrect type in return
  expression (different base types)
		return SNDRV_PCM_FORMAT_S8;

... and so on.

For these warnings:

 sound/usb/usb_audio_qmi_svc.c:559:47: expected unsigned short
  [usertype] usb_audio_spec_revision
		resp->usb_audio_spec_revision =

 sound/usb/usb_audio_qmi_svc.c:559:47: got restricted __le16 [usertype]
  bcdADC
		resp->usb_audio_spec_revision =

 sound/usb/usb_audio_qmi_svc.c:559:47: warning: incorrect type in
  assignment (different base types)
		resp->usb_audio_spec_revision =

Fix these by passing the bcdADC value through le16_to_cpu before
assigning to the usb_audio_spec_revision member.

Change-Id: I0be5848846be7e29566a7854c5190634bce4347d
Signed-off-by: Jack Pham <jackp@codeaurora.org>
2020-02-12 20:18:13 -08:00
Jack Pham
4ff8dc0db3 arm64: defconfig: Enable USB_F_FS_IPC_LOGGING for lahaina_debug, take 3
Since CONFIG_USB_F_FS_IPC_LOGGING was never explicitly set, despite
the "default IPC_LOGGING" in its Kconfig, it is prone to getting
disabled when performing a make config/menuconfig with the fragmented
configs. Fix this once and for all by explicitly marking it =y
in lahaina_debug.config.

Change-Id: I68c9a39ea2a0d0116f4685314daf717802af8481
Signed-off-by: Jack Pham <jackp@codeaurora.org>
2020-02-12 19:39:26 -08:00
Subbaraman Narayanamurthy
29ec019e35 power: supply: qti_battery_charger: Handle generic notification
Charger firmware sends some battery related events with a generic
notification opcode. Handle such notifications as well to send
events up to the userspace.

Change-Id: Ia35fb7dbe56183d3c7c7a66b5f387b94072e6ed0
Signed-off-by: Subbaraman Narayanamurthy <subbaram@codeaurora.org>
2020-02-12 18:53:14 -08:00
Subbaraman Narayanamurthy
f8b9116ee0 soc: qcom: qti_battery_debug: Update QBG device context dump length
QBG device context dump length has been increased to 598 words in
the charger firmware. Increase the length to support upto 4KB.

Change-Id: I4a0a28044a54cdbde146101384f5a1ccf73b1562
Signed-off-by: Subbaraman Narayanamurthy <subbaram@codeaurora.org>
2020-02-12 18:52:36 -08:00
Fei Mao
f75f798d17 arm64: defconfig: Enable new touchscreen on Lahaina
Enable new Focaltech touchscreen driver on Lahaina.

Change-Id: If3d837b3070899fc019339d93866e4025fc87a85
Signed-off-by: Fei Mao <feim1@codeaurora.org>
2020-02-12 17:50:25 -08:00
Fei Mao
5e8dfc019b arm64: defconfig: Enable touchscreen on Lahaina
Enable ST Micro touchscreen driver on Lahaina.

Change-Id: Iae3fd00d362bd981625006419ca1514682264ee3
Signed-off-by: Fei Mao <feim1@codeaurora.org>
2020-02-12 17:50:09 -08:00
Harshdeep Dhatt
804ef55605 defconfig: lahaina: Enable KGSL driver
Enable the kgsl driver on lahaina.

Change-Id: I85be526a2d3c57daac3813ecc2a2cefc3ddeb3af
Signed-off-by: Harshdeep Dhatt <hdhatt@codeaurora.org>
2020-02-12 18:48:46 -07:00
Mukesh Kumar Savaliya
0c8c733758 serial: msm_geni_serial: Cover console under GENI_CONSOLE config
Cover console specific functionality under driver defined defconfig.
This helps to enable/disable console in a primary/secondary image based
on need.

Currently on GKI based kernel, SERIAL_CORE_CONSOLE seem to enable console
functionality which is not as expected. This change makes perf image to
work without Serial console.

Change-Id: I571dfd70b280189a9fd741db1e97ef3e650343f8
Signed-off-by: Mukesh Kumar Savaliya <msavaliy@codeaurora.org>
2020-02-12 17:07:35 -08:00
Subbaraman Narayanamurthy
8c88d4e9ff defconfig: lahaina: Enable DYNAMIC_DEBUG
Enable DYNAMIC_DEBUG which is useful for debugging.

Change-Id: I93adcbba62380721751e58931d182729790b29b9
Signed-off-by: Subbaraman Narayanamurthy <subbaram@codeaurora.org>
2020-02-12 16:43:31 -08:00
Siddharth Gupta
1ad129ee39 firmware: shmbridge: Enable shmbridge by default
The SCM driver depends on shmbridge to make calls to the TZ. This
change enables shmbridge by default if CONFIG_QCOM_SCM is set.

Change-Id: I56a2cf35d5621f9b7ca4e8b3e854671e8d40071c
Signed-off-by: Siddharth Gupta <sidgup@codeaurora.org>
2020-02-12 15:54:33 -08:00
Mukesh Kumar Savaliya
c1d740e838 serial: msm_geni_serial: Manage HSUART clocks when read HW Ver
This change is to make sure UART doesn't turn on/off clocks for
console usecase. HSUART tries to store firmware version for debug
purpose which needs clocks to be ON, hence keep reading of FW
version only for HSUART.

Change-Id: I95025872852df3eb5b8252dfe1cc6f5be95586be
Signed-off-by: Mukesh Kumar Savaliya <msavaliy@codeaurora.org>
2020-02-13 03:45:37 +05:30
qctecmdr
d184fa35bf Merge "msm: kgsl: Fix gdsc disable timeout during reset" 2020-02-12 12:44:55 -08:00
qctecmdr
824167f1ba Merge "ASoC: pcm: update the start-up sequence for playback" 2020-02-12 12:44:54 -08:00
qctecmdr
d6d4969a7e Merge "sched: micro optimization for sched_energy_present" 2020-02-12 12:44:54 -08:00
qctecmdr
933bad2feb Merge "Add hdcp_qseecom driver snapshot for Lahaina" 2020-02-12 12:44:54 -08:00
Prakruthi Deepak Heragu
43fc0a1e21 arm64: defconfig: Enable QCOM EUD driver
Enable the EUD driver.

Change-Id: Ic2c01850f2dd3d2e36090526aaa0483ff2553f7e
Signed-off-by: Prakruthi Deepak Heragu <pheragu@codeaurora.org>
2020-02-12 10:13:45 -08:00
Mike Tipton
6621c8dad5 clk: qcom: clk-rpmh: Wait for completion when enabling clocks
The current implementation always uses rpmh_write_async, which doesn't
wait for completion. That's fine for disable requests since there's no
immediate need for the clocks and they can be disabled in the
background. However, for enable requests we need to ensure the clocks
are actually enabled before returning to the client. Otherwise, clients
can end up accessing their HW before the necessary clocks are enabled,
which can lead to bus errors.

Use the synchronous version of this API (rpmh_write) for enable requests
in the active set to ensure completion.

Completion isn't required for sleep/wake sets, since they don't take
effect until after we enter sleep. All rpmh requests are automatically
flushed prior to entering sleep.

Change-Id: I3d3261159bb30e4e149f4cb6b3e9d60b018a5d5e
Signed-off-by: Mike Tipton <mdtipton@codeaurora.org>
2020-02-12 10:00:02 -08:00
qctecmdr
378eb426d0 Merge "mm: set the watermark_boost before updating the low and high wmarks" 2020-02-12 05:13:21 -08:00
qctecmdr
f1adcf9983 Merge "ion: msm: Add support for the Trusted UI(TUI) dynamic carveout heap" 2020-02-12 05:13:21 -08:00
qctecmdr
9e911020fe Merge "msm: cvp: Relocate Synx init/uninit calls" 2020-02-12 05:13:21 -08:00
John Stultz
b5e4fb1b2e ANDROID: serdev: Fix platform device support
After commit 3c996ff8858 ("ANDROID: serdev: add platform device
support") landed, we started seeing boot panics on HiKey960/HiKey.

After some debugging I found the patch is passing a serdev_device->dev
pointer to match(), which expects the dev pointer to be
contained in a platform_device structure instead. When it uses
container_of, it ends up miscast and we get bad values.

Alistair suggested this fix which seems to avoid the issue.

Signed-off-by: John Stultz <john.stultz@linaro.org>
Bug: 146517987
Change-Id: I6354aeb4008fff85264a3c848c6c95fb8ca5b07a
Git-commit: 515764a925
Git-repo: https://android.googlesource.com/kernel/common
Signed-off-by: Blagovest Kolenichev <bkolenichev@codeaurora.org>
2020-02-12 05:09:37 -08:00
Ajay Prathi
0e96cc4199 msm: tsens: Add code to support thermal framework changes
Add code to update dev value in tsens struct which
will be compared in thermal framework to check whether
the device pointer is matching with thermal zone or not.

Change-Id: Ic7605034e48585bcb25641306c1703b8399b4e0e
Signed-off-by: Ajay Prathi <aprathi@codeaurora.org>
2020-02-12 18:08:29 +05:30
Maulik Shah
6bcbd9920b soc: qcom: rpmh: Add completion status to rpmh debug information
Linux kernel lockup case can be either due to RSC interrupt
pending at GIC unable to service or due to completion did not
get a chance to run and finish.

Currently rpmh debug only prints pending IRQ status at GIC.
Add completion status as well to rpmh debug information.

Change-Id: Iaee639f744be19c2cffb701547623c19bdabfb30
Signed-off-by: Maulik Shah <mkshah@codeaurora.org>
2020-02-12 16:09:17 +05:30
Hareesh Gundu
8f60d77911 msm: kgsl: Add rgmu_init() for firmware loading
Add rgmu_init() to load firmware for RGMU
based targets.

Change-Id: I49d250db70b49e220ce4292e12b6cb852686e678
Signed-off-by: Hareesh Gundu <hareeshg@codeaurora.org>
2020-02-12 01:58:00 -08:00
qctecmdr
91f2f60060 Merge "sched/core: Fix size of rq::uclamp initialization" 2020-02-12 00:18:29 -08:00
qctecmdr
9484b7d44c Merge "haven: Add VM management support for clients" 2020-02-12 00:18:29 -08:00
qctecmdr
f3bd0349ce Merge "sched/fair: bonus vruntime for task boost 3" 2020-02-12 00:18:29 -08:00
qctecmdr
b7f7f81480 Merge "mm, oom: Modify default value of panic_on_oom" 2020-02-12 00:18:29 -08:00
Subbaraman Narayanamurthy
f0d6115e00 leds: qti-flash: Update interrupt names
Update interrupt names to have "flash" prefix so that all the
interrupts for flash LED can be monitored easily.

Change-Id: Ib7c17ea48110461823702c8d11b7554ddebbbb26
Signed-off-by: Subbaraman Narayanamurthy <subbaram@codeaurora.org>
2020-02-11 18:09:53 -08:00
Sudheer Papothi
90cd260212 ASoC: Update the widgets power up/down sequence
Widgets power up/down sequence in dapm is specific
to platform. Change makes msm specific changes to the
sequence.

Change-Id: I5b501b5dc1b167e339c95fbbc7b5fc72dc9bdb89
Signed-off-by: Gopikrishnaiah Anandan <agopik@codeaurora.org>
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
2020-02-11 17:54:38 -08:00
qctecmdr
2a0b4922bc Merge "Revert "defconfig: lahaina: enable FSA driver on Lahaina"" 2020-02-11 17:42:02 -08:00
qctecmdr
00b9f1f54c Merge "kernel_headers: Add missing header for lahaina" 2020-02-11 17:42:02 -08:00
George Shen
bf518628e9 msm: cvp: Enable CVP auto PIL
The command in init.qcom.rc to load CVP firmware will take
effect with this change.

Change-Id: Ib45c77c8f34a12a9c01b462847cf2fc25ae1452d
Signed-off-by: George Shen <sqiao@codeaurora.org>
2020-02-11 16:33:09 -08:00
Guru Das Srinagesh
444271f5b6 thermal: adc-tm: Fix match table description and Makefile
Due to an error in the specification of the multiple compatible strings
in the match table, nodes defined with compatible string "adc-tm5-iio"
failed to probe. Fix this.

Also change the compilation recipe in the Makefile to prevent generation
of multiple kernel modules.

Change-Id: I6cf544b202dfb0773215aeaeae8a12bae5b79dde
Signed-off-by: Guru Das Srinagesh <gurus@codeaurora.org>
2020-02-11 15:49:51 -08:00
Sudheer Papothi
da36af38c0 ASoC: pcm: update the start-up sequence for playback
Codec should be started before the CPU to ensure that there is no data
loss during playback.Current sequence enables the CPU first followed by
codec.This change updates the sequence prevent any playback data loss.

Also, squash the below change to fix possible NULL pointer dereference
issue

ASoC: pcm: Check for capture path in all codec_dais

During soc_pcm_prepare, check for capture path for all
the codec_dais instead of the last codec_dai. This is
will help to set pcm start event for all the codec dais
that has capture_active set to high. Change checks for
all the codec_dais capture_active bit to set start stream
event.

Change-Id: I3f1b457ecd169f6ecc42e15f2151ede9cdbd580d
Signed-off-by: Gopikrishnaiah Anandan <agopik@codeaurora.org>
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
Signed-off-by: Meng Wang <mwang@codeaurora.org>
2020-02-11 15:21:39 -08:00