The new request notification test checks the following scenario:
A new request arrives after a NULL request was sent to the mmc_queue,
which is waiting for completion of a former request.
Change-Id: I05db0959ded400e292eb5e84e1ecfc579b78ee62
Signed-off-by: Konstantin Dorfman <kdorfman@codeaurora.org>
Signed-off-by: Lee Susman <lsusman@codeaurora.org>
Add statistics infrastructure for new_request_notification
mechanism. Information about the mechanism is collected by
counters that are located at decision points in the flow
of this feature.
Change-Id: I863911e7ecade609b3b4dff619dd6b059a098fcc
Signed-off-by: Konstantin Dorfman <kdorfman@codeaurora.org>
Signed-off-by: Lee Susman <lsusman@codeaurora.org>
Add functionality to test-iosched so that it could simulate the
ROW scheduler behaviour. The main additions are:
- 3 distinct requests queue with counters
- support for urgent request pending
- reinsert request implementation (callback + dispatch behavior)
Change-Id: I83b5d9e3d2b8cd9a2353afa6a3e6a4cbc83b0cd4
Signed-off-by: Konstantin Dorfman <kdorfman@codeaurora.org>
Signed-off-by: Lee Susman <lsusman@codeaurora.org>
WFD uses proxy driver to transfer pcm data from/to Q6 and it
requires support for period size about 1920 bytes for stereo.
Adjust period bytes and num periods for proxy driver so as to
support this usecase.
Change-Id: I5aa73f610cd7961b482eddf82d0aeb246bcc0cf7
Signed-off-by: Phani Kumar Uppalapati <phanik@codeaurora.org>
Currently driver doesn't prevent system suspend if UART port is
being used. This change adds support to prevent system suspend
when UART port is opened/under used. With this feature, wakelock
is acquire when UART port is being opened and release when UART
port is being closed.
To enable this feature, set use_pm platform data with required
UART port.
Also document use_pm pdata usage with device tree binding.
CRs-Fixed: 430726
Change-Id: I441b527af7047d57f6a5366e7c8277f413dc9d4e
Signed-off-by: Mayank Rana <mrana@codeaurora.org>
GSBI based UART is used in shared mode. Hence this driver only
supports configuring Tx and Rx GPIOs with configuring GSBI control
register with I2C/UART Shared mode protocol.
Add support in this driver for 4-wire UART related configuration
i.e.GPIOs (i.e. Tx, Rx, CTS, RFR signal lines) and programming
GSBI control register with UART mode protocol.
4-wire UART related configuration is done based on platform data
variable config_gpio.
For 4-wire UART, set config_gpio as 4 to configre all 4 GPIOs.
For 2-wire UART, set config_gpio as 1 to configure only Tx and Rx
GPIOs.
Also document added new pdata and their usage with device tree.
CRs-Fixed: 430725
Change-Id: I9236c63778406f004a96d782a4614cb5db46755c
Signed-off-by: Mayank Rana <mrana@codeaurora.org>
During constant voltage charging, the BMS reports a SoC calculated
by linearly interpolating battery current. However, sometimes the
charger does not immediately stop at -100 mA, and sometimes dips a bit
lower. This causes the BMS to report > 100% SoC and may cause a bad
user experience.
Fix this by clamping the linearly interpolated SoC to [0, 100].
CRs-Fixed: 430456
Change-Id: I3621a0a204360343ba684e2217a68a6ef51a7850
Signed-off-by: Xiaozhe Shi <xiaozhes@codeaurora.org>
Reset interrupt is sent to WCNSS when host drivers fail to
communicate with WCNSS over SMD. So log certain Pronto registers to
know the failure reason at Pronto. Similar debug mechanism is already
added for Riva. The same WCNSS registers are also logged in watchdog
bite handler.
Change-Id: I0ef4256b9702a61785e9ca2f0ccbf9f947d6dfa7
Signed-off-by: Sameer Thalappil <sameert@codeaurora.org>
Provision all mtp, cdp and fluid devices with finely tuned
touch configuration data. Configuration delivers
improved accuracy, multitouch support and power savings.
CRs-fixed: 432586
Change-Id: Ib1ca32010db1556fb55869a91d15b57c6ad922f3
Signed-off-by: Amy Maloche <amaloche@codeaurora.org>
This change adds the implementation of mhl discovery
detection procedure, USB hand-off function. Three APIs
are exposed from MHL driver to USB driver: for
register/unregistering callbacks from USB and triggering
device discovery detection in MHL hardware. By default, all
the USB interrupts are directed to the USB hardware which is
detected by USB driver and at appropriate points the USB
driver triggers the MHL device discovery and uses the results
to either hand control to MHL driver or continue with it's own
detection mechanism.
Change-Id: Ic1e22bc4c446de209f2e72d5dda8b823bfd398c8
Signed-off-by: Manoj Rao <manojraj@codeaurora.org>
The data type of the ipi-ping field should match its semantics: a
boolean value. Change the watchdog driver to use the boolean
procedures and change all device tree clients to use the boolean
syntax.
Change-Id: I36459ebc5dc25efe8939f477405fd34ea7b650d1
Signed-off-by: Mitchel Humpherys <mitchelh@codeaurora.org>
In certain memory configurations there can be a large number of
CMA pages which are not suitable to satisfy certain memory
requests.
This large number of unsuitable pages can cause the
lowmemorykiller to not kill any tasks because the
lowmemorykiller counts all free pages.
In order to ensure the lowmemorykiller properly evaluates the
free memory only count the free pages which are suitable for
satisfying the memory request.
Change-Id: Iabc3bebc54be9dec7fcbffb94a2fbf18dd684669
Signed-off-by: Liam Mark <lmark@codeaurora.org>
Signed-off-by: Laura Abbott <lauraa@codeaurora.org>
Currently Rx Break Error condition is not checked using UART_DM_SR
register. Hence by default null-character is being inserted on
receiving Rx Error or Rx Break condition. Application sets termios
c_iflag if it needs any notification related to any Rx Error or
Break condition. Hence add support to handle Rx Break condition and
insert null-character conditionally based on termios.c_iflag.
CRs-Fixed: 412201
Change-Id: I7f496e42757b949f597d5dbe5c1f1ca88ee53c8c
Signed-off-by: Mayank Rana <mrana@codeaurora.org>
RCU_FAST_NO_HZ has been shown to improve power consumption
thanks to CPUs entering nohz idle mode more quickly.
The 7627a and 8660 configurations are omitted until they
can be properly tested with RCU_FAST_NO_HZ.
Change-Id: I4d578ba0496fa46917aa2544fe5314a6d29826fc
Signed-off-by: Steve Muckle <smuckle@codeaurora.org>
Move msm timer code to use the udelay timer implementation.
Change-Id: If1ad095d6852f5966ea995856103e06de6ab2f59
Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
Upon interface suspend driver performs suspend on data channel
first and then on control channel. In case if suspend aborts
due to pending transfer on control channel, driver is not
undoing data channel suspend. This causes stall on data channel.
Fix the problem by performing suspend check on control channel
first. In this case if suspend aborts on control channel, driver
does not have to undo anything to abort interface suspend. Once
data channel suspend succeeds driver performs suspend on control
channel.
Signed-off-by: Hemant Kumar <hemantk@codeaurora.org>
Change-Id: I405b4797740e1b2aa67c6c28a2f3dcee0c196391
Commit: b7434561, "USB: dwc3: Add support for basic OTG in superspeed
mode" introduced regression by not putting hardware in LPM on bootup
without USB cable connected.
During boot-up external transceiver driver may notify initial BSV
and ID events to OTG driver even if they are not changed. Since,
ext_xceiv driver brings hardware out of LPM before notifying
events to OTG, hence, schedule state-machine which then takes care
of putting hardware in LPM accordingly.
CRs-Fixed: 433384
Change-Id: I1e74bc2b1febb6dd91293aad9e3690bd2c2eaed2
Signed-off-by: Manu Gautam <mgautam@codeaurora.org>
The 8930AB clock plan supports DDR@600MHz. Update the graphics
bandwidth vote to use this higher frequency on 8930AB.
Change-Id: I8891ecdb202b335f8fe43a663616a4745167d252
Signed-off-by: Lynus Vaz <lvaz@codeaurora.org>
In modem SSR case rescheduling of queue_rx_work for every 100ms
causing system to overload by rescheduling unnecessary work and
overflow kernel meesages with rescheduling logs.
Hence block the rescheduling of queue_rx_info
by adding in_global_reset flag check during modem SSR.
CRs-Fixed: 422096
Change-Id: I14bc8d82e44231a86b58faa0158740565177653d
Signed-off-by: Arun Kumar Neelakantam <aneela@codeaurora.org>
USB wall charger falls under the category of a dedicated wall
charger. Categorize it as a type of MAINS power supply.
CRs-Fixed: 429508
Change-Id: I1ba3ace8836aa4b094b8454fb78e24ea66c826ff
Signed-off-by: Anirudh Ghayal <aghayal@codeaurora.org>
Handle return code in reading vsense average so that
the parent function pm8921_bms_get_battery_current does not
report invalid battery current. While at it, also fix the
variable initialization.
CRs-Fixed: 389636
Change-Id: If24985f47cc9fcd6c2eb84a73165878559008120
Signed-off-by: Anirudh Ghayal <aghayal@codeaurora.org>
Provide an abstraction for IOMMU clients by decoupling clients
from actual IOMMU devices by allowing clients to find an IOMMU
group based on its name.
Change-Id: I89702cc761113197b6fd58c3372fd47f9b00bfaa
Signed-off-by: Olav Haugan <ohaugan@codeaurora.org>
The hardware crypto engine is not accessible without enabling
the correct clocks. Following clocks are added for the
crypto driver to access the crypto engine:
- core clk.
- iface clk.
- bus clk.
- core source clk.
Change-Id: I6254fe51fc57bdd8571ae5038d974087b4bb8000
Signed-off-by: Hariprasad Dhalinarasimha <hnamgund@codeaurora.org>
Add device tree entries for both qcrypto and qcedev.
Change-Id: If95d9cdf2514f28abefc5986abb91939af4260b4
Signed-off-by: Hariprasad Dhalinarasimha <hnamgund@codeaurora.org>
The current code allocates a new Rx buffer in Rx completion handler.
Rx buffers are freed after user space consumes them. This results in
allocating larger buffers in atomic context which may fail some times.
Don't queue the Rx buffer immediately. Defer it till user space consumes
it and reuse the same buffer. The test results indicate no throughput
degradation. The Rx buffers will be freed when interface is suspended
or disconnected.
CRs-Fixed: 430595
Change-Id: I8e69e27df2e11b38497e0384a8edd87ecedcb24b
Signed-off-by: Pavankumar Kondeti <pkondeti@codeaurora.org>
Driver need to configure the debug mode to
Venus firmware. Venus firmware won't send any
messages to driver without this setting.
This change fixes the same.
Change-Id: I24cac6054afc65b9672bb5b294d641053ddd87ea
Signed-off-by: Praneeth Paladugu <ppaladug@codeaurora.org>
Currenly CAD driver only supports VOICE method when setting volume.
For applying dynamic PMIC gain MIDI method is used. Changes are made
to support MIDI method also.
Change-Id: Id2d4868c88ef1fc08bbdbd3757905edc5435923c
Signed-off-by: Chaithanya Krishna Bacharaju <chaithan@codeaurora.org>
Extend Demux user-space API to set decoder buffers allocated externally
by user, supporting multiple linear buffers or a single cyclic buffer.
Internal decoder buffer allocation is still supported.
Change-Id: I98c63fffa14b597945dff8b4ac2fde05d9719e1b
Signed-off-by: Gilad Broner <gbroner@codeaurora.org>
FEMTO-452 will use the IPsec feature on APQ8064
Change-Id: I2e6d78fda4fde12af9715d45f2e24349370c4ac4
Acked-by: Ho Lee <holee@qti.qualcomm.com>
Signed-off-by: Rohit Vaswani <rvaswani@codeaurora.org>
Return 0 from mbim_read only as an indication
of reset command and cable disconnection.
For all failure cases return error code not equal 0.
CRs-Fixed: 429455
Change-Id: Ia921bf4cbda7647e6b04042943ed17759d8d9d9b
Signed-off-by: Anna Perel <aperel@codeaurora.org>
USB3 RAMs are used as data/descriptor FIFOs for BAM to BAM uses.
The clocks for these can be selected between master_clk or
ram_clk_gated. Since, ram_clk_gated can be gated off by hardware
if clk_gating is enabled using DWC3's GCTL register, hence,
select master_clk as RAM clock using QSCRATCH.
This allows other BAMs to access USB RAMs when clock gating is enabled
via DWC3's GCTL. Otherwise issues are seen where RAM clocks get turned
OFF in Super Speed mode.
CRs-Fixed: 432016
Change-Id: I7243e45fc71162df40724494136524dd44d6ae27
Signed-off-by: Manu Gautam <mgautam@codeaurora.org>
Tests have shown that entering pfm mode when there is more than one
cpu running at 300Mhz causes instability.
Update the current required at 300Mhz to 400mA so that pfm mode is
entered only when one cpu is online and is running at 300Mhz.
This 400mA is a temporary placeholder and will be a updated when
HW is characterized.
Change-Id: I93d5630ff9e797c981db3d64c5d71097dba9f3fc
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
Modify min and max period bytes and number of periods in
compressed driver so as to be consistent with lpa and to
meet ION memory requirements. This avoids using huge
buffer sizes for tunnel decode.
Change-Id: Ib71da4cebfc097e7aeaf0ca0e65ee847ba7cceb7
Signed-off-by: Phani Kumar Uppalapati <phanik@codeaurora.org>
This patch adds the gpiomux configuration for GPIOs of SDC3 & SDC4
slots. SDCC functionality for these GPIOs are muxed with other
functionalities so before enabling the relevant config options for
SDC3/SDC4, make sure that current functionality for those GPIOs are
disabled.
Change-Id: Ibec38407163593aa72f34af5df01b37c14d29c26
Signed-off-by: Subhash Jadavani <subhashj@codeaurora.org>
Return non-zero Relative-State-Of-Charge (RSOC) when I2C fails.
The battery manager shuts down the device when battery capacity is 0%
(and DC is not on-line).
The battery interface to user space will return error on I2C failure.
Change-Id: I772166746f2c604dd3e10547a108654ee02497c7
Signed-off-by: Amir Samuelov <amirs@codeaurora.org>
QDSS and DBM drivers reports error when USB cable is
disconnected in QDSS composition. These errors are due to
qdss_disable is not calling DBM driver's API uninit the EP.
Also, set EP's flag as BUSY once DBM queues TRB to hardware to
avoid any possibility of DWC3 re-submitting the TRB later.
Change-Id: I95b82f3c74feb1f4fa56e601caf2ef7563c593bd
Signed-off-by: Manu Gautam <mgautam@codeaurora.org>
RPM uses the virual MPM status register to determine if apps processor
needs to be woken up from a system wide low power mode. If the status
register is not cleared, RPM would wake up the apps processor on a
wakeup signal that isn't intended for Apps. To prevent such spurious
wake up clear the status register when entering RPM assisted power
collapse.
Change-Id: Ie832429f37f3e7b1a848d006664ea1ff1de302d4
Signed-off-by: Mahesh Sivasubramanian <msivasub@codeaurora.org>
If the card is removed before a request is started, the error
was not propagated to core and block layers. This led to flooding
of messages on the console leading to a crash/hang.
This patch propagates the appropriate error to the upper layers as a
result of which the request is failed quietly without flooding of
console.
CRs-fixed: 424497
Change-Id: Ica35c33ea26c27d13bd2cd0ae1b9d926bc0240b9
Signed-off-by: Asutosh Das <asutoshd@codeaurora.org>
Upon detecting HDCP authentication failures, reauthentication
attempts should be kicked off after a small delay. Instead of
using kernel timers, this is achieved by having the existing
HDCP work item as a delayed work.
Change-Id: I7d04b33b159c718cd347576d18cffd1b705bb790
Signed-off-by: Aravind Venkateswaran <aravindh@codeaurora.org>
When a connected sink is operating in DVI mode, the HDMI Tx
controller should also be programmed accordingly to operate in
DVI mode.
Change-Id: I63176b55be86a0fe73b23880fc1d45f7a2272d32
Signed-off-by: Aravind Venkateswaran <aravindh@codeaurora.org>
Modify min and max period bytes and number of periods in
compressed driver so as to be consistent with lpa and to
meet ION memory requirements.
Change-Id: I216b7a7d3f38867725782b450dd62237faa856ee
Signed-off-by: Phani Kumar Uppalapati <phanik@codeaurora.org>
The subsystem framework will use this information to do
housekeeping work on the subsystem like taking ramdumps
(if enabled) when the next subsystem_put() is called, etc.
Change-Id: I5b76acde223e46c04b51a6b84950f4d59566c8c7
Signed-off-by: Vinay Kalia <vkalia@codeaurora.org>
To turn off droop detectors in glitch free mux, the krait PLL clamp
is set permanently for secondary cores in platsmp secondary boot path.
Set the pll clamp for primary core as well.
Change-Id: I4b18e7781515c3c66ef629c3c8ca3457ca9b2874
Signed-off-by: Jay Chokshi <jchokshi@codeaurora.org>
Change the active and sleep set force mode configurations for
SMPS 3 and 4 on MSM8930+PM8917 targets to "none". This ensures
that crashes to not occur due to instability caused by using
"auto" mode.
Change-Id: I1522f334dbf3e6b7050beb943e8cbd4e661a18d0
CRs-Fixed: 432618
Signed-off-by: David Collins <collinsd@codeaurora.org>
Currently HDMI audio support is implemented with HDMI CPU driver and
dummy codec driver. HDMI CPU DAI configures both QDSP6 AFE and also
HDMI controller. This patch moves the functionality of HDMI codec
driver out of combined HDMI CPU and codec driver into a ASoc codec
driver.
Change-Id: Iee190c0524558136b228a443efc6690dc30a7287
Signed-off-by: Kiran Kandi <kkandi@codeaurora.org>
For graceful shutdown or reboot scenarios, RMT storage
sync must be completed successfuly before device shutdown.
So register with reboot notifier to initiate the RMT
storage force sync.
CRs-Fixed: 419695
Change-Id: I6d8783d2ad2b7112fd6e84d3a9dcf033cc804a8c
Signed-off-by: Prasad Sodagudi <psodagud@codeaurora.org>
Signed-off-by: Pratibhasagar V <pratibha@codeaurora.org>
Handle venus watchdog timeout by informing all
clients about the error so that existing video
sessions can be closed.
Change-Id: I631e319c810d8114050b21038e2f9edbbaf7427e
Signed-off-by: Vinay Kalia <vkalia@codeaurora.org>
Remove venus subsystem restart related code as this
code is obsolete now after architecture changes in
subsystem restart framework.
Change-Id: I429f5d6ccf6d0a6f0d2513fb0e52c2ed0206e77d
Signed-off-by: Vinay Kalia <vkalia@codeaurora.org>