Revert "Revert "git revert f88bf36f08Revert "Revert "cpufreq: interactive: Modifying sync_freq implementation""""

This reverts commit b171fc56127f8c60e50f80c8310554dd2e65e28c.
Revert "Revert "Revert "Revert "cpufreq: interactive: Fix null pointer dereference in interactive governor""""

This reverts commit 98c0caf7f9f0c53dd26129a6b92395c35a8c7173.
msm: acpuclock-krait: Init to max speed

There's no need to delay the boot process by running at slower
speeds, let's boot at max speed to get to the UI faster.

Change-Id: I4f07e8ff7a73ba8add17611bb0875a231ab5a568
Signed-off-by: Chris Fries <C.Fries@motorola.com>
Reviewed-on: http://gerrit.pcs.mot.com/531544
SLT-Approved: Slta Waiver <sltawvr@motorola.com>
Tested-by: Jira Key <jirakey@motorola.com>
Reviewed-by: Christopher Fries <qcf001@motorola.com>
Reviewed-by: Check Patch <CHEKPACH@motorola.com>
Reviewed-by: Klocwork kwcheck <klocwork-kwcheck@sourceforge.mot.com>
Reviewed-by: Igor Kovalenko <cik009@motorola.com>
Submit-Approved: Jira Key <jirakey@motorola.com>
[ljc: Adapt to use common ARCH_MSM8960]
Signed-off-by: Luis Cruz <ljc2491@gmail.com>

Conflicts:
	arch/arm/mach-msm/acpuclock-krait.c
msm: memutils:  memcpy, memmove, copy_page optimization

Preload farther to take advantage of the memory bus, and assume
64-byte cache lines.  Unroll some pairs of ldm/stm as well, for
unexplainable reasons.

Future enhancements should include,

- #define for how far to preload, possibly defined separately for
  memcpy, copy_*_user
- Tuning for misaligned buffers
- Tuning for memmove
- Tuning for small buffers
- Understanding mechanism behind ldm/stm unroll causing some gains
  in copy_to_user

BASELINE (msm8960pro):
======================================================================
memcpy 1000MB at 5MB       : took 808850 usec, bandwidth 1236.236 MB/s
copy_to_user 1000MB at 5MB : took 810071 usec, bandwidth 1234.234 MB/s
copy_from_user 1000MB at 5M: took 942926 usec, bandwidth 1060.060 MB/s
memmove 1000GB at 5MB      : took 848588 usec, bandwidth 1178.178 MB/s
copy_to_user 1000GB at 4kB : took 847916 usec, bandwidth 1179.179 MB/s
copy_from_user 1000GB at 4k: took 935113 usec, bandwidth 1069.069 MB/s
copy_page 1000GB at 4kB    : took 779459 usec, bandwidth 1282.282 MB/s

THIS PATCH:
======================================================================
memcpy 1000MB at 5MB       : took 346223 usec, bandwidth 2888.888 MB/s
copy_to_user 1000MB at 5MB : took 348084 usec, bandwidth 2872.872 MB/s
copy_from_user 1000MB at 5M: took 348176 usec, bandwidth 2872.872 MB/s
memmove 1000GB at 5MB      : took 348267 usec, bandwidth 2871.871 MB/s
copy_to_user 1000GB at 4kB : took 377018 usec, bandwidth 2652.652 MB/s
copy_from_user 1000GB at 4k: took 371829 usec, bandwidth 2689.689 MB/s
copy_page 1000GB at 4kB    : took 383763 usec, bandwidth 2605.605 MB/s

Change-Id: I5e7605d4fb5c8492cfe7a73629d0d0ce7afd1f37
Signed-off-by: Chris Fries <C.Fries@motorola.com>
Reviewed-on: http://gerrit.pcs.mot.com/526804
SLT-Approved: Gerrit Code Review <gerrit-blurdev@motorola.com>
Tested-by: Jira Key <jirakey@motorola.com>
Reviewed-by: Igor Kovalenko <cik009@motorola.com>
Submit-Approved: Jira Key <jirakey@motorola.com>

Conflicts:

	arch/arm/lib/Makefile
	arch/arm/mach-msm/Kconfig
	arch/arm/mach-msm/Makefile

Signed-off-by: Luis Cruz <ljc2491@gmail.com>

Conflicts:
	arch/arm/mach-msm/Makefile
msm: memutils: memcpy, memmove optimization

1. To fit 8x26 64-bytes cache line size, we change preload steps as 64Bytes.
2. According to tune result, change preload distance as 5 cache lines.
3. According to tune result, re-arrange the ld/str order as back-to-back
   for copy_from_user.

The markable improvement:
	memcpy : 5%
	copy_to_user : 9%
	copy_from_user : 13%
	memmove : 37%

Raw data is as below:

BASELINE:
	memcpy 1000MB at 5MB       : took 1547098 usec, bandwidth 646.646 MB/s
	copy_to_user 1000MB at 5MB : took 1704308 usec, bandwidth 586.586 MB/s
	copy_from_user 1000MB at 5M: took 1777090 usec, bandwidth 562.562 MB/s
	memmove 1000GB at 5MB      : took 1066205 usec, bandwidth 937.937 MB/s
	copy_to_user 1000GB at 4kB : took 1774866 usec, bandwidth 563.563 MB/s
	copy_from_user 1000GB at 4k: took 1797654 usec, bandwidth 556.556 MB/s
	copy_page 1000GB at 4kB    : took 1644606 usec, bandwidth 608.608 MB/s
	memmove 1000GB at 4kB      : took 1236227 usec, bandwidth 808.808 MB/s

