Commit graph

570198 commits

Author SHA1 Message Date
Syed Rameez Mustafa
c34b0b85aa sched: Optimize wakeup placement logic when need_idle is set
Try and find the min cstate CPU within the little cluster when a
task fits there. If there is no idle CPU return the least busy
CPU. Also Add a prev CPU bias when C-states or load is the same.

CRs-fixed: 1006303
Change-Id: I577cc70a59f2b0c5309c87b54e106211f96e04a0
Signed-off-by: Syed Rameez Mustafa <rameezmustafa@codeaurora.org>
2016-04-22 15:05:01 -07:00
Prakash Kamliya
3edc12e8ea msm: kgsl: Update ucode workarounds for A5xx GPUs
Update ucode workarounds for A5xx GPUs based on new
microcode and hardware changes.

CRs-Fixed: 1000396
Change-Id: I87a1ba9bfc441cad2ed6a6959d07af1cc1e2c7bc
Signed-off-by: Prakash Kamliya <pkamliya@codeaurora.org>
Signed-off-by: Oleg Perelet <operelet@codeaurora.org>
2016-04-22 15:04:52 -07:00
Hemant Kumar
bbb0b3be44 usb: gadget: f_gsi: Add free_func call back
Without free_func call back config causes NULL pointer
dereference.

CRs-Fixed: 1003784
Change-Id: Idb7717315da20fa3331303136d7ba1d05696f063
Signed-off-by: Hemant Kumar <hemantk@codeaurora.org>
2016-04-22 15:04:40 -07:00
Hemant Kumar
7ab51c2789 usb: gadget: f_gsi: Fix bug in handling control transfer
Driver is overriding the ep0 request context with gsi driver
context even if it does not intend to handle the setup completion.
This is causing flood of warnings when composite_setup_complete()
is type casting the function driver context as cdev and failing to
match ep0 request pointer with cdev->req. Hence only override
context when driver is overriding the complete call back.

CRs-Fixed: 1003784
Change-Id: I176671ae09f17d920643eeeec8262a6f97856712
Signed-off-by: Hemant Kumar <hemantk@codeaurora.org>
2016-04-22 15:04:29 -07:00
Hemant Kumar
99e000989b usb: gadget: f_gsi: Allocate dma memory using gadget device's parent device
Use "gadget->dev.parent" instead of "&gadget->dev" in the first argument
of dma_zalloc_coherent() because the parent has a udc controller's device
pointer. Otherwise, iommu functions are not called in ARM environment and
allocation is failing.

CRs-Fixed: 1003784
Change-Id: I2ea75b533f857189856840e437a96891eea5699c
Signed-off-by: Hemant Kumar <hemantk@codeaurora.org>
2016-04-22 15:04:18 -07:00
Hemant Kumar
599b6b32a0 usb: gadget: f_gsi: Fix bug in accessing evt queue lock
In case gsi_update_function_bind_params() returns failure
before initializing spin lock for event queue, gsi_bind()
continues further by calling post_event() which acquires
the uninitialized spin lock causing BUG. Hence check for
return value of gsi_update_function_bind_params() before
calling post_event().

CRs-Fixed: 1003784
Change-Id: I0fcad2467d15f311feecf3b9cee9209f7453485c
Signed-off-by: Hemant Kumar <hemantk@codeaurora.org>
2016-04-22 15:04:06 -07:00
Devdutt Patnaik
a431c4747f usb: dwc3: Allocate fixed h/w eps for GSI endpoints
Adds support to allocate specific hardware EPs to
GSI enabled endpoints. Creates EP list with names
"gsi-epin" for IN and "gsi-epout" for OUT EPs that
are intended for use by the GSI function driver.
The EPs are reserved from the end of the EP list.

CRs-Fixed: 1003784
Change-Id: I70ebce8c2717baaea38f7b6235976d8a522eb9fd
Signed-off-by: Devdutt Patnaik <dpatnaik@codeaurora.org>
2016-04-22 15:03:56 -07:00
Hemant Kumar
5488a16eb9 ARM: dts: msm: Set number of GSI event buffer for msmcobalt
This allows configuration of event buffers for GSI based
hardware accelerated endpoints.

