msm: camera: Check for open camera instances before release

Release the subdevs and QOS variables only if there are active
camera instances

Change-Id: If8f6eb80cf7bd21e36de988ad6c4df7441d655ae
CRs-fixed: 490249
Signed-off-by: Alok Kediya <kediya@codeaurora.org>
msm: kgsl: Fix the extra draw packet on resume for A305

The extra draw command on resume was missing some state. Add the missing
state registers, to avoid stability issues.

Change-Id: Iad51cbe3be7b2951563c989625a690178491e0c8
Signed-off-by: Lynus Vaz <lvaz@codeaurora.org>
Bluetooth: Disable Sniff on HID ACL(s) if SCO is active

This patch disables sniff support on HID ACL(s) if SCO is active by
updating Link Policy settings. Once SCO is disabled, link policy is
again updated to re-enable Sniff on HID ACL(s). Without this patch
it was seen in presence of SCO, disconnection was observed on HID
ACL(s).

Change-Id: I81e0b3725bdadffe06ddb345afb9de2e042d5f9a
CRs-Fixed: 509616
Signed-off-by: Hemant Gupta <hemantg@codeaurora.org>
msm: bam_dmux: delay shutdown until DL polling is complete

Bam_dmux assumes that a shutdown event will not occur while downlink (DL)
polling is active. If this assumption does not hold, bam_dmux stops
polling, but does not cleanly switch back to interrupt mode until the next
power-on event. This is a problem because the next power-on event could
occur in the distant future and until that time some resources may be
incorrectly accessed or not released. Instead, if a shutdown event occurs
while DL polling is active, delay processing of that event until polling
completes.

CRs-Fixed: 503046
Change-Id: I67e4216b4820942e6070944557cd13f59600a2aa
Signed-off-by: Brent Hronik <bhronik@codeaurora.org>
spi_qsd: set device's runtime PM status to 'suspended'

Device's runtime PM status is not in suspended state during
system suspend.

CRs-Fixed: 512718
Change-Id: I5c0cb39c0b91782d8686c1b3da81125169ccf9be
Signed-off-by: Alok Chauhan <alokc@codeaurora.org>
msm: display: Do not commit in unset for external.

In case of external, commit is happening in unset itself which
is causing flickers. This patch fixes the issue.

Change-Id: Id55346be7a155108954e23bef236db80e7b65152
Signed-off-by: Vishnuvardhan Prodduturi <vproddut@codeaurora.org>
radio: iris: Handle force close gracefully

Do not queue the FM disabled event while in OFF state.

Change-Id: I8f8cd31198f8bb1a7521920844e0f0c5c3190b08
CRs-Fixed: 492216
Signed-off-by: Venkateshwarlu Domakonda <Venkateshwarlu@codeaurora.org>
u_hsuart: Fix a bug in opening the SMUX port

commit 9fdf017a (tty: n_smux: add separate close notifications)
implemented SMUX_LOCAL_CLOSED notification for clients to know
when the port is ready for opening again.  Use this notification
and defer opening until the port is ready.  If the port is opened
before this notification is arrived, the open will fail and
rmnet/dun does not work.

CRs-Fixed: 509013
Change-Id: I18bf9f08029fb98d611679d3aa65d13b088da8bc
Signed-off-by: Pavankumar Kondeti <pkondeti@codeaurora.org>
Merge "u_hsuart: Fix a bug in opening the SMUX port"
Merge "msm: camera: Check for open camera instances before release"
msm_serial_hs: Increase rx buffer size to 1024bytes

Increase the UARTDM rx buffer size from 512 bytes
to 1024 bytes. This patch helps to increase the
rx data rates of the clients that uses serial_hs driver.

CRs-Fixed: 514385
Change-Id: I2956020af299dda849cfbef795728da2d8664c77
Signed-off-by: Dilip Kota <c_dkota@codeaurora.org>
tty: n_smux: fix deadlock between RX and TX workers

smux_handle_rx_open_ack function acquires the channel state spin lock
and tries to add the channel into ready list causing spin lock lockup
between smux_rx_worker thread and smux_tx_worker thread running on
two different CPUs.

Add the channel to ready list after releasing the state spin lock.

CRs-Fixed: 514726
Change-Id: I11729290c5c28a13bed66cf7506b8aaf48a32d2a
Signed-off-by: Arun Kumar Neelakantam <aneela@codeaurora.org>
Merge "msm: display: Do not commit in unset for external."
msm: rotator: Wait for the pending commits in finish IOCTL

Due to asynchronuous rotator mechanism, sometimes the
MSM_ROTATOR_IOCTL_FINISH arrives before the previously queued
do_rotate work is completed. This causes fence to be signalled
before the buffer is used by rotator. In case of fast YUV 2 pass
scenario, this causes IOMMU page fault on 2 pass buffers, since
the buffer is unmapped when the rotator is still using it. Hence,
wait for the pending commit works to be finished before releasing
the fence and freeing the 2 pass buffers.

Change-Id: Iec9edd11406d102c7dd102c2ad7935184bbbba93
Signed-off-by: Padmanabhan Komanduru <pkomandu@codeaurora.org>
diag: Command registration not happening properly

Some CM command registrations are not happening properly
on apps side. This could be because some smd events
for control type were getting missed. Make changes
in order to read pending SMD packets for control
type.

Change-Id: I0fe25455275f6169bee91d151d8657330081c104
CRs-Fixed: 516718
Signed-off-by: Mohit Aggarwal <maggarwa@codeaurora.org>
Merge "tty: n_smux: fix deadlock between RX and TX workers"
sync: Limit logging to particular fence on timeout and error

Change-Id: I5bd7d62260666cdd2a32212f0e828d2d5d7d7bba
Signed-off-by: Prakash Kamliya <pkamliya@codeaurora.org>
Signed-off-by: Ananta Kishore K <akollipa@codeaurora.org>
Merge "radio: iris: Handle force close gracefully"
Merge "Bluetooth: Disable Sniff on HID ACL(s) if SCO is active"
Merge "diag: Command registration not happening properly"