LMH lite driver allocates DMA memory for getting the
sensor list from trustzone. DMA memory is not needed for
this operation, so use dynamic memory.
CRs-Fixed: 1010120
Change-Id: Ia7ef920a0f34334e49d76efc5ba233aa58aeb273
Signed-off-by: Ram Chandrasekar <rkumbako@codeaurora.org>
Thermal core framework allows reading negative temperature and to
support that, thermal core APIs will read temperature in integer.
Inline with thermal core changes, modify the parameters to read
temperature to integer from signed long.
CRs-Fixed: 1010120
Change-Id: I975c11aa4e63e01ee3274a577b51b37c1c0f78cd
Signed-off-by: Ram Chandrasekar <rkumbako@codeaurora.org>
The permissions of /proc/iomem currently are -r--r--r--. Everyone can
see its content. As iomem contains information about the physical memory
content of the device, restrict the information only to root.
Change-Id: If0be35c3fac5274151bea87b738a48e6ec0ae891
CRs-Fixed: 786116
Signed-off-by: Biswajit Paul <biswajitpaul@codeaurora.org>
Signed-off-by: Avijit Kanti Das <avijitnsec@codeaurora.org>
In some cases modem will delay USB uplink pipe
for flow control. This will happen regardless of
tethering protocol. This change sends a QMI message
to modem to remove the delay on USB pipe in case
of USB cable disconnect.
CRs-Fixed: 1009199
Change-Id: I42cd716dcb87b814256a81418fecdff020f37d9d
Acked-by: Ady Abraham <adya@qti.qualcomm.com>
Signed-off-by: Skylar Chang <chiaweic@codeaurora.org>
Add WCN3990 slimbus slave device tree to support
bluetooth and FM audio.
Change-Id: I15a0abe365555a6695a7317e4d9cfae13a56c49e
Signed-off-by: Sungjun Park <sjpark@codeaurora.org>
Create a new file for hdmi panel related functionalities
for a cleaner approach. Move all the video, infoframe and
timing related programming to hdmi panel. Expose its
functionalities for other modules. Register the panel with
hdmi transmitter core so that it can access and program it.
Change-Id: Iff1cb13d7b42b6ecfe6fd1fc88a111875c3d6cfa
Signed-off-by: Ajay Singh Parmar <aparmar@codeaurora.org>
The DP RCGs exported by the MMSS clock controller (MMSS-CC)
can be sourced out of the DP PLL which is outside the MMSS-CC. Set up
these external clock sources to point to the DP PLL clocks.
CRs-Fixed: 1009740
Change-Id: Ia8f60ba711770c26e5b5919d2c39d7986403ece6
Signed-off-by: Chandan Uddaraju <chandanu@codeaurora.org>
Change the feature flag to compile rndis_ipa
on cobalt target with msm-4.4 kernel, also
fix the compile warnings.
Change-Id: I82d3dd00e003d8eab63ca6bcc3bb91d51f122606
Signed-off-by: Skylar Chang <chiaweic@codeaurora.org>
List all the resources needed by the MDSS DP PLL device and add the
corresponding device node for msmcobalt. The DP PLL is the source for
all the branch clocks needed to drive pixel data over the DP interface.
CRs-Fixed: 1009740
Change-Id: I1a373a7602f8dbad3fb547690a87a28aea73aadd
Signed-off-by: Chandan Uddaraju <chandanu@codeaurora.org>
Add support for new Display-port PLL clock driver to handle
different DP panel resolutions in msmcobalt. Add separate files
to support this new PHY PLL block.
CRs-Fixed: 1009740
Change-Id: Ic282c7e14fc6e23f4d044cb6a58249bdb4c8c2d8
Signed-off-by: Chandan Uddaraju <chandanu@codeaurora.org>
Set the primary display interface as the DSI device and the preferred
primary panel to be nt35597 dual-DSI (non-DSC) panel on msmcobalt CDP.
CRs-Fixed: 1000724
Change-Id: I8caa21c7b6a5f1e57cbd4c2bffeaa34e1e59d9c2
Signed-off-by: Aravind Venkateswaran <aravindh@codeaurora.org>
MSMCOBALT supports SLIMBUS_7 RX/Tx and SLIMBUS_8 Tx ports.
Add these ports to the CPU DAI list for passing to machine
driver.
Change-Id: I91306af6a2376fc76d51c62497e9723e6ec716e1
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
Support for SLIMBUS_7 and SLIMBUS_8 Rx/Tx ports added to MSM audio
drivers. Add the right devices to probe/register these ports with
kernel at device bootup.
Change-Id: Id28b3d2fc5db4ec88ddbfa20b36047804d1fbdb6
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
New sequence print functions doesn't return error on overflow.
Use the new API to check for overflow and then return error
from LMH interface driver.
CRS-FIxed: 1010120
Change-Id: I12c496f3c72398845a9039607b27112196afe38a
Signed-off-by: Ram Chandrasekar <rkumbako@codeaurora.org>
KTM has support for handling cluster with asynchronous cores within
a cluster. KTM can get the individual clock plans for the cores and
mitigate them separately. This feature is not supported in
hardware.
So remove the asynchronous cluster support from KTM.
CRs-Fixed: 1010111
Change-Id: I13348a16e2e1c11053cf5b99b921fd8ea65c7d89
Signed-off-by: Ram Chandrasekar <rkumbako@codeaurora.org>
When driver detects that there is a dynamic resolution change
mid-stream it will not activate dcvs.
CRs-Fixed: 1007339
Change-Id: Ia5e5b42598b7e32360267e42665a5ce3880aaeee
Signed-off-by: Rohit Kulkarni <rkulkarn@codeaurora.org>
In order to centralize IPA assert calls and add essential
data on assertion, replace some BUG calls in an ipa_assert wrapper.
CRs-fixed: 1006564
Change-Id: I6a9b679bb083c695908972b377e8779e2f1cca60
Signed-off-by: Amir Levy <alevy@codeaurora.org>
Incorrect voltage and temperature results are seen
during ADC reads from VADC_HC peripheral.
Fix setting the correct flag used to select the respective
peripherals scaling formula to return the correct voltage
and temperature readings for VADC_HC peripheral.
Change-Id: I6f4fe857996c8df996b6e4a0e4475a48740929fa
Signed-off-by: Siddartha Mohanadoss <smohanad@codeaurora.org>
If process_open_event is delayed and glink has migrated to new transport,
process open event will be treated as a new open event and migration will
happen on fully open channel.
If channel is fully, open migration will not be allowed as client might
already be using the channel for communication.
Change-Id: I6c1760bc19f52e7d0c1c9834a72e2304f0ae28c8
Signed-off-by: Dhoat Harpal <hdhoat@codeaurora.org>
Add programming support for the qspi_ref and qspi_ahb clocks
in the linux clocks driver.
CRs-Fixed: 1011840
Change-Id: Ic67b72b1e9341fec33bcdbde67f9e2c7e8045ec1
Signed-off-by: Deepak Katragadda <dkatraga@codeaurora.org>
Add machine driver code to support audio on MSMCOBALT based
boards with WCN3990 BT/FM chipset.
Change-Id: Ia23572f44775a04c8f8c67e9a61d6b9be8869b82
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
Add a new mixer control for volume control for SLIMBUS_8_TX AFE port
loopback.
Change-Id: Ifbf1778255edbe4901bd0860216ba1dd5a786047
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
SLIMBUS_7 and SLIMBUS_8 would be used for BT-SCO and FM use
cases when using the second Slimbus instance. Add routes
to support voice call over BT-SCO and FM playbacki and capture
with these ports.
Change-Id: I5c558ee2dbe2de20b9ac3f042ae45a9431590778
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
SLIMBUS_8 ports can be used for hostless audio playback and
capture use cases. Add Hostless Front-end DAI definitions
with Slimbus 8 ports.
Change-Id: Idc56625bb8fea263c3d530c8a9488eeb81fdd7e5
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
Add support for SLIMBUS_7 and SLIMBUS_8 Rx and Tx ports for
MSM audio drivers.
Change-Id: I839ac07a3ee1e1e778c4d1e43d0bac89f01bd21a
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
Increase the OSM LLM frequency and voltage vote hysteresis timers
to the maximum allowed value of 327675 ns. This is necessary
to ensure stable operation when LLM port is enabled as client of
OSM.
Change-Id: I6b53b5a6187f0ac0e68f4ed54c7ae3ba0b062222
CRs-Fixed: 1009097
Signed-off-by: Osvaldo Banuelos <osvaldob@codeaurora.org>
OSM clock period is 5 ns. Therefore, the various hysteresis
timers used by OSM can be fine tuned with a granularity of
5 ns. Allow specification of timers in units of nanoseconds
to prevent losing valid timer setpoints.
Change-Id: Ice93347aaf81fe41ea7862752ac0d2d4e82d838c
CRs-Fixed: 1009097
Signed-off-by: Osvaldo Banuelos <osvaldob@codeaurora.org>
Fix overwrite of updt_params allocated in heap, and stack overread
where param pointer is passed from user space.
CRs-Fixed: 989628
Change-Id: Ida8bdb7da2fcb97023dce3b6eafe4b899a51cb66
Signed-off-by: Weiyin Jiang <wjiang@codeaurora.org>
Increase the refcount of CPU clocks proportionally to the number
of available CPUs to maintain the assumption that each CPU clock
has been prepared and enabled by the time cpufreq takes over.
Change-Id: Icccb28bc7a88dc76cf4ed5710623e992ba62f19c
CRs-Fixed: 994035
Signed-off-by: Osvaldo Banuelos <osvaldob@codeaurora.org>
The original commit was reverted due to conflicts in the kernel upgrade
process. Now that the upgrade is complete we can introduce this commit
again.
Original commit:
commit 8e10bff713 ("power: move QTI charger drivers to a new
sub-directory qcom-charger")
QTI charger drivers have outgrown their home in power and deserve their
own sub-directory. Move all QTI charger drivers and their dependencies to
a new sub-directory of power called qcom-charger.
CRs-Fixed: 1001767
Change-Id: I5465a944a79f622ddf69534075b067db0fb10c95
Signed-off-by: Nicholas Troast <ntroast@codeaurora.org>
POWER_SUPPLY_PROP_CHARGING_ENABLED has been used to indicate enabling
the charge path in some drivers and enabling the input path in others.
This leads to confusion of what charging enabled really means.
POWER_SUPPLY_PROP_BATTERY_CHARGING_ENABLED was introduced to indicate
enabling the charge path, and in this case
POWER_SUPPLY_PROP_CHARGING_ENABLED is used to indicate enabling the
input path. Since these are similarly named it leads to even more
confusion.
In an attempt to fix this confusion we introduce a new power supply
property POWER_SUPPLY_PROP_INPUT_SUSPEND which indicates suspending the
input path of the power supply. POWER_SUPPLY_PROP_CHARGING_ENABLED takes
its original definition of enabling the charge path. Then
POWER_SUPPLY_PROP_BATTERY_CHARGING_ENABLED will be retired from use.
CRs-Fixed: 1005389
Change-Id: I1ca8f5748a56a9395caa8ed8ed18f70e69f0cbe8
Signed-off-by: Nicholas Troast <ntroast@codeaurora.org>
Introduce the power_supply_typec_mode enum definitions which
will allow a charger to indicate the type of USB Type-C
connection that is established. Also add additional properties
for indicating CC pin orientation, changing source/sink power
role (useful for dynamic power role swap), and a flag to allow
the charger to expect VBUS changes during USB Power Delivery
power negotiation.
CRs-Fixed: 1005389
Change-Id: Iba9b652335fba4ee4f24a17eba8abdd5c85c21bb
Signed-off-by: Jack Pham <jackp@codeaurora.org>
Signed-off-by: Nicholas Troast <ntroast@codeaurora.org>
Currently SSR framework seems to make callbacks in the order
they were registered, or based on pririties.
Due to this, APR's callback (done in its probe) may be executed
before slimbus driver's callback (only registered after children
are probed). This still works, but may take longer since codec
may try sending some disconnection commands over slimbus if APR
is notified about SSR before codec was notified by slimbus.
This failure may result in some delay in SSR handling which is
more than the KPI numbers expected for this recovery mechanism.
Priority is added to slimbus SSR notifier registration to make
sure its callback is called before APR's.
CRs-Fixed: 996871
Change-Id: Ib7f002d52310dc13b60a18972a6899ebae21ba24
Signed-off-by: Sagar Dharia <sdharia@codeaurora.org>
Currently ADSP SSR notifications to APR come much earlier
than ADSP SSR notifications to SLIMbus. This causes audio
playback resume to take more time than expected, as code in WCD
codec driver has dependency on the sequence at which SSR
notifications are received. Add a priority to the notifier
block for APR, so that the APR has lower priority compared
to SLIMbus.
CRs-fixed: 989828
Change-Id: Idb089ec8d036d441e32bc927d7294121a1d2735d
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
In SSR with recording, race condition which reduces micb_ref to -1
is seen. SSR sets micb_ref to 0, further recording widgets power
down can reduce it to -1. During power up, it is increased to 0,
micbias is not getting enabled for recording since micb_ref is 0.
To prevent this micb_ref is checked for non zero value before
decrementing it.
CRs-Fixed: 994268
Change-Id: I6ea23fdf8b119cfd178c4f5b79b9d1c01c267a82
Signed-off-by: dojha <dojha@codeaurora.org>
During SSR(subsystem restart), add a delay when ADSP state
is not yet ready. This will avoid excessive logging when
ADSP state is not ready.
CRs-Fixed: 1001242
Change-Id: I2f3d1bdb3ca1ba05c014c26bbc87879f549098d8
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
Update the Slmbus6 downlink hostless routing so it can connect
to Slimbus0 Hostess FE.
Change-Id: Iaeb3e148af57e9d484a31820993cf7e5b6466dd2
CRs-fixed: 991759
Signed-off-by: Kuirong Wang <kuirongw@codeaurora.org>
During temperature read, resource acquire can fail
if mclk is not enabled successfully. In such case,
clock and bandgap control counters are not incremented.
But resource release is still happening resulting
in counters going negative and warn_on messages.
Fix it by handling resource acquire failure case.
CRs-Fixed: 1003365
Change-Id: If2371e06866a615ca7d7dad64a5d7a17f258b3b6
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
Add check to avoid out of bound access.
Check return value of get_user api.
CRs-Fixed: 997025
Change-Id: Ibbace116ac206007fa1928555838285304737737
Signed-off-by: Ashish Jain <ashishj@codeaurora.org>
VOC_EXT_EC MUX kcontrol, which is being used for external EC
reference, returning incorrect values when requested. Update
the logic to fix this issue.
CRs-Fixed: 999158
Change-Id: If05a54ca2539ef452312548bfcaf7f3fadd1de87
Signed-off-by: Venkata Narendra Kumar Gutta <vgutta@codeaurora.org>
Use a vrail_comp factor of 25 for clients voting on mdp masters
CRs-Fixed: 1011135
Change-Id: I213bc12a089bdad75934959d0ccc8a6243f6124e
Signed-off-by: David Dai <daidavid1@codeaurora.org>
Voice calls are not working over quinary rx path. Required rx
controls are not present, hence it's not working. Fix this
by updating quinary rx controls and routing map.
CRs-Fixed: 999811
Change-Id: Id566359e381b69acfccff406c7448708701530e7
Signed-off-by: Venkata Narendra Kumar Gutta <vgutta@codeaurora.org>
USB BAM device is having 4 pipes. USB BAM global register address
space size is 0x13000, whereas each USB BAM pipe register address
space size is 0x1000. Due to insufficient register address space
mapping, there is unpaging related crash seen while trying to
access USB BAM pipe 0 related register. Fix this issue by
increasing size to 0x17000 (i.e. 0x13000 + 4 * 0x1000).
CRs-Fixed: 1011319
Change-Id: I6654d9eec5a849bcce6d812166d6696347458169
Signed-off-by: Mayank Rana <mrana@codeaurora.org>
During Compress offload session open, a private data structure
is allocated and registered as parameter for a callback to the
compressed offload driver. All parameters inside the structure
must be initialized before the structure is passed to ASM driver.
This private data structure is sent back as param to the callback
function registered with ASM. The initialization is needed to avoid
NULL pointer dereference inside the callback function, in case ADSP
SSR is triggered right after registering the callback with ASM and
before rest of the initialization of the private data is complete.
CRs-fixed: 989822
Change-Id: I8a64539a6a64fb8c75d06f933a735c70049bce7b
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
Mute observed in WFD playback during ADSP SSR. This is due to
playback session isn't being restarted post SSR. Fix this by
listening to reset events and propagate the appropriate error
back to userspace in case of SSR.
CRs-Fixed: 986757
Change-Id: I4c2fdf70e518310157d81d527afff4436dd42140
Signed-off-by: Venkata Narendra Kumar Gutta <vgutta@codeaurora.org>
Set token value with port index and copp id so that
correct wait queue handle can be deduced in the
callback of adm_set_stereo_to_custom_stereo command.
Change-Id: Ica4c1442c1143f46de2baa6eaf1890ad0cb4b742
Signed-off-by: Shiv Maliyappanahalli <smaliyap@codeaurora.org>
Add soundwire API to control slave device data path
enable or disable. This gives slave device drivers
more flexibility for data path control during device
path enablement.
CRs-fixed: 996586
Change-Id: Ic0ab015098035418458a5ba7c2ffad9df20f933c
Signed-off-by: Phani Kumar Uppalapati <phaniu@codeaurora.org>