Enable MHI driver for MSM8996.
Change-Id: I2161f6cedc4152bb7c48fec9868cfc7070a5d494
Signed-off-by: Andrei Danaila <adanaila@codeaurora.org>
Signed-off-by: Tony Truong <truong@codeaurora.org>
Enable MHI runtime PM by default to enable additional
power savings.
Change-Id: I115af9e823ed685d7bf6e2ebaf18ad526256dc98
Signed-off-by: Andrei Danaila <adanaila@codeaurora.org>
Signed-off-by: Tony Truong <truong@codeaurora.org>
Fix race condition in mhi_poll_inbound which could leave the
bounce buffer list and TRE list out of sync.
Change-Id: I76c7de75256b59f8a0dff2a85af733c441761385
Signed-off-by: Andrei Danaila <adanaila@codeaurora.org>
Signed-off-by: Tony Truong <truong@codeaurora.org>
Read the EXEC_ENV register from device to determine the MHI
base state.
Change-Id: Id70a360cfa3775a7186e5059306385a37960df2d
Signed-off-by: Andrei Danaila <adanaila@codeaurora.org>
Signed-off-by: Tony Truong <truong@codeaurora.org>
Enable dynamic allocation of event rings from the coherent pool
to ensure appropriate page alignment with device.
Change-Id: Id57ccd889cf96aad73f4ada01405e2d734351c8c
Signed-off-by: Andrei Danaila <adanaila@codeaurora.org>
Signed-off-by: Tony Truong <truong@codeaurora.org>
Set the correct DMA mask on the platform device to
avoid bounce buffering from the default 32 bit mask.
Change-Id: I7e201e83fd21b0f0a6f57754a3b6f3eded9be58f
Signed-off-by: Andrei Danaila <adanaila@codeaurora.org>
Signed-off-by: Tony Truong <truong@codeaurora.org>
Replace the MHI defined enum for return codes with
kernel standard return codes. This greatly improves readability
and parsing of errors by userspace clients.
Change-Id: Ica47f8c3a149f23243b5fb6a4aabcdc0a36b1535
Signed-off-by: Andrei Danaila <adanaila@codeaurora.org>
Signed-off-by: Tony Truong <truong@codeaurora.org>
Failed M2 wakeups may represent a serious hardware problem.
The device is refusing to wake up from low power states and all
modem functionality is now stalled.
Track these wakeup attempts.
Change-Id: I3115a4416f85290c5faead0e2d9f280d8cc3b662
Signed-off-by: Andrei Danaila <adanaila@codeaurora.org>
Signed-off-by: Tony Truong <truong@codeaurora.org>
Enable runtime PM on PCIe device to ensure sync with
PCIe framework.
Change-Id: Ied432440df0dc788642fe1a1a8d9195b6cc1cf7c
Signed-off-by: Andrei Danaila <adanaila@codeaurora.org>
Signed-off-by: Tony Truong <truong@codeaurora.org>
Remove unused macros for TRE sizes. This information is
now present in device tree.
Change-Id: Id3ca59c62d66ce8913e83fcba60e1a912cf146ea
Signed-off-by: Andrei Danaila <adanaila@codeaurora.org>
Signed-off-by: Tony Truong <truong@codeaurora.org>
Add mdmcalifornium to the list of supported PCIe devices
by MHI.
Change-Id: I34e846caceb8fd2808594470cccbb7e318011cda
Signed-off-by: Andrei Danaila <adanaila@codeaurora.org>
Signed-off-by: Tony Truong <truong@codeaurora.org>
In case of BHI failure, read the device BHI error registers
in the hopes of root causing the failure.
Change-Id: I0c695f7afc873d6fd5c0c9d88e9885799b228d46
Signed-off-by: Andrei Danaila <adanaila@codeaurora.org>
Signed-off-by: Tony Truong <truong@codeaurora.org>
Enable the local bounce buffer list before the device
channel initialization sequence.
Change-Id: Ia87698dc83807727f6897356bf9b23f123c53851
Signed-off-by: Andrei Danaila <adanaila@codeaurora.org>
Signed-off-by: Tony Truong <truong@codeaurora.org>
Enable correct allignment of MHI channels to the
ring size rounded up to the next power of two as
per device requirement.
Change-Id: Ic77c43fdbcde2ec3b6f08e3062eaf778eb13ec5b
Signed-off-by: Andrei Danaila <adanaila@codeaurora.org>
Signed-off-by: Tony Truong <truong@codeaurora.org>
Resolve issue whereby UL DL properties were
being incorrectly set for non HW event rings.
CRs-Fixed: 827294
Change-Id: Ie279061e84c0f2498393c5d7bfaef404307c84da
Signed-off-by: Andrei Danaila <adanaila@codeaurora.org>
Signed-off-by: Tony Truong <truong@codeaurora.org>
Enable logging based on MHI defconfig option. This
avoids excessive logging in secondary boot image.
Change-Id: Ie22d56d781feadb2d484e6117c9c25ee29aa5299
Signed-off-by: Andrei Danaila <adanaila@codeaurora.org>
Signed-off-by: Tony Truong <truong@codeaurora.org>
Enable parsing of device window size from device tree
and calculating the appropriate addressing limitations.
Change-Id: I252a593a74f0cc00e6295a45d4d13db6c79cdfca
Signed-off-by: Andrei Danaila <adanaila@codeaurora.org>
Signed-off-by: Tony Truong <truong@codeaurora.org>
Enable clients to queue virtual buffers, thus leaving
all the DMA operations to MHI.
Change-Id: I824d2f387b1a21d322ca0628963995824227bd76
Signed-off-by: Andrei Danaila <adanaila@codeaurora.org>
Enable the queueing of virtual buffers to MHI instead
of buffers obtained from streaming DMA.
Change-Id: I8ba25c1f28cbd1cb302aec184864ed2e25672d4a
Signed-off-by: Andrei Danaila <adanaila@codeaurora.org>
Enable the queueing of virtual buffers to MHI instead
of buffers obtained from streaming DMA.
Change-Id: I3f77c7d5d9924659ce13e454646d5a65402353cc
Signed-off-by: Andrei Danaila <adanaila@codeaurora.org>
Enable bounce buffering scheme in MHI for the cases
where allocated APQ memory falls outside of the memory range
which the device can access.
Change-Id: I9f40b0dda2f49111b7deb22973e6399fada90094
Signed-off-by: Andrei Danaila <adanaila@codeaurora.org>
When entering a sleep mode, idle drivers notifies scheduler to help
scheduler make better scheduling decisions by not waking up sleeping
CPUs/clusters.i
The change was left out of original 4.4 merge due to dependency on
scheduler changes.
Change-Id: Id366432ac4acca390692ef810adbd6edec4a5bfb
Signed-off-by: Mahesh Sivasubramanian <msivasub@codeaurora.org>
The sensor APIs have changed from using long to int for temperatures. Update
the variables types from long to int.
Change-Id: Id183b83339ceaacb6d340cca138845dd5ac6fbdf
Signed-off-by: Mahesh Sivasubramanian <msivasub@codeaurora.org>
Match debugfs creation to variable type instead of a 'bool' one.
This fixes a compile issue under 4.4 since debugfs_create_bool now
expects a bool* instead of a u32*.
Signed-off-by: Clarence Ip <cip@codeaurora.org>
Configure the PMCOABLT and PMICOABLT devices for MSMCOBALT.
Change-Id: Ic896d7faea6405f260117fdd7ec84a88b3c74aac
Signed-off-by: Nicholas Troast <ntroast@codeaurora.org>
Configure the SPMI PMIC arbiter device for MSMCOBALT.
Change-Id: I6ce0e9724acff8309e0f518a243b3e2b25c80bcf
Signed-off-by: Nicholas Troast <ntroast@codeaurora.org>
Use the upstream naming convention and update the ufs driver
compatible string.
Change-Id: Iee4d316c99d0d47537514a93ad91e14630970712
Signed-off-by: Venkat Gopalakrishnan <venkatg@codeaurora.org>
The direct firmware class API support original relied
on the destination address to determine which file operations
to link to the data binary file. Since the 4.4 kernel version,
this was changed to an attribute group.
Fix this by adding a direct firmware API attribute group and
appropriately assign it when necessary.
Signed-off-by: David Keitel <dkeitel@codeaurora.org>
Add the oneshot_sync driver as of msm-3.18 commit
7892968f (sync: oneshot_sync: Update oneshot_sync for new sync APIs).
Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org>
This is a snapshot of the sysmon glink library as of
msm-3.18 commit
d5809484
(Merge "msm: ipa: fix race condition when teardown pipe")
Signed-off-by: David Keitel <dkeitel@codeaurora.org>
While compiling for usermode linux for x86 architecture, observed
compilation issues with probable usage of uninitialized variables.
This change initializes the variables.
Signed-off-by: Jeevan Shriram <jshriram@codeaurora.org>
flask.h was included in the above file. This is autogenerated header
which gets produced during compilation of selinux. This causes issues
for other module (PFK) which includes objsec.h and compiles after
selinux. Since removal of the above headers does not break compilation,
they seem to be redundant and can be removed.
Signed-off-by: Gilad Broner <gbroner@codeaurora.org>
SELinux has to be the default security module for 'flask.h'
to be generated and compilation error to be resolved.
Signed-off-by: Gilad Broner <gbroner@codeaurora.org>
Signed-off-by: Andrey Markovytch <andreym@codeaurora.org>