blu_plug: Dynamic hotplug driver for hammerhead
Squashed, based on dyn_hotplug by stratosk
Improvements, fixes, changes and ported to hammerhead by eng.stk <eng.stk@sapo.pt>

Signed-off-by: Stefanescu Cristian <howerkraft@gmail.com>

Conflicts:
	arch/arm/mach-msm/Makefile
defconfig: enable blu_hotplug

Signed-off-by: Stefanescu Cristian <howerkraft@gmail.com>
sched/cpuidle: reduce IPI store. Backport upstream 3.16 scheduler updates

Signed-off-by: Paul Reioux <reioux@gmail.com>
Signed-off-by: Stefanescu Cristian <howerkraft@gmail.com>
sched/fair: Optimize find_busiest_queue()

Use for_each_cpu_and() and thereby avoid computing the capacity for
CPUs we know we're not interested in.

Reviewed-by: Paul Turner <pjt@google.com>
Reviewed-by: Preeti U Murthy <preeti@linux.vnet.ibm.com>
Signed-off-by: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/n/tip-lppceyv6kb3a19g8spmrn20b@git.kernel.org
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Signed-off-by: Paul Reioux <reioux@gmail.com>

backported for Linux 3.4

Signed-off-by: Stefanescu Cristian <howerkraft@gmail.com>

Conflicts:
	kernel/sched/fair.c

Signed-off-by: Stefanescu Cristian <howerkraft@gmail.com>
sched/fair: Optimize cgroup pick_next_task_fair()

Since commit 2f36825b1 ("sched: Next buddy hint on sleep and preempt
path") it is likely we pick a new task from the same cgroup, doing a put
and then set on all intermediate entities is a waste of time, so try to
avoid this.

Measured using:

  mount nodev /cgroup -t cgroup -o cpu
  cd /cgroup
  mkdir a; cd a
  mkdir b; cd b
  mkdir c; cd c
  echo $$ > tasks
  perf stat --repeat 10 -- taskset 1 perf bench sched pipe

PRE :      4.542422684 seconds time elapsed   ( +-  0.33% )
POST:      4.389409991 seconds time elapsed   ( +-  0.32% )

Which shows a significant improvement of ~3.5%

Signed-off-by: Peter Zijlstra <peterz@infradead.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Tejun Heo <tj@kernel.org>
Link: http://lkml.kernel.org/r/1328936700.2476.17.camel@laptop
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Signed-off-by: Paul Reioux <reioux@gmail.com>

Backported for Linux 3.4 kernel

Signed-off-by: Stefanescu Cristian <howerkraft@gmail.com>

Conflicts:
	kernel/sched/fair.c

Signed-off-by: Stefanescu Cristian <howerkraft@gmail.com>
fastcharge: initial Nexus 5 adaptation

added custom charge levels for better control over fastcharge

Signed-off-by: Paul Reioux <reioux@gmail.com>
Signed-off-by: Stefanescu Cristian <howerkraft@gmail.com>

Conflicts:
	arch/arm/mach-msm/Kconfig
	arch/arm/mach-msm/Makefile
	arch/arm/mach-msm/fastchg.c
	drivers/power/bq24192_charger.c
	drivers/usb/dwc3/dwc3_otg.c
	include/linux/fastchg.h
fastcharge: increase battery charging current to use higher input current

Signed-off-by: Paul Reioux <reioux@gmail.com>
Signed-off-by: Stefanescu Cristian <howerkraft@gmail.com>

Conflicts:
	drivers/power/bq24192_charger.c
blu_plug: enable by default

Signed-off-by: Stefanescu Cristian <howerkraft@gmail.com>
mako_hotplug: lets try this fix for the crippling sound when changing networks.

Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
Signed-off-by: Stefanescu Cristian <howerkraft@gmail.com>