video: msm: Allow DSI commands to timeout

 * Occasionally the power-off command will timeout even though the panel
   actually powers off. Call wait_for_completion with a timeout instead
   so we don't lock up.

Change-Id: I61f584371e7bb09eac654e1f6cadee5bc7b6e7f9
Revert "d2: Disable Samsung DVFS"

 * Not breaking anything in the kernel, but the userspace mpdecision
   needs it enabled.

This reverts commit fa22a73b7ebbd6543f18c0e28f63bdf3130df33c.
msm_fb: display: free dtv iommu buffer

Free iommu buffer after pipe is committed to hardware.

Change-Id: I00506d6fd55d99fec7921c02953fd755a7536d3e
Signed-off-by: Kuogee Hsieh <khsieh@codeaurora.org>
msm_fb: display: fix fake iommu buffer drop

During pipe free, some content of pipe is backed up and then after
pipe is zeroed out, the content get restored, in between there should
be no actions to change the content since any change will be wiped out
by the restore.

Change-Id: Ia6da0162d1f9b614682e1fc36edab1db003b42ab
Signed-off-by: Huaibin Yang <huaibiny@codeaurora.org>
msm_fb: display: add stage commit before kickoff to WFD

Since stage commit had been splited out of stage up fucnction,
it needed to be called to stage pipes into mixer befroe
kickoff mixer. Add this function into overlay writeback for WFD.

Change-Id: I11e4486d92b89a15e58531033d474b3137b5935a
Signed-off-by: Kuogee Hsieh <khsieh@codeaurora.org>

Conflicts:

	drivers/video/msm/mdp4_overlay.c
msm: kgsl: Fix a logical error in the gpu hang detection code

Change the GPU hang detection code to avoid the normal case is
mistakely treated as GPU hang scenario.

Cherrypicked from 50ec337976319844106e8da129244a7538604461

CRs-Fixed: 378488
Change-Id: I567c57911bb8683e561a70f95177518b4dd1df6d
Signed-off-by: Tarun Karra <tkarra@codeaurora.org>
video: msm: wfd: Delay fill_buffer until START_DONE

VCD requires we do not give any output buffers to be given until
START_DONE is received. In the case that buffers are given, it
introduces race conditions in the vidc with respect to the SPS/PPS
buffer, which vidc assumes to be present on the first fill_buffer but
actually isn't present until START_DONE.

Change-Id: Ie4dec3ed41e0f248175fb7d9719b458d3b699539
Signed-off-by: Deva Ramasubramanian <dramasub@codeaurora.org>
arm: Don't disable interrupts during WFE fixup

Disabling interrupts during the Krait WFE fixup can result
in deadlock if a thread tries to acquire a spinlock that is
released from an interrupt context. Instead of disabling
interrupts, modify the interrupt handler to reset the fixup
condition to put the processor into a safe state in the
event that the interrupt came in during the fixup window.

CRs-Fixed: 383670
Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
(cherry picked from commit 1fd137804b489f7a0b4103d846cda13a07e26cdf)

Change-Id: Ie6d1adc42cc0a68bbbaeaa35f18cdda074d66cd5
Signed-off-by: Srivalli Oguri <oguri@codeaurora.org>
 msm_fb: display: retrieve correct base layer pipe

Base layer pipe is cloned and cached at satge array.
Retrive the real base layer pipe before used it.

Signed-off-by: Kuogee Hsieh <khsieh@codeaurora.org>
(cherry picked from commit f44fbf21a8066016d441d742ad2386ee382cc603)

Change-Id: I2bffc3070c2a33d3c265dae968c1645a5a2e076c
Signed-off-by: Gopal G Goberu <ggober@codeaurora.org>
msm: iommu: Disable access to global registers

Global IOMMU registers are not accessible to Linux kernel and
should not be read or written to.

Add Kconfig option to turn on configuration of the global IOMMU
address space but leave default turned off.

Change-Id: I5be2efcb21a5245011607103c7b6a889c038db78
Signed-off-by: Olav Haugan <ohaugan@codeaurora.org>
Merge branch 'jb', remote-tracking branch 'cm/jellybean' into jb