dynamic fsync: add reboot notifier to force flush outstanding data

this should further prevent data corruption from kernel panics and
forced reboots

bump version to 1.2

Signed-off-by: Paul Reioux <reioux@gmail.com>
dynamic fsync: add kernel panic notifier to force flush outstanding data

more paranoia safety checks

Signed-off-by: Paul Reioux <reioux@gmail.com>
dynamic fsync: don't disable fdatasync()

Signed-off-by: Paul Reioux <reioux@gmail.com>
msm: kgsl: add Simple GPU governor. Original code and idea from @faux123. Current commit has some custom changes: eg. added the load history buffer to filter spikes and average the GPU scaling.

Signed-off-by: Francisco Franco <franciscofranco.1990@gmail.com>

Conflicts:

	drivers/gpu/msm/kgsl_pwrscale_trustzone.c
Revert "msm: kgsl: add Simple GPU governor. Original code and idea from @faux123. Current commit has some custom changes: eg. added the load history buffer to filter spikes and average the GPU scaling."

This reverts commit 14bcff8023a6219f50c3dea7bd7d00eb1fe6b453.

Conflicts:

	drivers/gpu/msm/kgsl_pwrscale_trustzone.c
msm: kgsl: Bump up the GPU frequency for long batch processing

Compute workloads run without kernel interaction for long periods
of time.  If one is identified early, increase the frequency to
finish it as fast as possible, rather than waiting for the standard
algorithm to do so.

Change-Id: I213ccabfae5e1000cdc34bc1d92bdc3bad86383d
CRs-Fixed: 441847
Signed-off-by: Lucille Sylvester <lsylvest@codeaurora.org>
Signed-off-by: Francisco Franco <franciscofranco.1990@gmail.com>

Conflicts:

	drivers/gpu/msm/kgsl_pwrscale_trustzone.c
msm: kgsl: re-add Simple Governor.

Signed-off-by: Francisco Franco <franciscofranco.1990@gmail.com>

Conflicts:

	drivers/gpu/msm/kgsl_pwrscale_trustzone.c
msm: kgsl: forgot to add the header for the Simple Governor on the latest revert and re-add.

Signed-off-by: Francisco Franco <franciscofranco.1990@gmail.com>
msm: kgsl: we don't need this routine anymore. We save CPU cycles not going through this small, now deleted, piece of code.

Signed-off-by: Francisco Franco <franciscofranco.1990@gmail.com>
msm: kgsl: use kgsl_mmu_device_setstate() if the GPU is already idle

Use the default setstate function, which directly reprograms the IOMMU,
to change IOMMU pagetables or flush the TLB if the GPU is already idle.
This condition often occurs when the GPU is being powered down. In this
case it is desirable to avoid the overhead of issuing commands, waiting
for idle and firing events that results from using the GPU
command stream to reprogram the IOMMU.

Change-Id: I633002ac49c8fe58df3f1f6a1fd1ddf705fc1733
Signed-off-by: Jeremy Gebben <jgebben@codeaurora.org>
Signed-off-by: Ajay Dudani <adudani@codeaurora.org>
Signed-off-by: Francisco Franco <franciscofranco.1990@gmail.com>
kgsl: add a new governor algorithm. Ditch the older Simple Governor to make place for Interactive. This name is chosen just to differentiate from the others, but it doesn't behave like the CPU governor Interactive. This uses a completely different algorithm to decide when to increase or decrease the GPU frequency. Also the functions tz_wake and tz_sleep don't do anything, they were a bit useless at this point after some testing.

Signed-off-by: Francisco Franco <franciscofranco.1990@gmail.com>
kgsl: add back content to the sleep function for this tz routine. Also fix the length of the governor name for the sysfs entry.

Signed-off-by: Francisco Franco <franciscofranco.1990@gmail.com>