THIS PATCH:
	memcpy 1000MB at 5MB       : took 1475835 usec, bandwidth 677.677 MB/s
	copy_to_user 1000MB at 5MB : took 1559060 usec, bandwidth 641.641 MB/s
	copy_from_user 1000MB at 5M: took 1561603 usec, bandwidth 640.640 MB/s
	memmove 1000GB at 5MB      : took 861664 usec, bandwidth 1160.160 MB/s
	copy_to_user 1000GB at 4kB : took 1673501 usec, bandwidth 597.597 MB/s
	copy_from_user 1000GB at 4k: took 1674006 usec, bandwidth 597.597 MB/s
	copy_page 1000GB at 4kB    : took 1691358 usec, bandwidth 591.591 MB/s
	memmove 1000GB at 4kB      : took 882985 usec, bandwidth 1132.132 MB/s

Change-Id: I83bec3b7a9dd9cd88890eaa7ec423363e230a651
Signed-off-by: Hong-Mei Li <a21834@motorola.com>
Reviewed-on: http://gerrit.pcs.mot.com/550383
SLT-Approved: Slta Waiver <sltawvr@motorola.com>
Tested-by: Jira Key <jirakey@motorola.com>
Reviewed-by: Klocwork kwcheck <klocwork-kwcheck@sourceforge.mot.com>
Reviewed-by: Check Patch <CHEKPACH@motorola.com>
Reviewed-by: Yi-Wei Zhao <gbjc64@motorola.com>
Submit-Approved: Jira Key <jirakey@motorola.com>
Signed-off-by: Luis Cruz <ljc2491@gmail.com>
ARM: smp: Wait just 1 second for other CPU to halt

Currently, the busyloop waiting for a 2nd CPU to stop takes about 4
seconds.  Adjust for the overhead of the loop by looping every 1ms
instead of 1us.

Change-Id: If04a4dc16425fff3898233eea2a0fff95f5db287
Signed-off-by: Chris Fries <C.Fries@motorola.com>
Reviewed-on: http://gerrit.pcs.mot.com/537864
SLT-Approved: Slta Waiver <sltawvr@motorola.com>
Tested-by: Jira Key <jirakey@motorola.com>
Reviewed-by: Check Patch <CHEKPACH@motorola.com>
Reviewed-by: Klocwork kwcheck <klocwork-kwcheck@sourceforge.mot.com>
Reviewed-by: Igor Kovalenko <cik009@motorola.com>
Reviewed-by: Russell Knize <rknize2@motorola.com>
Submit-Approved: Jira Key <jirakey@motorola.com>
Signed-off-by: Luis Cruz <ljc2491@gmail.com>
Add in SLQB allocator, fix depecated functions within, an add a few missing includes (A heavily modified cherry-pick)

Conflicts:
	include/linux/rcupdate.h
	include/linux/slab.h

Conflicts:
	include/linux/slab.h
Add 480MHz GPU OC step
Fix an error with GPU OC
Add SmartassH3 gov

Conflicts:
	drivers/cpufreq/Kconfig
	drivers/cpufreq/Makefile
	include/linux/cpufreq.h
input: glorious touchkey backlight animation

- Change 8921_l10 configuration to expose full LDO regulator limits
- Add a trivial interface to reduce 8921_l10 voltage
- Add toggleable animation code for brightness changes
- Add hacky backlight brightness adjustment
- Break suspend sequence up to avoid waiting 500ms for the animation
- Probably break BLN; sorry, jt1134

Conflicts:
	arch/arm/mach-msm/board-8960-regulator.c
	arch/arm/mach-msm/board-m2_spr.c
	drivers/input/keyboard/cypress_touchkey_236/cypress-touchkey-236.c
input: fix touchkey IRQ toggling

The previous code left the IRQ enabled longer than it should have,
resulting in useless inputs after the screen was long since blank.
Disable IRQs early, but wait until the off animation is actually
complete before finally cutting power.
input: fixups for touchkey animation

 - Fix up suspend/resume sequence
 - Change gamma for animation LUT
 - Remove animation enable knob
 - Replace gattr brightness knob with device attr (range 0..255)

Conflicts:
	drivers/input/keyboard/cypress_touchkey_236/cypress-touchkey-236.c
input: make touchkey leds behave as expected

 - don't turn off on our own
 - only turn on during resume when enabled during suspend
 - only calculate animation parameters once

This fixes the last of the bugs I'm aware of.  Disabling touchkeys
works, on/off/on animation works correctly.
input: touchkeys: fix an obvious deadlock
PING: Fix struct incompatibility for both IPv4 and IPv6
Bluetooth: Fix incompatible sizeof reference
Cypress: Fix incompatible sizeof reference

Conflicts:
	drivers/input/keyboard/cypress_touchkey_236/cypress-touchkey-236.c
Fix a few compiler warnings

Conflicts:
	arch/arm/mach-msm/cpufreq.c
	drivers/cpufreq/cpufreq.c
More compiler fixes