Change-Id: If9ae84c0de214bcb5057d14a6960b6fb528c6c14
CRs-Fixed: 1003784
Signed-off-by: Hemant Kumar <hemantk@codeaurora.org>
2016-04-22 15:03:44 -07:00
Hemant Kumar
b279a34274 usb: dwc3: Add support for GSI event buffer configuration
Add additional event buffers for GSI based hardware accelerated
endpoints and its related configuration.

CRs-Fixed: 1003784
Change-Id: Ibedf73690040b8bd872f5621835680a66c22e265
Signed-off-by: Hemant Kumar <hemantk@codeaurora.org>
2016-04-22 15:03:29 -07:00
Gidon Studinski
6a4f3ec86c msm: ipa3: enable smart prefetch control for xDCI
Enable smart prefetch control for xDCI channels.
This is done by configuring the channel scratch in GSI.

Change-Id: I9a301da3c5426649b40069103d545e50bc75aad2
CRs-Fixed: 1004467
Signed-off-by: Gidon Studinski <gidons@codeaurora.org>
2016-04-22 15:03:18 -07:00
Gidon Studinski
b391ac1b48 msm: ipa3: enable smart prefetch control for MHI
Enable smart prefetch control for MHI channels.
This is done by configuring the channel scratch in GSI.

Change-Id: Icff18699ce96e224d6f58b8aadce006f3d5210ee
CRs-Fixed: 1004468
Signed-off-by: Gidon Studinski <gidons@codeaurora.org>
2016-04-22 15:03:05 -07:00
Ashwini Rao
752fcde3d8 ARM: dts: msm: Add jpeg, FD and CPP HW dtsi changes for msmcobalt
Add jpeg, FD and CPP HW dtsi nodes for jpeg encoder, jpeg DMA,
face detection and CPP on msmcobalt.

CRs-Fixed: 1001324
Change-Id: Ia62486e070310c3dccc0dc84490e5a9147ba8a56
Signed-off-by: Ashwini Rao <ashwinik@codeaurora.org>
2016-04-22 15:02:40 -07:00
Hardik Kantilal Patel
4621d9062c ARM: dts: msm: Add icnss node for msmcobalt
Add Adrestea base memory address and Copy Engine interrupt
mapping entry.

CRs-Fixed: 999575
Change-Id: Iab3d4aceeafc28b1df73fa9570405c6f21535f29
Signed-off-by: Hardik Kantilal Patel <hkpatel@codeaurora.org>
2016-04-22 15:02:30 -07:00
Stephen Oglesby
634f85a4ab ASoC: msm: qdsp6v2: Limit codec register config packet size
APR packet size is now capped at 512 bytes. The codec register
config data is 740 bytes. We now break up this data into multiple
packets no larger than the defined maximum.

CRs-fixed: 974874
Change-Id: I2bd3cb01ff389ffd1d319239019e11d35d8c16b6
Signed-off-by: Stephen Oglesby <soglesby@codeaurora.org>
2016-04-22 15:02:18 -07:00
Mohit Aggarwal
de210aad0f defconfig: arm64: msm: Enable QPNP RTC config flag
RTC driver is responsible for reading RTC value
and also used for reading/setting Alarm value.
This patch enables QPNP RTC config.

Change-Id: Ibc2aee233e657ba73b42f41e9b20859e818d9e1d
Signed-off-by: Mohit Aggarwal <maggarwa@codeaurora.org>
2016-04-22 15:02:08 -07:00
Shiv Maliyappanahalli
52ba772633 soc: pcm: add arch_setup_dma_ops call
Make sure that DMA ops are initialized before attempting to allocate
the DMA substream buffer.

Change-Id: I03bcb4ac7ea415c00ce3047b844455f5c6546400
Signed-off-by: Shiv Maliyappanahalli <smaliyap@codeaurora.org>
2016-04-22 15:01:57 -07:00
Jack Pham
2d242b7ef9 usb: dwc3: msm: Move extcon registration later in probe
It is possible that the extcon notifier may be triggered
soon after it is registered, but before the mdwc->dwc3
has been populated. This leads to a NULL pointer dereference
in vbus_notifier. Fix this by moving the extcon_register()
call later in the probe until when the the driver would be
ready to handle an immediate notification.

