kmemleak: Replace list_for_each_continue_rcu with new interface

This patch replaces list_for_each_continue_rcu() with
list_for_each_entry_continue_rcu() to save a few lines
of code and allow removing list_for_each_continue_rcu().

Change-Id: I134340bed0578d888762a2ff197c1b1c0e250ced
Signed-off-by: Michael Wang <wangyun@linux.vnet.ibm.com>
Acked-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
kmemleak: use rbtree instead of prio tree

kmemleak uses a tree where each node represents an allocated memory object
in order to quickly find out what object a given address is part of.
However, the objects don't overlap, so rbtrees are a better choice than
prio tree for this use.  They are both faster and have lower memory
overhead.

Tested by booting a kernel with kmemleak enabled, loading the
kmemleak_test module, and looking for the expected messages.

Change-Id: I0dce3bb7b8481da095fb21c450b16b59d6bd9129
Signed-off-by: Michel Lespinasse <walken@google.com>
Cc: Rik van Riel <riel@redhat.com>
Cc: Hillf Danton <dhillf@gmail.com>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Andrea Arcangeli <aarcange@redhat.com>
Cc: David Woodhouse <dwmw2@infradead.org>
Acked-by: Catalin Marinas <catalin.marinas@arm.com>
Tested-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
mm/kmemleak.c: remove obsolete simple_strtoul

Replace the obsolete simple_strtoul() with kstrtoul().

Change-Id: I295e5a2d2bb1a6db5a0476e0af5b8aef1e8289a5
Signed-off-by: Abhijit Pawar <abhi.c.pawar@gmail.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
msm: Fix high load average from uninterruptible waits

 * The load average on all MSMs is currently hovering at around 14
   due to uninterruptible waits in various places.
 * Convert these waits to interruptible waits to bring the load
   back down to zero at idle.

Change-Id: I14bad4af135b1594e235e2252cb484cb34d91054
cpufreq: ondemand: Remove unused waitqueue

Change-Id: Iee8bb3b319be81fd232e3acf392c9548fec71320
cpufreq: cpu-boost: Fix queue_delayed_work_on() race with hotplug

Calling queue_delayed_work_on() on a CPU that's in the process of getting
hotplugged out can result in that CPU infinitely looping in
msm_pm_wait_cpu_shutdown(). If queue_delayed_work_on() is called after the
CPU is hotplugged out, it could wake up the CPU without going through the
hotplug path and cause instability. To avoid this, make sure the CPU is and
stays online while queuing a work on it.

Signed-off-by: Saravana Kannan <skannan@codeaurora.org>

Conflicts:
	drivers/cpufreq/cpu-boost.c

Change-Id: I35bc30380f253bce39db22ad59af9258803e9735
cpufreq: cpu-boost: Remove unused waitqueue

Change-Id: I2e72d8ee5f2777bffe8d7817122934d8857c78b6
msm: mdss: On sharing dma pipe increment pipe ref_cnt

When DMA pipe is being shared and if mdss_mdp_pipe_map is called,
there could be a race condition when the pipe being shared
is unmapped, will lead to map failure as map is used for operations
on pipe which are already having positive ref_cnt.
This can result in potential map failure and attempt to free of
unmapped pipe resulting in crash.

Hence in this scenario of shared pipe usage atomic_inc should
be used instead of mdss_mdp_pipe_map.

CRs-Fixed: 590736
Change-Id: Ibaba20ac96662b5cd8aba3585f10d9cfe6e72d22
Signed-off-by: Justin Philip <jphili@codeaurora.org>
Revert "mdss: use a nonthreaded interrupt"

This reverts commit 0a1f6b2fc7ab80b8d0daf1ed77779c2d2b62e414.

Change-Id: Ie563172ae6a327b77bd5a8bb9be634231f625a7f
mm: fix anon vma naming

Fix two bugs caused by merging anon vma_naming, a typo in
mempolicy.c and a bad merge in sys.c.

Change-Id: Ia4ced447d50573e68195e95ea2f2b4d9456b8a90
Signed-off-by: Colin Cross <ccross@android.com>
gpu: ion: system_heap: add support for 2MB allocations

Enable 2MB (order 9) allocations from the system heap. This improves the
performance of some heavyweight use cases. The benefit is especially
large for use cases where the buffer is mapped into an IOMMU since we
can leverage the 2MB IOMMU page table mappings.

Change-Id: I869733089b9ccba8090bbca80aac7b5f248b335e
Signed-off-by: Mitchel Humpherys <mitchelh@codeaurora.org>
ion: use iounmap instead of __arm_iounmap

The API iounmap() is more generic and portable
than __arm_iounmap().

Change-Id: If9601e9266bec56442686d3f2bdb1d475cd7bead
Signed-off-by: Larry Bassel <lbassel@codeaurora.org>
ion: use PAGE_KERNEL instead of pgprot_kernel

The ion code uses PAGE_KERNEL (which is more generic than
pgprot_kernel) everywhere except in one place (so fix it).

Change-Id: I38fa1c682a3e04e9c8cb3cd25678094862fe8c9c
Signed-off-by: Larry Bassel <lbassel@codeaurora.org>
always use short version for kernel formatting

Change-Id: Ib57844dc0ef502d773ad8948639b749886647f22
Make the kernel tell it's nameless

Change-Id: I26af65861bf587ed73e0ef18647965ddadced9c9
msm: hotplug: Add MSM Hotplug driver
msm: hotplug: Max 1036MHz during screen off
msm: hotplug: Remove spinlock in load stats

It's too expensive and not nessecary.
msm: hotplug: Stop hotplug work a tad later
msm: hotplug: Schedule suspend/resume work

Dennis is right, this is the proper way to suspend and resume.