In the scenario where the charging is terminated in the
JEITA soft condition, the HW is expected to restart
charging when battery temperature returns back to normal.
However, this does not work as expected and the charging
stays terminated. Fix this by disabling and re-enabling
charging CMD bit to restart charging.
CRs-Fixed: 2071261
Change-Id: I81d2a89c72ede840cc561b736ce1366c65da8c42
Signed-off-by: Anirudh Ghayal <aghayal@codeaurora.org>
Add board-id for UFS board which has a different board sub type.
Change-Id: Ic231784c46d4439944e403e26410515856fdc5fb
Signed-off-by: Lei wang <leiwan@codeaurora.org>
When calculating po->tp_hdrlen + po->tp_reserve the result can overflow.
Fix by checking that tp_reserve <= INT_MAX on assign.
Change-Id: If3b5fd73bd440de2a1050644b71ef7430f09810f
Signed-off-by: Andrey Konovalov <andreyknvl@google.com>
Acked-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Git-repo: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
Git-commit: bcc5364bdcfe131e6379363f089e7b4108d35b70
Signed-off-by: Dennis Cagle <dcagle@codeaurora.org>
When calculating rb->frames_per_block * req->tp_block_nr the result
can overflow.
Add a check that tp_block_size * tp_block_nr <= UINT_MAX.
Since frames_per_block <= tp_block_size, the expression would
never overflow.
Change-Id: I183d9adb8b90010f408b5e1d0785aa06814f4348
Signed-off-by: Andrey Konovalov <andreyknvl@google.com>
Acked-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Git-repo: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
Git-commit: 8f8d28e4d6d815a391285e121c3a53a0b6cb9e7b
Signed-off-by: Dennis Cagle <dcagle@codeaurora.org>
Not all targets support the DCI channel over MHI. Fix
error handling to only cleanup the failing device if
MHI registration fails.
Change-Id: I5ba23d69bc1fa3c08468d930f5f50151bfcd5bc0
Signed-off-by: Chris Lew <clew@codeaurora.org>
On an MHI down notification, the enabled state is set to 0 before
flushing the workqueue and buffers. This sanity check conflicts
with the down notification. Remove unneeded sanity check.
Change-Id: I6bedc353187bee907775347009e0d4157b0e35e2
Signed-off-by: Chris Lew <clew@codeaurora.org>
In order to support DT on DIAG, convert diag
bridge driver to platform driver.
Change-Id: I0ddecc06d9b4845d822799f3cff942789d1441c6
Signed-off-by: Sujeev Dias <sdias@codeaurora.org>
This can make sure MHI driver can safely free the memory which
is used by WLAN firmware since device is powered off.
Change-Id: If9d891eaf1ca7c28869448b3a0a42be713e16c2e
Signed-off-by: Yue Ma <yuem@codeaurora.org>
Mark as rw when adding as linear target to allow changes
to the underlying filesystem through adb disable verity
and adb remount.
(Cherry-picked from
https://partner-android-review.googlesource.com/#/c/613573/
79a3032bb62da65a5d724eb70c8bdc662945d475)
BUG: 28845874
Signed-off-by: Badhri Jagan Sridharan <Badhri@google.com>
Change-Id: If41e9cad8e0f054f4778c09a6e2f0cb8af6fddaf
Git-commit: 492a6047e7
Git-repo: https://android.googlesource.com/kernel/common/
Signed-off-by: Runmin Wang <runminw@codeaurora.org>
Add MultiMedia21 capture and routing support for ASM
loopback from AUX PCM TX to QUAT TDM RX.
CRs-fixed: 2069348
Signed-off-by: Derek Chen <chenche@codeaurora.org>
Change-Id: I632392d98092ff31fa9bdb13c02eef8c2a0a54a3
Update bootargs with configuration of lpm_levels.sleep_disabled.
CRs-Fixed: 2079671
Change-Id: Iced6d6fc8e571b342a77ce49b4fa54bf511d7dbc
Signed-off-by: John Zhao <yuankuiz@codeaurora.org>
Currently, there is a possibility of NULL pointer dereference
while accessing diag master table. The patch adds proper check
for null pointer while iterating over the list.
CRs-Fixed: 2077525
Change-Id: I51075b7a7f3acce0cb27822ad1acd8a5894cdaa9
Signed-off-by: Hardik Arya <harya@codeaurora.org>
Peer delete response event is not parsed for the
params being sent by firmware.
Parse the tlv params and get the peer mac address
which was deleted.
CRs-Fixed: 2079551
Change-Id: I1f603d65784611d5f82babf2d9fa9dca5b1664b7
Signed-off-by: Rakesh Pillai <pillair@codeaurora.org>
The last_pet variable is set in suspend callback and during
pet_watchdog() and is printed when watchdog bark handler gets
called. This variable does not represent exact last pet time in
cases where non secure bark occurs before system could pet the
watchdog upon wakeup event from low power mode. Reset the
watchdog during msm_watchdog_resume() and update last_pet
variable so that watchdog bark messages will represent latest
info.
This commit also adds memory barrier after resetting watchdog in
msm_watchdog_suspend(). This will make sure watchdog writes are
complete before proceeding further.
Change-Id: I44492a947bc3664b7d14cfae9e877ebe0dc32836
Signed-off-by: Sarangdhar Joshi <spjoshi@codeaurora.org>
Signed-off-by: Mohammed Khajapasha <mkhaja@codeaurora.org>
If the request->length is zero, a ZLP should already be sent due to that
and another ZLP is not needed to terminate the transfer.
Fixes: 04c03d10e507 ("usb: dwc3: gadget: handle request->zero")
Signed-off-by: John Youn <johnyoun@synopsys.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
Change-Id: I747a9fd710d90986c7befd3d5ee5a1a5fceeaaed
Git-commit: d9261898a4b2c143c28568dc686a1becfc637a99
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
Signed-off-by: Vijayavardhan Vennapusa <vvreddy@codeaurora.org>
So far, dwc3 has always missed request->zero
handling for every endpoint. Let's implement
that so we can handle cases where transfer must
be finished with a ZLP.
Note that dwc3 is a little special. Even though
we're dealing with a ZLP, we still need a buffer
of wMaxPacketSize bytes; to hide that detail from
every gadget driver, we have a preallocated buffer
of 1024 bytes (biggest bulk size) to use (and
share) among all endpoints.
Reported-by: Ravi B <ravibabu@ti.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
Change-Id: Ib4cb734bdb90ea142ced0d3b5299ee37ffce0352
Git-commit: 04c03d10e507052cfce6910ddf34091196e79e1c
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
[vvreddy@codeaurora.org: resolved merge conflicts]
Signed-off-by: Vijayavardhan Vennapusa <vvreddy@codeaurora.org>
When the Camera application exercises the V4L2 ioctl operations, CPP
driver would attempt to the copy user space buffer contents into the
internal kernel buffer. If an invalid length of the user space buffer
is passed onto the driver, it could trigger buffer overflow condition.
Thus, fix this by copying user space buffer contents into kernel space
buffer of the driver for further processing, only after checking for
proper length of user space buffer.
Change-Id: I0386d0f84a8d7015bfe6bbb1e9472fa8934df83a
CRs-Fixed: 2025367
Signed-off-by: Rahul Sharma <sharah@codeaurora.org>
stream_idx cannot take negative value and wrongly type casted to int.
Use uint32_t to fix this issue.
Change-Id: I7f306d3a24fc8f73aae91c0514b3747592466404
Signed-off-by: Srikanth Uyyala <suyyala@codeaurora.org>
Power collapse should be transparent to vidc layer, so
clock rate should be retained across suspend resume.
Add change to save clock rate during suspend, and restore
clock rate during resume.
Change-Id: I7e01ddcfc5b2f7d02f76512e1cbaf1a75bacdb03
Signed-off-by: Surajit Podder <spodder@codeaurora.org>
HDR playback needs metadata to be sent to the sink
while the playback is ongoing and needs a proper
teardown sequence when the playback has ended with respect
to the infoframe being sent to the sink.
This needs a state machine to synchronize start/stop of
the playback with sending the right metadata along with
resetting the infoframe HDMI registers.
Add support for this HDR playback control state machine.
Change-Id: I229183531f7ccb48579e74d02e0a1dea1cb945ff
Signed-off-by: Abhinav Kumar <abhinavk@codeaurora.org>
USB device is failing to initiate L1 remote wakeup for following
scenarios:-
1) When USB host initiates L1 between control transfers
(Setup and Status Phase).
2)In case of BULK only composition when USB host initiates L1 after
PING retries on OUT endpoint. Device fails to initiate L1 remote
wakeup when SW issues start transfer.
3) When bus is suspended and Start transfer is issued on IN TRB
Hence disable high speed link power management support by advertising
bcdUSB as 2.0 in high speed mode.
Change-Id: I83124d5e3821ba979be4772bc04e41f05dc7492c
Signed-off-by: Hemant Kumar <hemantk@codeaurora.org>
The patch synchronizes msg mask read and write on a peripheral
by proper protection of mask_info and msg_mask_table_count.
CRs-Fixed: 2042362, 2055291
Change-Id: If136012855834b0b8cba91eb66bf711750e8f372
Signed-off-by: Manoj Prabhu B <bmanoj@codeaurora.org>
Add device tree entries to support depth sensor.
Change-Id: I7b2219b95e69b44a4048a4f163b1b079a55050e1
Signed-off-by: Vijay kumar Tumati <vtumati@codeaurora.org>
Add execute permission for hyp_assign_phys for adsp shared
memory region to allow for the memory to be reused by other user
space processes when this is not used by the remote processor.
Change-Id: I4f593584f332f8dc775afb68e6bfae1ea8f803fa
Acked-by: Viswanatham Paduchuri <vpaduchu@qti.qualcomm.com>
Signed-off-by: Tharun Kumar Merugu <mtharu@codeaurora.org>
There is a chance of deleting, already deleted list
in ipa_cleanup_wlan_rx_common_cache API.
Protect the wlan_comm_desc_list,
with the spinlock to avoid this deletion.
Change-Id: I10161f71b92d6d5fe06af62b65bf3d92d0d4512a
Signed-off-by: Mohammed Javid <mjavid@codeaurora.org>
The patch initializes the glink buffers only to peripherals
supporting it and moves the handling of processing the data
received on glink buffers to process context.
CRs-Fixed: 2042362
Change-Id: I24522489ec5e499ff4ef97be0fef356a1671ec62
Signed-off-by: Manoj Prabhu B <bmanoj@codeaurora.org>
It is possible that host sends SEND_STRING control request with zero
length and in that case, driver ends up setting string as NULL. This
results in CTS failure for accessory test. Hence add check for length
and update string only if length is nonzero.
Change-Id: I4594a46f830f45fc49f80a74ec6042383edf007d
Signed-off-by: Vijayavardhan Vennapusa <vvreddy@codeaurora.org>
This reverts commit 7d6f012ed1.
Traffic shaper is not required for 60fps 4k video. OT settings
will take care of this.
Change-Id: Id6e65da102c7fa43cf215129643c7a54e6a72085
Signed-off-by: Jayant Shekhar <jshekhar@codeaurora.org>
Since the PMIC GPIO runtime configuration is not feasible using
pinctrl framework, add it as fixed regulator for WLAN_EN pin.
Signed-off-by: Yue Ma <yuem@codeaurora.org>
CRs-fixed: 2071634
Change-Id: Ifd08bac34388389c6aced7e450cbf5c6ae37b36d