CRs-Fixed: 1003908
Change-Id: I403da246f18c25a77fa7f66e152cbcdca8c00b16
Signed-off-by: Jack Pham <jackp@codeaurora.org>
2016-04-22 15:01:46 -07:00
Yuanyuan Liu
e1ed71b374 cnss: Fix compilation error of missing CONFIG_CNSS_SECURE_FW
Add #ifdef CONFIG_CNSS_SECURE_FW for cnss_get_fw_ptr and
cnss_get_sha_hash.

Change-Id: I884b4ab3d552b12dd83f852be565a5dc4e69e21a
CRs-Fixed: 971688
Signed-off-by: Yuanyuan Liu <yuanliu@codeaurora.org>
2016-04-22 15:01:34 -07:00
Skylar Chang
a5e4baeeeb msm: ipa3: set GPI channels to DB mode
In order to enable prefetch control in GSI,
channels needs to be configured to doorbell mode.

CRs-Fixed: 1000819
Change-Id: I4847982f48b09de1690bb474db9a60e018e0c0d6
Acked-by: Ady Abraham <adya@qti.qualcomm.com>
Signed-off-by: Skylar Chang <chiaweic@codeaurora.org>
2016-04-22 15:01:21 -07:00
Mayank Rana
362a9cd138 USB: f_fs: Use HS and SS descriptors without checking gadget speed
User space function driver could always provide descriptors for all
speeds irrespective of USB speed supported with USB gadget. If USB
gadget is not high/super speed capable, f_fs driver doesn't parse
HS or SS descriptors which results into OS descriptors processing
fail due to checking against wrong offset within received descriptor
buffer. Fix this issue by always processing HS and SS descriptors
without checking USB gadget speed.

CRs-Fixed: 1003565
Change-Id: Icb6537271ce55e44f5fc3e1ef28dd4d6810b681f
Signed-off-by: Mayank Rana <mrana@codeaurora.org>
2016-04-22 15:01:13 -07:00
Aravind Venkateswaran
ed7b9f5828 msm: mdss: add support for configuring DSI PHY v3
Add the initialization and shutdown programming sequence for the DSI PHY
v3 which is used on msmcobalt. This includes configuring the phy lane
timings, strength control, and regulator settings.

CRs-Fixed: 1000724
Change-Id: I6a8d45ef71316b5a935a711a5b0a48c055c1c392
Signed-off-by: Aravind Venkateswaran <aravindh@codeaurora.org>
2016-04-22 15:01:01 -07:00
Aravind Venkateswaran
2df9ce47f6 msm: mdss: add support dsi phy v3 timing used on msmcobalt
Add PHY timing calculation support for v3 PHY used on msmcobalt.
This needed to program the DSI PHY to drive the link at a specific
link rate based on the DSI panel configuration.

CRs-Fixed: 1000724
Change-Id: I180af3544c111cb9f491ea9fb77638beece8299c
Signed-off-by: Aravind Venkateswaran <aravindh@codeaurora.org>
2016-04-22 15:00:49 -07:00
Aravind Venkateswaran
af48722765 msm: mdss: refactor dsi phy timing calculations
Refactor the DSI PHY timing calculations for v2 PHY. This will make things
easier when support has to be added for new revisions.

CRs-Fixed: 1000724
Change-Id: Icd99a3b29feddc64e42a2b4a18987579b7f52e77
Signed-off-by: Aravind Venkateswaran <aravindh@codeaurora.org>
2016-04-22 15:00:37 -07:00
Aravind Venkateswaran
37b3e8da8b msm: mdss: add support for dsi byte interface clock
DSI controller version 2.0 and above require configuring an additional
link clock called the byte interface clock which is used to drive all
high-speed PPI signals. Add support to configure this clock.

CRs-Fixed: 1000724
Change-Id: I907823b21ad2c6152899233fc52f38d17bcc5ed1
Signed-off-by: Aravind Venkateswaran <aravindh@codeaurora.org>
2016-04-22 15:00:27 -07:00
Padmanabhan Komanduru
d5faefb415 msm: mdss: refactor support for controlling LCD mode selection GPIO
For certain board configurations, the enable port on display
connector card needs to be controlled via LCD mode selection
GPIO. For example, for DSC/single DSI mode, the GPIO needs to
be driven high and for non-DSC/split DSI mode, the GPIO
needs to be driven low. Add support for this.

