ARM: smp: Make SMP operations mandatory

Now that all SMP platforms have been converted to use struct
smp_operations, remove the "weak" attribute from the hooks
in smp.c, and make the functions static wherever possible.

Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Acked-by: Nicolas Pitre <nico@linaro.org>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
ARM: smp: remove wrapper functions

Remove some silly wrapper functions which aren't really required:
	platform_smp_prepare_cpus
	platform_secondary_init
	platform_cpu_die

This simplifies the code.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
ARM: SoC: convert MSM to SMP operations

Convert MSM SMP platforms to use struct smp_operations to provide
their SMP and CPU hotplug operations.

[antypas@xda: Adapt to 8974/hammerhead]
[linflux@arcor.de: Minor cleanups]

Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Acked-by: Nicolas Pitre <nico@linaro.org>
Cc: David Brown <davidb@codeaurora.org>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
ASoC: wcd9xxx: Synchronize button press with notifiers

Button press handler and event notification handler needs
to be syncronized so that they do not interfere in the
excution leading to incorrect register writes or threshold
updates.

CRs-Fixed: 637805
Change-Id: I51ebf1d546aa59e219ce71517970b35730589b6c
Signed-off-by: Simmi Pateriya <simmip@codeaurora.org>
msm: camera: Avoid memory corruption by changing order of enum

SET_POSITION is added above MOVE_FOCUS which makes kernel prone to
memory corruption as MOVE_FOCUS enum is changed. when CFG_POSITION
is not present and userspace calls MOVE_FOCUS kernel misinterprets
MOVE_FOCUS as SET_POSITION and thus copies user structure to wrong
structure and makes memory to corrupt.

Change-Id: I335ee28d9af6ec25b00262d71701e503a06e21c5
Signed-off-by: Lokesh Kumar Aakulu <lkumar@codeaurora.org>
mmc: core: fix the issue with clock scaling in HS400 mode

Clock scaling feature would scale up/down the MMC interface clock
frequency based on the load on storage. During clock scale up in HS400
bus speed mode, SW is unncesserily doing the tuning even after HS400
switch is done. This change fixes this bug.

CRs-Fixed: 660534
Change-Id: I4de06962a3fe6dba2e7ff8420d9a3e3997b33ba1
Signed-off-by: Subhash Jadavani <subhashj@codeaurora.org>
camera: isp: create debug fs entry to log vfe overflows

Added entry in fs to log occurence of overflow from vfe

CRs-Fixed: 661343

Change-Id: Id398d11aaa84fca4ea63ea523c78c564c7eb6999
Signed-off-by: Katta Santhisindhu <kattas@codeaurora.org>
ARM: dts: msm: Update bus bandwidth votes for sdhci on 8974

Some versions of 8974 supports eMMC HS400 mode providing maximum
throughput of 400MB/s. Update the list of bus bandwidth votes to
make sure appropriate vote is placed in this mode.

CRs-fixed: 656702
Change-Id: I5e3bed70d8c8c1c6423483f7469849823e3ebb2c
Signed-off-by: Sujit Reddy Thumma <sthumma@codeaurora.org>
Signed-off-by: Asutosh Das <asutoshd@codeaurora.org>
ASoC: wcd9320: increase DMIC CLK drive-strength

Increase DMIC CLK drive-strength for WCD9320 codec from 2mA
to 4mA. This increase will improve setup and hold times for
DMICs in WCD9320 codec.

Change-Id: Id8603a994281b9c7f1a3eeb2d258ce2805f03575
Signed-off-by: Banajit Goswami <bgoswami@codeaurora.org>
Revert "[media] v4l2: vb2: one more fix for REQBUFS()"

This reverts commit 31901a078af29c33c736dcbf815656920e904632.

Queue should be reinitialized on each REQBUFS() call even if the memory
access method and buffer count have not been changed. The user might have
changed the format and if we go the short path introduced in that commit,
the memory buffer will not be reallocated to fit with new format.

The previous patch was just over-engineered optimization, which just
introduced a bug to videobuf2.

Reported-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
CC: Pawel Osciak <pawel@osciak.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>

Change-Id: I537d5dcc025a176111fefc4bcdad934266373573
Git-commit: bf7b73efb7f52abf56b512546c3bbc35001dd696
Git-repo: https://github.com/torvalds/linux.git
Signed-off-by: Pushkaraj Patil <ppatil@codeaurora.org>
msm: kgsl: Fix nice level for higher priority GPU start thread

Before, we were actually setting the lowest possible priority.
msm: kgsl: Schedule adreno_start in a high priority workqueue

Better safe than sorry. Also, return early if we didn't set a _wake_timeout.
msm: kgsl: when unmapping from the mmu flush the entire tlb

Flushes the entire tlb when calling mmu_unmap to make sure there
is no race condition between unmapping and freeing the pages.

Change-Id: I911f8479a3aef2006f9df40a3419284423937542
Signed-off-by: Shrenuj Bansal <shrenujb@codeaurora.org>
msm: kgsl: Add new API's to track device mutex owner

Add new API's kgsl_mutex_lock/unlock to track device mutex owner.
Mutex owner is an atomic variable and all operations set/clear on
it are also atomic to avoid any race conditions.

If a thread tries to acquire the mutex using new API, try to acquire
the mutex only if mutex owner is not same as current thread. This is
to prevent deadlocks which can happen if a thread tries to acquire
mutex with mutex held.

Change-Id: I3da4d0427ede5458f6a663043c57a4799b72d8fd
Signed-off-by: Tarun Karra <tkarra@codeaurora.org>