mali: cache and memory optimizations
Final cm11 kernel version
 block: Allow 0ms deadline latency, increase the read speed

 Change a timer compare from after to after-equals, thus allowing 0 timeout
 and making some of our schedulers FIFO.

Conflicts:
	block/bfq-iosched.c
	block/vr-iosched.c
Optimize kernel cfbfillrect function

This is a  patch to speed up the kernel
cfbfillrect function used for clearing the screen or filling an area
with a solid color.

The previous implementation was doing reads from the uncached framebuffer,
in certain circumstances, even for simple fills, which for performance
reasons, on most platforms, is ill-advised unless strictly necessary to
conform to the raster operation. In these circumstances, doing 64-bit
access on 64-bit systems does not serve much purpose except for probing
for corner-case bugs and race conditions in the hardware's framebuffer
bus implementation. On all systems, for 16bpp, it is better to take
advantage of write-combining features of the framebuffer and write a
half-word if required for the left and right edges.

Additionally, on most platforms, integer divides are relatively slow so are
best avoided, especially in inner loops.

This patch implements optimizations for 16bpp and 32bpp that avoid
framebuffer read operations during cfbfillrect if the raster-operation
is GXcopy. This applies to both 32-bit (BITS_PER_LONG) and 64-bit
systems (BITS_PER_LONG == 64). Although cfbfillrect is not usually a
bottleneck for the console text framebuffer (because regions filled
usually are aligned to a multiple of 2 or 4 x-coordinate and reads
are avoided), in some use-cases this patch could deliver a significant
speed-up.

Signed-off-by: Harm Hanemaaijer <fgenfb@yahoo.com>
Speed up console framebuffer imageblit function

Especially on platforms with a slower CPU but a relatively high
framebuffer fill bandwidth, like current ARM devices, the existing
console monochrome imageblit function used to draw console text is
suboptimal for common pixel depths such as 16bpp and 32bpp. The existing
code is quite general and can deal with several pixel depths. By creating
special case functions for 16bpp and 32bpp, by far the most common pixel
formats used on modern systems, a significant speed-up is attained
which can be readily felt on ARM-based devices like the Raspberry Pi
and the Allwinner platform, but should help any platform using the
fb layer.

The special case functions allow constant folding, eliminating a number
of instructions including divide operations, and allow the use of an
unrolled loop, eliminating instructions with a variable shift size,
reducing source memory access instructions, and eliminating excessive
branching. These unrolled loops also allow much better code optimization
by the C compiler. The code that selects which optimized variant is used
is also simplified, eliminating integer divide instructions.

The speed-up, measured by timing 'cat file.txt' in the console, varies
between 40% and 70%, when testing on the Raspberry Pi and Allwinner
ARM-based platforms, depending on font size and the pixel depth, with
the greater benefit for 32bpp.

Signed-off-by: Harm Hanemaaijer <fgenfb@yahoo.com>
max8997: silence kmsg spam when using cpu undervolting

Conflicts:
	drivers/regulator/max8997.c
ARM: mm: Recreate kernel mappings in early_paging_init()

This patch adds a step in the init sequence, in order to recreate
the kernel code/data page table mappings prior to full paging
initialization.  This is necessary on LPAE systems that run out of
a physical address space outside the 4G limit.  On these systems,
this implementation provides a machine descriptor hook that allows
the PHYS_OFFSET to be overridden in a machine specific fashion.

Cc: Russell King <linux@arm.linux.org.uk>

Acked-by: Nicolas Pitre <nico@linaro.org>
Signed-off-by: R Sricharan <r.sricharan@ti.com>
Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>

Conflicts:
	arch/arm/kernel/setup.c
ARM: cacheflush: split user cache-flushing into interruptible chunks

Flushing a large, non-faulting VMA from userspace can potentially result
in a long time spent flushing the cache line-by-line without preemption
occurring (in the case of CONFIG_PREEMPT=n).

Whilst this doesn't affect the stability of the system, it can certainly
affect the responsiveness and CPU availability for other tasks.

This patch splits up the user cacheflush code so that it flushes in
chunks of a page. After each chunk has been flushed, we may reschedule
if appropriate and, before processing the next chunk, we allow any
pending signals to be handled before resuming from where we left off.

Signed-off-by: Will Deacon <will.deacon@arm.com>

Conflicts:
	arch/arm/kernel/traps.c
CPU heat control: Set min heat to 65c and max to 70c.

Conflicts:
	arch/arm/mach-exynos/mach-u1.c
Add ram_console support.

- Revert use of phys_to_virt instead of ioremap in driver, since we're
  allocating the buffer in high memory where it's not direct mapped.
- Add reserve function to machine_desc to reserve ram_console memory.
- Place in the last 1 MB of RAM, in high memory.
- Exclude the final 4 kB for the kexec hardboot page.
Support copying of kernel tagged list (atags) in the decompressor.

This is needed to hardboot kexec a kernel with a new tags list (including a
new kernel command line), since the new atags would otherwise be lost with
the limited kernel memory mapping.  Without this patch, a hardboot-kexec'd
kernel uses the atags provided by the bootloader.
Support hard booting to a kexec kernel.

See KEXEC_HARDBOOT config option help for details.

Change-Id: If1a45732f1f10f28c44d179e0c7589968e146ac7

Conflicts:
	arch/arm/mach-exynos/include/mach/memory.h

Conflicts:
	arch/arm/kernel/machine_kexec.c

Conflicts:
	arch/arm/configs/cyanogenmod_n7100_defconfig
	arch/arm/configs/cyanogenmod_t0lte_defconfig
	arch/arm/mach-exynos/include/mach/memory.h