CRs-Fixed: 1000724
Change-Id: I3546fc2b5dacd77e9d2cd2ea843481dc34bfef54
Signed-off-by: Padmanabhan Komanduru <pkomandu@codeaurora.org>
Signed-off-by: Aravind Venkateswaran <aravindh@codeaurora.org>
2016-04-22 15:00:15 -07:00
Aravind Venkateswaran
7dcf51415c msm: mdss: modify DSI phy init sequence for split-DSI config
For split-DSI hardware configuration, both the DSI controller clocks are
sourced from a single PLL (clock-master). In such cases, it is important
to initialize both DSI0 PHY and DSI1 PHY prior to enabling the PLL.
This is due to the fact that for certain HW versions, PLL programming
for the clock-master may require configure some PLL registers on the
clock-slave. If the PHY init sequence for the clock-slave is called
after PLL is programmed, it could reset those PLL registers leading to
unexpected behavior. Fix this by ensuring that PHY init sequence is done
for both controllers at the same time for split display usecases.

CRs-Fixed: 1000724
Change-Id: I09fb8097d31cd0390cea5c32bb7aabceeff2c37e
Signed-off-by: Aravind Venkateswaran <aravindh@codeaurora.org>
2016-04-22 15:00:04 -07:00
Hemant Kumar
de2f55c7c0 usb: gadget: f_cdev: Fix recursive spin lock bug
Since driver context f_cdev is not freed until the driver
is unloaded, port_usb remains available to be accessed for
driver operations. Hence there is no need to protect port_usb
using spin lock. Hence remove un-needed spin lock/unlock from
some of the APIs which prevents recursive spin lock. Also, make
sure char device is destroyed before f_cdev context is freed up.

Change-Id: Ib91f23c070065185da72387300304f2690d5a8b1
Signed-off-by: Hemant Kumar <hemantk@codeaurora.org>
2016-04-22 14:59:50 -07:00
Mayank Rana
4579ab018e usb: gadget: composite: Set default value of bcdUSB as 0x0200
When l1_supported is false and USB gadget max speed is high speed
only, composite framework is not updating bcdUSB as 0x0200 which
results into bcdUSB set as 0x00 used as part of device descriptors.
This is against USB specification and also USB host may behave
differently. Fix this issue by setting default value of bcdUSB as
0x0200.

CRs-Fixed: 1006330
Change-Id: I8330f0609540d97f5bca78c42ed193537f497a73
Signed-off-by: Mayank Rana <mrana@codeaurora.org>
2016-04-22 14:59:39 -07:00
Sudheer Papothi
3a50f7f3bb ASoC: wsa881x: Add pinctrl support for shutdown gpio
wsa881x codec shutdown gpio is connected to msmcobalt and
control of this gpio happens through pinctrl. Add support
in codec driver to enable/disable gpio using pinctrl.

Change-Id: I9d627bf40f0e6be5d085eafc5e7211366e795c24
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
2016-04-22 14:59:28 -07:00
Sudheer Papothi
d00e0e6dbc defconfig: Enable msm codec pinctrl driver on msmcobalt
msm codec pinctrl driver is needed to handle codec reset
gpios from msmcobalt. Change enables msm codec pinctrl
driver.

Change-Id: I37ced30d9b6062ccd7de3342a9ba5b61d3d8a9d6
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
2016-04-22 14:59:16 -07:00
Sudheer Papothi
c22099b3c0 drivers: mfd: Move codec reset gpio config to early boot
WCD and WSA codecs uses MSM gpios that are accessed through pinctrl
mechanism. Codec reset gpios need to be configured before master
controller is initialized otherwise codec cannot be enumerated
on the bus. Add a new platform device driver to update reset gpio
configuration to valid state before bus initialization.

Change-Id: I1e36f4a85334704652c6b50950f50b90224a472e
Signed-off-by: Sudheer Papothi <spapothi@codeaurora.org>
2016-04-22 14:59:05 -07:00
Puja Gupta
5fa0810710 soc: qcom: Check for exact value instead of non-zero
SP-PBL could be writing other values to err_status_spare2 register and
hence check for exact value to conclude its wdog_bite.

