The return variable is initialized if there is an error and is
left uninitialized otherwise. There is a possibility of returning
garbage.
CRs-Fixed: 980968
Change-Id: I2a21ef7934472ae2fd59d6277df4b3e9b401b489
Signed-off-by: Yeleswarapu Nagaradhesh <nagaradh@codeaurora.org>
This reverts commit 43c0767e17 ("of/platform: Move platform
devices under /sys/devices/platform"). Userspace code that
expects to find devices under a fixed /sys/devices/... path are
affected by moving platform devices under /sys/devices/platform.
Change-Id: I6a108c46c1b2e3985797bb86a3ed84a29ab286a8
Signed-off-by: Kaushal Kumar <kaushalk@codeaurora.org>
This change adds logic to prevent invalid access of qmi ctx
during SSR clean up using mutex.
Change-Id: I689deaf093909a951a9e5847241ee3938fea240b
Acked-by: Chaitanya Pratapa <cpratapa@qti.qualcomm.com>
Acked-by: David Arinzon <darinzon@qti.qualcomm.com>
Signed-off-by: Sivan Reinstein <sivanr@codeaurora.org>
Signed-off-by: Ravinder Konka <rkonka@codeaurora.org>
Report the input current limited status via the power supply in
parallel mode in order to better optimize for HVDCP usecases.
Change-Id: Ibd3865828ccbfa44b36839f5d11e7a60b7ada77d
Signed-off-by: Ashay Jaiswal <ashayj@codeaurora.org>
Apply voltage adjustments for required voltage corners based on
different values of selected miscellaneous fuse bits. Apply the
adjustments to both open-loop voltages and closed-loop target
quotients.
CRs-Fixed: 982984
Change-Id: Ic45949afc8445d35c245434a7f51e4859a5978ad
Signed-off-by: Tirupathi Reddy <tirupath@codeaurora.org>
The LP1 and LP2 flags must be swapped to be in accordance
with the old HAL mapping used by MDP3 driver.
Change-Id: Id4b0b41d102f9aef2836901b2bea5e961ec0962b
Signed-off-by: Sravanthi Kollukuduru <skolluku@codeaurora.org>
In DAPM, when booting up widgets connect variable
is sometimes initialized with value 1 even though
expected to be 0. This is due to val not initialized
locally in API dapm_set_mixer_path_status and can
result in using garbage value.
CRs-Fixed: 982805
Change-Id: I172558f64c19750c461befda3aa16ca6480ab507
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
Use the cxo_clk_src_ao resource to source the HMSS CPR RCG. In
addition, remove it's vote on the CX rail since CX is guaranteed
to be at least SVS2 as long as even one CPU is online.
CRs-Fixed: 983870
Change-Id: I5a4d37310e56235a590e8a93dc8a33d6c3e46e4d
Signed-off-by: Deepak Katragadda <dkatraga@codeaurora.org>
USB 5V VBUS can be switched independently for the two USB
instances on the CDP_AU board. Add the PM8994 GPIO/MPP
configurations and expose them as usb_vbus_vreg,
usb_otg_switch and usb2_otg_switch regulators that can be
controlled by the USB controller device instances.
Also fix up the &usb3 node. Due to commit c51ea2bbbce87
("ARM: dts: msm: Add GIC ITS extensions for 8996") changing
the size of address-cells for the &intc node, the interrupt-map
property needs to be updated to the new format. Also update
the correct IRQ numbers and add the missing ss_phy_irq to
sync up with the msm8996 SOC DT definition. Finally, remove
the unused vdda supply entries as well.
CRs-fixed: 971957
Change-Id: Id53f0a54e16b194bc12e57fac3e52efc43ebdc6c
Signed-off-by: Jack Pham <jackp@codeaurora.org>
The mmss_mdss_byte0/1_intf_clk clocks are needed by the display
driver. Add support to program them in the clock driver.
CRs-Fixed: 981902
Change-Id: I17b1ecaec9c98261faa49c6f088c4802a716ecf7
Signed-off-by: Deepak Katragadda <dkatraga@codeaurora.org>
Turn off watchdog on Virtio on MSMCOBALT.
CRs-Fixed: 983131
Change-Id: I2684d52b95cb446013d2620de252b6abe3e1e5bd
Signed-off-by: Runmin Wang <runminw@codeaurora.org>
The active context tracker that we bolted on the side of the
dispatcher was designed mainly to see if there was 1 OR more than 1
active context, not much more than that. Since it is apparent that
we'll need to track up to 4 contexts and possibly more later the
algorithm needs to change.
The new algorithm puts all active contexts on a linked list - every
time a context is used it is popped from the list and put on the
tip with an updated time. To count the number of active contexts
walk the list until you get a context with an active time older than
you are looking for. You also can do other magic on the context,
like see if it matches up with a given command queue.
Change-Id: Ic0dedbad6be9fd1925121ee54e0000c42b089f44
Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org>
Signed-off-by: Prakash Kamliya <pkamliya@codeaurora.org>
Currently MPM pin for DP line state change is not mapped to irq.
Only MPM for DM line state chagne is mapped to hs_phy irq. But this
results in delayed device detection in VDDmin when HS/FS devices
are connected in host mode. Hence enable power event irq during
host bus suspend so that MPM pin for DP line state can be also
mapped for early detection of HS/FS devices during VDDmin.
CRs-Fixed: 972212
Change-Id: I71d7c3c374a23b51a0489cf44410d76d5734d009
Signed-off-by: Vijayavardhan Vennapusa <vvreddy@codeaurora.org>
After commit dbe80b7cc96a1f3f23246552fbd2352f334fa857 ("ARM: dts: msm:
remove gpio output settings in dsi pinctrl") driver is no longer
defining in the pinctrl the gpios as output high configuration;
so driver now has to explicitly configure gpio output direction.
This change add the settings in the driver to configure the gpio
as output pin, fixing panel issues when booting-up with
continuous splash disabled.
Change-Id: I1ac3c5dd07cff4a30cce9de3c340f071dd84d49a
Signed-off-by: Ingrid Gallardo <ingridg@codeaurora.org>
Fixes EP configuration for DPL resume sequence.
Sets correct interrupter number for DPL composition
and also checks for NULL on notify EP in the
resume path.
CRs-Fixed: 983160
Change-Id: I7e9bf0aa839e63d8cfe801d3b81dd5f48a315575
Signed-off-by: Devdutt Patnaik <dpatnaik@codeaurora.org>
Add CTI devices for msmcobalt target. These devices can be used to
send cross triggers between different components
Change-Id: Ia5902c62b699c5f373f567dd18cbe38f10a275a3
Signed-off-by: Shashank Mittal <mittals@codeaurora.org>
Current code sets default CPU id as of CPU0. This causes a failure in
case where device tree declares a CoreSight node that is associated with
a CPU that's not available on that target. This causes complete failure of
the system.
Set default CPU id to -1 to avoid this problem.
Change-Id: I77e5f734666a5f806013d685e89902ce5983cf49
Signed-off-by: Shashank Mittal <mittals@codeaurora.org>
Update the number of frame rates supported for dynamic refresh
feature from 10 to 20. This is needed to support all the fps
values requested by display HAL between minimum fps and maxiumum
fps based on the requirement.
Change-Id: Ib7487ad17261ac8c4d6929787899161061e71078
Signed-off-by: Padmanabhan Komanduru <pkomandu@codeaurora.org>
When ever notification of IRQ affinity changes, call
cancel_work_sync from irq_set_affinity_notifier to cancel
all pending works to avoid work list corruption.
Change-Id: I1f093bcc43be8c6696bad29250e4926cbc6c4029
Signed-off-by: Prasad Sodagudi <psodagud@codeaurora.org>
Synaptics reference driver V2.6 is being cleaned up to enable touch
controller S332U. Add Kconfig and Makefile changes to enable Synaptics dsx
V2.6 driver's compilation.
CRs-Fixed: 943896
Change-Id: I7e79e9ee321b7a7c90d27f065281dc73cee65391
Signed-off-by: Mao Li <maol@codeaurora.org>
When headphone is removed while 3 second polling is still in progress,
mbhc hs comparator result will be read as "0" and this causes reporting
a fake headset insert event to user-space followed by headphone removal.
Avoid sending this fake headset insert event to user-space by checking
for the microphone clamp bit from codec mbhc hardware.
CRs-fixed: 941089
Change-Id: I96d96dca92a6c99bbb25ab70a2706e730c28818b
Signed-off-by: Phani Kumar Uppalapati <phaniu@codeaurora.org>
In case of any codec access failure, return -EPROBE_DEFER
so that slimbus driver can probe the codec again
to toggle codec reset and retry codec access.
CRs-fixed: 969497
Change-Id: I570e7357a6d7810c495f56bbb626b8e823892837
Signed-off-by: Phani Kumar Uppalapati <phaniu@codeaurora.org>
This change adds some routing missing plus few other fixes needed
when MI2S interfaces are used.
CRs-fixed: 909961
Change-Id: Ic1e234c955a6162d67fd97ac7647ec810ede204c
Signed-off-by: Roberto Granados Dorado <robertog@codeaurora.org>
POWER_SUPPLY_TYPE_USB_DCP type is returned in read_usb_type() if no
charger is connected, which might cause APSD to unnecessarily rerun.
To fix it, POWER_SUPPLY_TYPE_UNKNOWN should be returned instead.
A bug is also fixed by returning right after IDEV_STS register
read error in this function .
CRs-fixed: 963745
Change-Id: Ia399e05fe8d0ad13c2f1f272c6737e8798177174
Signed-off-by: Harry Yang <harryy@codeaurora.org>
Use proper size for dma memory free call API while saving lmh sensors
list in lmh hardware driver otherwise it leads to memory leak or
unexpected crash if scm_call error path is executed.
CRs-Fixed: 982320
Change-Id: I31ac79585c8899b44ece745676d9af79fe8bca78
Signed-off-by: Manaf Meethalavalappu Pallikunhi <manafm@codeaurora.org>
For kernel clients, some of the flags are maintained which is not required
as those are specific to userspace clients. So remove the code which is
not required.
Change-Id: If7fb51cc17e9a8c0f3c2632e9c42d84489bda4f6
Signed-off-by: Mallikarjuna Reddy Amireddy <mamire@codeaurora.org>
A small fraction of MSM8996v3 parts with CPR revision 0 to 5 may
not operate properly at very low VDD_APCC voltages. Therefore
increase the VDD_APCC CPR floor voltage for these parts to 625 mV
in order to guarantee stable operation.
Also change the maximum CPR floor to ceiling voltage range from
80 mV to 50 mV for all MinSVS and LowSVS corners in order to
ensure stable operation.
Change-Id: I71c32aac8ef7d54dfcf48098aaf5d5909762df15
CRs-Fixed: 981898
Signed-off-by: David Collins <collinsd@codeaurora.org>
Add the qcom,pwm-sel and qcom,enable-gp-driver properties to
the MISC device driver to enable configuring the PWM source.
Currently this will be supported only for pmdcalifornium.
CRs-Fixed: 972331
Change-Id: I320edac22b20d748a531a41eaff06162092cfd3d
Signed-off-by: Devesh Jhunjhunwala <deveshj@codeaurora.org>
Add documentation for KGSL_CMDBATCH_PROFILING_KTIME to make it
clear that KGSL_CMDBATCH_PROFILING must also be set.
CRs-Fixed: 977455
Change-Id: I44f9dbc006450fbe226b642ee66b8d49dd1108cc
Signed-off-by: Jonathan Wicks <jwicks@codeaurora.org>
As part of dynamic refresh sequence, we program PLL_UPPER_ADDR2 register to
0x003FFE00 instead of 0x001FFE00. This causes a register write to
DSIPHY_PLL_KVCO_COUNT1 to 0x1 during the dynamic refresh operation whereas
the register write is supposed to happen for DSIPHY_CMN_PLL_CNTRL register.
Update the write value to DYNAMIC_REFRESH_PLL_UPPER_ADDR2 to take care
of this.
Change-Id: I991920d5a45e79670a4a033c8a83bef6c7f3136b
Signed-off-by: Padmanabhan Komanduru <pkomandu@codeaurora.org>
Due to chipset max capabilities considered in buffer population,
secure scenarios are failing due to limited CMA size.
Remove read-only flags for profile and level clusters to allow
omx component set.
CRs-Fixed: 973470
Change-Id: I28c8318bd356ebb01258c1ec946215a838f81827
Signed-off-by: Srinu Gorle <sgorle@codeaurora.org>
This change adds support to read HPD state from sysfs node,
which will be helpful in automated test cases where multiple
HPD operations are performed on HDMI TV.
Change-Id: I39d19447c01d11a54a8e54c661b2dd177310c205
Signed-off-by: Sandeep Panda <spanda@codeaurora.org>
In simulator panel SW-TE approach, we rely on the sync config
height, init, start_pos and read ptr TE parameters. Set start_pos,
init and read ptr with respect to panel yres, as it is done in
the default settings when it is used with an actual panel.
Setting these parameters with respect to 0 causes fps drops.
Change-Id: I9acf4d1558767e7789a5e37dc2444f947d11eb21
Signed-off-by: Veera Sundaram Sankaran <veeras@codeaurora.org>
Add rmts shared memory node for msmcobalt to support EFS
on the modem.
CRs-Fixed: 980874
Change-Id: Ic869dd739f7efd880d574bcc1f730d9d04d9c456
Signed-off-by: Nikhilesh Reddy <reddyn@codeaurora.org>
This patch checks for Null Pointer dereference before destroying the
diag mempools.
CRs-Fixed: 980428
Change-Id: I0e8fc8aa82ad26263bd9d47cbdd22de212efe489
Signed-off-by: Manoj Prabhu B <bmanoj@codeaurora.org>
The memory color values for the left and right hold of foliage were
incorrectly returning the values for sky. This change fixes the foliage
hold values that will be returned during read.
CRs-Fixed: 968059
Change-Id: Ib5c2ae9b8fbe8817d730104ace88f20f04b59d17
Signed-off-by: Benet Clark <benetc@codeaurora.org>
This change add a sysfs node to enable the misr crc generation
in batch mode. Once this is enabled, driver will collect the
crc numbers during each of the interfaces interrupt,
vsync interrupt for video mode panels and ping pong done
for cmd mode panels.
To enable/disable the crc generation, respectively:
echo 1 > /sys/class/graphics/fb0/msm_misr_en
echo 0 > /sys/class/graphics/fb0/msm_misr_en
To collect the last crc generated:
cat /sys/class/graphics/fb0/msm_misr_en
To enable the ftrace to collect the crc for all frames:
echo 1 > <debugfs>/tracing/events/mdss/mdp_misr_crc/enable
CRs-Fixed: 964076
Change-Id: I47fb47b772aef097bc9af3b58a6c79565bcdc872
Signed-off-by: Ingrid Gallardo <ingridg@codeaurora.org>
Set the correct offsets of the MISR for command mode
interfaces in 8996.
CRs-Fixed: 964076
Change-Id: I90c7fa1ff144ae547cc0537421211a73051f1036
Signed-off-by: Ingrid Gallardo <ingridg@codeaurora.org>
Cannot switch from memory device logging to USB Mode after
the first switch because the first MD state is stored.
This fix resets the MD state by closing the session when
switching to USB Mode from MD mode.
Change-Id: I9addf0c7d8f1c058485349e196c1dcaa54b92f3a
CRs-Fixed: 972027
Signed-off-by: Chris Lew <clew@codeaurora.org>
Correct the size of the register block.
CRs-Fixed: 980025
Change-Id: I6a672bf4f46f6ba453e4382c41cefd1630c0ac1e
Signed-off-by: Patrick Daly <pdaly@codeaurora.org>
Increase the scm retry timeout to 2 seconds and add a warning
message if the call takes longer than 1 second.
CRs-Fixed: 975433
Change-Id: I7719df41e491c9a8c80b8547de14bc8c71bf7c8d
Signed-off-by: Runmin Wang <runminw@codeaurora.org>
Initialize tdm group reference count on tdm group q6 probe
instead of tdm per dai probe to avoid duplicated init calls.
CRs-fixed: 975767
Change-Id: I88bc791fc2bfbb60f1cf6b2faeb6de0c865539c0
Signed-off-by: Derek Chen <chenche@codeaurora.org>
Add mixer controls to adjust wcd9335 codec lineout PA
volume adjustment. This gives flexibility for user
to modify volume based on use-case.
CRs-fixed: 969512
Change-Id: I562f17363d7d38caece358a50d1e3f654d87491f
Signed-off-by: Phani Kumar Uppalapati <phaniu@codeaurora.org>
Initialize PMCOBALT regulators SMPS 7 and LDO 5 to use HW_EN0 pin
control to force high power mode. Whenever HW_EN0 is driven high these
regulators will be forced into high power mode.
HW_EN0 is driven high whenever WLAN is transmitting or receiving, thereby
reducing power when it is not active.
Initialize PMCOBALT regulators SMPS 3 and SMPS 5 to use HW_EN2 pin
control to force high power mode. Whenever HW_EN2 is driven high these
regulators will be forced into high power mode.
Add pin control regulator devices for PMCOBALT regulators LDO 7, LDO
17, and LDO 25. When any of these pin control regulators are enabled by
software their output will be physically enabled whenever HW_EN2 is driven
high. When disabled HW_EN2 is ignored.
HW_EN2 is driven high whenever BT is transmitting or receiving, thereby
reducing power when it is not active.
CRs-Fixed: 971169
Change-Id: I819299fefde72400a18fb8503aedd1a1f32bfe7b
Signed-off-by: Nicholas Troast <ntroast@codeaurora.org>
ARB occurs upon DCP removal due to bit INPUT_MISSING_POLLER_EN_BIT
cleared in kernel charger driver. Enable input missing poller bit
to avoid ARB.
CRs-Fixed: 965458
Change-Id: I3597327d8607b61582d124318e06da701758e34b
Signed-off-by: Harry Yang <harryy@codeaurora.org>