msm: camera: Add NULL check for stats_buf

Return error in case stat_buf is NULL in the list

CRs-Fixed: 436229
Change-Id: I42b2f61dc8e6c9e9883d0bd5d7531d62b5f0fb99
Signed-off-by: Raju P.L.S.S.S.N <rplsssn@codeaurora.org>
msm: apq8064: remove device registration of touchscreen FET on MTP

This power FET does not exist on apq8064 MTP and registration of
its platform device conflicts with usage of pmic gpio-23 for other
purposes on the MTP target.

Change-Id: I37d679ea9d984579ebb27d3acd6002d4d579c9b4
Signed-off-by: Joel King <joelking@codeaurora.org>
msm: sglte2: prevent early bootup of the external qsc modem

The gpio connection to the KPD_PWR_N pin of the external qsc modem
is not inverted as it was in previous sglte targets so configuring
the gpio LOW initially was causing the qsc modem to boot up too
early. Change the configuration to HIGH and set the platform data
flag that tells the mdm driver that this connection is not inverted.

Change-Id: I240f056443aa2eb2fb2bfa192894054b610e91ff
Signed-off-by: Joel King <joelking@codeaurora.org>
msm: mdm: add a parameter for the name used to register for SSR

The name that that mdm driver uses to register with SSR is used
by other drivers to register for notifications, so it must be a
system-wide, known string. The mdm driver was previously generating
an arbitrary string that only it knew about. The name needs to be
passed to the mdm driver instead of it being auto-generated.

Change-Id: If8dab185b5599e95f2087bab97d48e5c72311279
Signed-off-by: Joel King <joelking@codeaurora.org>
msm: camera: Add proper camera close sequence

Update camera driver to handle closing sequence properly
when there is a crash in userspace threads to restart
camera again.

Change-Id: Ic1956975fd18d262e9cf503055fb09d391f8c7d7
CRs-Fixed: 467053
Signed-off-by: Suresh Vankadara <svankada@codeaurora.org>
msm: ipc: Security updates to IPC Router

In order to provide fine-grained access control to QMI services,
a security script from user-space will feed the security rules to
IPC Router. The security rule implies that in order to send a QMI
message to a service, a client process should belong to a specific
Linux/Android group. IPC Router, after receiving the security rules,
will enforce the access control rules.

Change-Id: I49f8d7c0067fc37cb0b4de2ccb46a575905ef64f
Signed-off-by: Karthikeyan Ramasubramanian <kramasub@codeaurora.org>
msm: ipc: Allow QMI clients to send messages after IRSC is complete

Currently there exists a small time interval during initialization
where QMI clients in user-space can communicate with QMI services
before the IPC Router Security Configuration(IRSC) is complete.

Only allow clients to communicate after IRSC is complete.

Change-Id: I773ad5b3cb02c51a725cd60a77466876c1498b64
Signed-off-by: Karthikeyan Ramasubramanian <kramasub@codeaurora.org>
msm: ipc: Security updates to IPC Router

With the fine-grained access control in place for QMI clients, default
security check in socket create operation is redundant. Update the
IPC Router to perform the default security check only for the
bind operation, which is used during QMI service registration.

Change-Id: I967dbc3d414d39d307c071ff49c319828b5ed19e
Signed-off-by: Karthikeyan Ramasubramanian <kramasub@codeaurora.org>
ASoC: WCD9304: Fix Headphone + Lineout concurrent audio playback

During concurrent playback on headphone and lineout, it is observed that
headphone is enabled in class G mode. This causes incorrect routing to
lineout. Fix by making sure headphone does not operate in class G mode
when there is concurrent playback on headphone and lineout.

CRs-fixed: 421247
Change-Id: Ib1f38deb453d6dbbcf86f69a117e6dc812b61546
Signed-off-by: Bhalchandra Gajare <gajare@codeaurora.org>
ASoC: Avoid putting stream state to STOP when stream paused

When multiple Front-end are using the same Back-end, putting
the stream state for a Front-end to STOP will make the the Backend
stream to be released, when the front-end is paused. This will avoid
the Backend to be released (when another active front-end stream is
present).
Instead, put the stream state to PAUSED, which will keep the Back-end
ON.

Change-Id: Ic31bf90a09b605b91f6b9fe3c09361b1145581fb
CRs-fixed: 428825
Signed-off-by: Banajit Goswami <bgoswa@codeaurora.org>
ASoC: wcd9310: Disable Mic Bias Pull down prior to enable micbias

Pull down Mic Bias and add a delay of 250ms to avoid issue
of something else pulling up the mic voltage other than mbhc
polling prior to enable micbias when recording starts.

CRs-fixed: 431573
Signed-off-by: Simmi Pateriya <simmip@codeaurora.org>
(cherry picked from commit 1b9a309c9a58bfd47d0e6dee75cfd6fea12e0760)

Change-Id: I575cc61c1f0d9956958768f8852b87695bb2211c
Signed-off-by: Sivasri Kumar Vanka <sivasri@codeaurora.org>
nl80211/cfg80211: add VHT MCS support

Add support for reporting and calculating VHT MCSes.

Note that I'm not completely sure that the bitrate
calculations are correct, nor that they can't be
simplified.

Change-Id: Id4c132850a85ff59f0fc16396763ed717689bec0
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Git-commit: db9c64cf8d9d3fcbc34b09d037f266d1fc9f928c
Git-repo:
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
Signed-off-by: Sameer Thalappil <sameert@codeaurora.org>
msm: vidc: Fix possible memory corruption

This change fix the possible memory corruption
by increasing the local array sizes in video
encoder.

Change-Id: If03cee2f428c3cef863178da70bc083159f203f5
Signed-off-by: Maheshwar Ajja <majja@codeaurora.org>