CRs-Fixed: 1005034
Change-Id: Iaef99256f86c2e6508554f2d144d1514f10e6049
Signed-off-by: Puja Gupta <pujag@codeaurora.org>
2016-04-22 14:58:54 -07:00
Josh Kirsch
1f2cb1a4a4 drivers: soc: Add intent notification callback for APR Glink
APR is required not to send any packet until the far end queues
at least one intent. Add the wait during client registration time.

Change-Id: Ie29ddda4527ae7a70afff2c595d6e3c76500a8af
Signed-off-by: Deven Patel <cdevenp@codeaurora.org>
Signed-off-by: Josh Kirsch <jkirsch@codeaurora.org>
2016-04-22 14:58:45 -07:00
Shashank Mittal
82496f5cb3 coresight-qpdi: add support to skip LDO configuration
On few devices QPDI's LDOs are configured by some other component.
This change adds support to skip LDO configuration on such devices.

Change-Id: I84c8b4a5a0d6155a39e43e0503961f76e2d8a615
Signed-off-by: Shashank Mittal <mittals@codeaurora.org>
2016-04-22 14:58:36 -07:00
Shashank Mittal
9e6e3bba5a coresight: add HW event driver support in upstream implementation
Add HW event driver in upstream implementation of Coresight driver.
This change copies coresight-hwevent.c file from drivers/coresight
(commit f9b3004b242c ("msm: pcie: enable/disable PCIe AER from
debugfs"))
to driver/hwtracing/coresight directory.

Change-Id: I2d75108bae975107ee5c13fa5dfb5846185fbd3d
Signed-off-by: Shashank Mittal <mittals@codeaurora.org>
2016-04-22 14:58:25 -07:00
Shashank Mittal
46c271e86b coresight: add qpdi driver support in upstream implementation
Add qpdi driver in upstream implementation of Coresight driver.
This change copies coresight-qpdi.c file from drivers/coresight
(commit f9b3004b242c ("msm: pcie: enable/disable PCIe AER from
debugfs"))
to driver/hwtracing/coresight directory.

Change-Id: I8f29f386a31aec1a10a1398e0753a3b4355b3449
Signed-off-by: Shashank Mittal <mittals@codeaurora.org>
2016-04-22 14:58:16 -07:00
Shashank Mittal
8185b206af coresight-tmc: add support to set default sink
Add support to set default sink at probe time.

Change-Id: I62abe39a5cb5e7f8b1bb1198cecd3b529b124de8
Signed-off-by: Shashank Mittal <mittals@codeaurora.org>
2016-04-22 14:58:05 -07:00
Shashank Mittal
534fd1b6c4 coresight-tmc: add support to switch sinks
Add support to switch to a different Coresight sink when one or
more Coresight tracing sources are enabled.

Change-Id: I79f769f0913124710ae56fddea7d205359e09b43
Signed-off-by: Shashank Mittal <mittals@codeaurora.org>
2016-04-22 14:57:55 -07:00
Shashank Mittal
93e852721d coresight: add remote etm driver support in upstream implementation
Add remote etm driver in upstream implementation of Coresight
driver.
This change copies coresight-remote-etm.c file from drivers/coresight
(commit c1fe9ac38d93 ("input: touchscreen: correct function and variable
names in ITE tech driver"))
to driver/hwtracing/coresight directory.

Change-Id: I77a1aaf10aaf3f3010ab19d5878bb53dcc504c29
Signed-off-by: Shashank Mittal <mittals@codeaurora.org>
2016-04-22 14:57:42 -07:00
Shashank Mittal
966e92d21f msm_bus: coresight: fix to support upstream implementation
Upstream's Coresight driver doesn't have id field in
coresight_platform_data. So use device name instead to link bus clk with
Coresight device node.

Change-Id: I9f70974d64154217c2701879eb428beef1857fcf
Signed-off-by: Shashank Mittal <mittals@codeaurora.org>
2016-04-22 14:57:31 -07:00
Shashank Mittal
6c73cbbdbe coresight: fix kstrtoul usage
Unlike sscanf kstrtoul function returns 0 on success and non-zero value
in case of an error.

Fix Coresight code to check error condition correctly.

Change-Id: Id1bd544a9928ed6b13c278f12a47070d1ca353a7
Signed-off-by: Shashank Mittal <mittals@codeaurora.org>
2016-04-22 14:57:21 -07:00
Shashank Mittal
41c473f37f coresight-cti: use for_each_cpu instead of for_each_cpu_mask
for_each_cpu_mask is deprecated, so replace that with for_each_cpu.

Change-Id: I21a937053ce8a7f3a81a09f78e873b7c71421b72
Signed-off-by: Shashank Mittal <mittals@codeaurora.org>
2016-04-22 14:57:10 -07:00
Shashank Mittal
a9af086a5a coresight: fix compilation issue due to missing of_coresight.h file
In upstream implementation there is no of_coresight.h file. That causes
compilation issue with some of the Coresight components.

Change-Id: I81bf45e1e322e1d90ac70c6e73738b7348cf85e1
Signed-off-by: Shashank Mittal <mittals@codeaurora.org>
2016-04-22 14:56:58 -07:00
Shashank Mittal
bb91c2f611 coresight: tmc: add usb bam support for etr device
Add support to use etr device in usb bam mode.

In usb bam mode traces can be streamed over usb.

Change-Id: I5509c01aeb704a7b3ec8406130886145f7fddc10
Signed-off-by: Shashank Mittal <mittals@codeaurora.org>
2016-04-22 14:56:55 -07:00
Manaf Meethalavalappu Pallikunhi
8e9dbc4e1d msm: thermal: Request INT_MAX as max for regulator set voltage API
During Vdd restriction trigger/clear request, KTM request it's vote
to regulator via regulator_set_voltage() API. KTM is interested only
in min value for this feature, always request INT_MAX as max value
instead of supported MAX corner of that regulator. It makes sure
that there is no impact if MAX corner for that regulator is changed
at any time.

Change-Id: Iebcb0383ea7b44d8584adb610ca7b56f0db2e755
Signed-off-by: Manaf Meethalavalappu Pallikunhi <manafm@codeaurora.org>
2016-04-22 14:56:41 -07:00
Liam Mark
06964f9d53 arm64: mm: preserve 4k mappings for late mappings
There are several features such as CONFIG_FREE_PAGES_RDONLY
which depend on pages being mapped as 4k.
When we creating late mappings ensure that 4K mappings
aren't replaced with block mappings if CONFIG_FORCE_PAGES
is enabled.

CRs-Fixed: 1004260
Change-Id: I9f1853c71ba6dec92ede869b90e220d63af6ae3e
Signed-off-by: Liam Mark <lmark@codeaurora.org>
Signed-off-by: Patrick Daly <pdaly@codeaurora.org>
2016-04-22 14:56:30 -07:00
Skylar Chang
043b5b2046 defconfig: msm: enable ipa3 nodes on cobalt
enable ipa3 on cobalt build

Signed-off-by: Skylar Chang <chiaweic@codeaurora.org>
Change-Id: I562bf73e375ce78227746a9eaf0fb256abf69ce5
2016-04-22 11:57:56 -07:00
Skylar Chang
2d3f067449 ARM: dts: msm: disable IPA3 on MSMCobalt rumi
Disable ipa-driver on MSMCobalt rumi build.

Signed-off-by: Skylar Chang <chiaweic@codeaurora.org>
Change-Id: I8447214ca3fcf4567979ce2538dc342c4957e4d4
2016-04-22 11:57:55 -07:00
Devesh Jhunjhunwala
14648993db clk: msm: clock-gcc-cobalt: Remove support for glm clocks
The glm clocks are controlled by TZ, so remove support for
these clocks from the clock-gcc-cobalt driver.

Change-Id: Ibfb8f211ca8c29617aca4ff0ee885366f95aac00
Signed-off-by: Devesh Jhunjhunwala <deveshj@codeaurora.org>
2016-04-22 11:57:54 -07:00
Deepak Katragadda
7d94420659 clk: msm: clock: Change the check_enable_bit log to pr_warn
Change the log about the clocks being enabled even without a
SW vote to pr_warn instead of WARN. The stack trace isn't very
helpful in this case and cause a lot of logging.
Also, add the check_enable_bit property to some SMMU clocks
which are votable.

CRs-Fixed: 1006841
Change-Id: Icb15b038b170590e69073ca628b3d610e14893da
Signed-off-by: Deepak Katragadda <dkatraga@codeaurora.org>
2016-04-22 11:57:54 -07:00