d2: Enable FMEM in board files

Change-Id: I86b51659cf9321e75a242d187e781aebc7e63474
msm: tzcom: Vote for DFAB clock.

The secure processor does not have the capability to vote
for the DFAB clock. The vote for DFAB clock in HLOS ensures
that the secure processor does not freeze.

Change-Id: I580c92aea02dbfe6b47d593da71d7c779bf1ffa3
Signed-off-by: Ramesh Masavarapu <rameshm@codeaurora.org>
msm: dsps: Revise handling of PPSS_PAUSE register.

Only modify the PPSS_PAUSE register if the apps processor controls
the DSPS power state. The Linux kernel shouldn't modify the register
if the DSPS is in control of its own power state.

Also move the definition of the PPSS_PAUSE_REG address to the devices
file, since it may be different on different platforms.

CRs-Fixed: 370236
Signed-off-by: Karthik Karuppasamy <kkaruppa@codeaurora.org>
(cherry picked from commit 9dac549aa64d2d86a156a075de1656cfd38fc60a)

Conflicts:

	arch/arm/mach-msm/devices-msm8x60.c
	arch/arm/mach-msm/include/mach/msm_dsps.h
	arch/arm/mach-msm/msm_dsps.c

Change-Id: I6141df35639d77103d94c13e437161b0afe573d6
Signed-off-by: Srivalli Oguri <oguri@codeaurora.org>
(cherry picked from commit 74b4dae2862acadad22d91b530dbf3dce12dbebf)

Signed-off-by: Sudhir Sharma <sudsha@codeaurora.org>
fmem: interact properly with DMM

On a system with both FMEM and DMM, FMEM must veto
memory hotremove of section(s) FMEM occupies when
in C-state and allow it (after cleaning up metadata)
in T-state (and then change to O-state).

It must also change back to T-state when all sections
FMEM uses have been powered on.

Change-Id: I9766a07305d1e3e2c6ff48e1cbf6933765b751f8
Signed-off-by: Larry Bassel <lbassel@codeaurora.org>
fmem: hotplug notifier should do nothing if fmem is inactive

If fmem discovers it has no memory to manage, it will
stay in an uninitialized state. However, this is
not discovered until long after the hotplug notifier
is set up (which must be in the fmem_init function).

Since fmem has not been initialized, the hotplug notifier
runs and incorrectly causes memory hotremove to fail, as
it bases its decision on uninitialized data.

The fix is for the hotplug notifier to just return
immediately if fmem is in the uninitialized state.

Change-Id: Ia647470d64fe1926be404af419f5f516e6b59c05
Signed-off-by: Larry Bassel <lbassel@codeaurora.org>
fmem: add missing zcache_put after zcache_get

The code to flush all objects was missing a needed
zcache_put after a zcache_get.

Change-Id: I03ad33ee74b42567d8c0598bd5c2af7e455ca097
CRs-Fixed: 350617
Signed-off-by: Larry Bassel <lbassel@codeaurora.org>
FMEM: allocate non-fixed FMEM from memory pool

On platforms whose FMEM is not at a fixed place
and which don't have DMM (such as 7x27a), FMEM
and the EBI memory pool would incorrectly overlap,
and the same memory would be used both as FMEM
and as memory allocated by allocate_contiguous_memory()
at the same time leading to crashes and strange behavior.

There are some unsolved problems related to
allocating FMEM from unstable memory, so we have
decided not to do this any longer. This decision allows
us to simply allocate non-fixed FMEM from the
EBI memory pool (this will prevent FMEM's memory
from being used by another allocator at the same time).
In this case FMEM will appear to "overlap" with
the memory pool, but this now OK as FMEM is allocated
from it.

This also re-enables FMEM on 7x27a and 8625, which
had been disabled due to the above-mentioned bug.

CRs-Fixed: 354254
Change-Id: I8e0bba332c7ddcac1d280de9642078fdfe61bbcc
Signed-off-by: Larry Bassel <lbassel@codeaurora.org>

Conflicts:

	arch/arm/mach-msm/board-8960.c
	arch/arm/mach-msm/board-msm7x27a.c
	arch/arm/mach-msm/memory.c
d2: Import FMEM changes to board files

Change-Id: Ie47d4578c77be72704f431d0255aaf41bcfd197c
fmem: Use alignment property from platform data

Change-Id: I5d3e5f2c022937cd721befdd67a9d2f8f927608e
m2: fmem

Change-Id: I5bd5a32274e5e181b459fb124df7035a70f04622
msm_rotator: Update the rotator driver

Change-Id: Ic668cdc95be7151ec68e606095b0c627719e7bea
msm_fb: display: Assign proper destination rectangles to mdp blit

Add check for (90 + Flip Horizontal) and Flip Vertical cases to assign
proper destination rectangle parameters to avoid corrupted frame
buffer content.

CRs-Fixed: 344807
Change-Id: I7e7b0b8d26f08f63a6f9c55eedd37f31cf0348d7
Signed-off-by: Jeevan Shriram <jshriram@codeaurora.org>
msm_fb: Enable overlay downscale check for Samsung panel

Change-Id: Id2b002720bb9ca7c910a90462aa41b3fe0388652