ARM: tegra: power: Restore cpufreq governor target

Restored cpufreq governor target frequency on exit from suspend.
Otherwise, CPU would stay at frequency set underneath the governor
by tegra driver on suspend entry.

Original-Change-Id: Iad96c7771bf89b78cdeb3e8f4e2c40b36e845b57
Reviewed-on: http://git-master/r/38390
Reviewed-by: Alex Courbot <acourbot@nvidia.com>
Tested-by: Alex Courbot <acourbot@nvidia.com>
Reviewed-by: Scott Williams <scwilliams@nvidia.com>
Reviewed-by: Narendra Damahe <ndamahe@nvidia.com>
Reviewed-by: Jin Qian <jqian@nvidia.com>
Reviewed-by: Yu-Huan Hsu <yhsu@nvidia.com>
ARM: tegra: clock: Change default sampling period to 12ms

Bug 845349

Original-Change-Id: I0ce1a5da9a80cea6a4e55bc92490e6ae8508e22f
Reviewed-on: http://git-master/r/39704
Tested-by: Thomas Cherry <tcherry@nvidia.com>
Reviewed-by: Aleksandr Frid <afrid@nvidia.com>
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
media: video: update copyright headers

update headers for camera files

bug 846086

Original-Change-Id: Id53c77ead17b569ad05c0a5b8ec7f2a5d1aef869
Reviewed-on: http://git-master/r/39102
Reviewed-by: Erik M Lilliebjerg <elilliebjerg@nvidia.com>
Reviewed-by: Abhinav Sinha <absinha@nvidia.com>
Reviewed-by: Michael Stewart <mstewart@nvidia.com>
Tested-by: Frank Chen <frankc@nvidia.com>
Reviewed-by: Jonathan Mayo <jmayo@nvidia.com>
arm: mfd/regulator: tps80031: Adding force_update for status register

The state register is read and write register, if read, it returned
current state, not current written value in register.
So if it want to write the value into state register, it must unconditional
write the value, don't use update(read and compare and then write).

Bug 838189

Original-Change-Id: I2555875a822f159e664b0834af2d00073c859acd
Signed-off-by: Jin Park <jinyoungp@nvidia.com>
Reviewed-on: http://git-master/r/38396
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
arm: tegra: pm269: Low power mode to unused vddio-gmi pins

Putting the unused vddio_gmi pins into the low power mode.

bug 833087

Original-Change-Id: I7595d011a61d5993fee167e89ed7eb204d5cb6b6
Reviewed-on: http://git-master/r/37877
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
Tested-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-by: Matthew Longnecker <mlongnecker@nvidia.com>
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
video: tegra: host: No S_IWGRP permission for sysfs attrbs

Removing write permission for Group and others for sysfs:
"null_kickoff_pid" attribute as CTS test "android.permission
.cts.FileSystemPermissionTest#testAllFilesInSysAreNotWritable"
requires it as non-writable.

Bug 828100

Original-Change-Id: Ifa2ee439a63f0503bf10f10f3cf31cd7c91c2842
Reviewed-on: http://git-master/r/39367
Tested-by: Manoj Gangwal <mgangwal@nvidia.com>
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
Reviewed-by: Sachin Nikam <snikam@nvidia.com>
arm: tegra: cardhu: correct rail_names in ina219_platform_data

Bug 844743

Original-Change-Id: I7538342b2a267540ee14ddd70e10d0d71618d46e
Reviewed-on: http://git-master/r/39527
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
Tested-by: Bharat Nihalani <bnihalani@nvidia.com>
Reviewed-by: Pritesh Raithatha <praithatha@nvidia.com>
Tested-by: Pritesh Raithatha <praithatha@nvidia.com>
Reviewed-by: Venu Byravarasu <vbyravarasu@nvidia.com>
mfd: tps80031: Update to new IRQ API

Original-Change-Id: Ic68fb22749dae71751c64326e0912d6267f1c886
Signed-off-by: Dan Willemsen <dwillemsen@nvidia.com>
regulator: tps80031: Fix build warning

Original-Change-Id: I0bcfd38569b9a9a1cc21d0e9d12a0d114d87be9c
Signed-off-by: Dan Willemsen <dwillemsen@nvidia.com>
backlight: tegra_pwm: Add backlight type

Original-Change-Id: I43036163f62c33f29c915fd4fe37ea10f71dfb55
Signed-off-by: Dan Willemsen <dwillemsen@nvidia.com>
input: touch: atmel_mxt_ts: Prevent boot and resume hangs.

Prevents touchscreen hangs during initial TS boot, and TS resume.

BUG 847725
BUG 845156
BUG 846711

Original-Change-Id: Ia853574e4b2422eb9368fe37eaf7457bd4022df8
Reviewed-on: http://git-master/r/40261
Reviewed-by: Varun Colbert <vcolbert@nvidia.com>
Tested-by: Varun Colbert <vcolbert@nvidia.com>
ARM: config: tegra3: Enable TPS80031, gpio reg

Signed-off-by: Dan Willemsen <dwillemsen@nvidia.com>
ARM: tegra3: defconfig: Enable CPU_IDLE support

Change-Id: Id286cb8ca33cde5df22d60cc83d2f29a41ca3d51
Signed-off-by: Scott Williams <scwilliams@nvidia.com>
Reviewed-on: http://git-master/r/47177
Reviewed-by: Daniel Willemsen <dwillemsen@nvidia.com>
Merge branch 'linux-tegra-nv-2.6.39' into android-tegra-nv-2.6.39

Conflicts:
	arch/arm/mach-tegra/board-enterprise-panel.c
	drivers/video/tegra/dc/dc.c

Signed-off-by: Dan Willemsen <dwillemsen@nvidia.com>
arm: tegra: add hdmi to earlysuspend

use FB_BLANK_POWERDOWN on hdmi device in earlysuspend to cause
tegra_dc_disable.
This change applies to enterprise,whistler and ventana.

Fixes bug 835171

Original-Change-Id: I792ab60344667acbdfcbd65a2ba697c2e7b59a78
Reviewed-on: http://git-master/r/35854
Reviewed-by: Niket Sirsi <nsirsi@nvidia.com>
Tested-by: Niket Sirsi <nsirsi@nvidia.com>
arm: config: Adding ina219 power mon configuration

Adding config variable for enabling INA219 power monitor.

bug 808311

Original-Change-Id: Ib2d59b14974f30643baf71ade01805f8043aee14
Reviewed-on: http://git-master/r/34300
Reviewed-by: Niket Sirsi <nsirsi@nvidia.com>
Tested-by: Niket Sirsi <nsirsi@nvidia.com>
ARM: config: tegra3_android: Enable TPS80031 PMU

Used by enterprise

Original-Change-Id: I8fd71cbb1fab8f176b3d42ae6f369fba2b904acd
Signed-off-by: Dan Willemsen <dwillemsen@nvidia.com>
cpufreq interactive governor: Update target frequency calculation

Updated target frequency calculation algorithm to take into account
current rate CPU is running at:

- When CPU is running below go_maxspeed_load threshold, adjust the
target frequency based on current rate to reach tunable sustainable
load (instead of applying cpu load to max possible cpu rate).

Tuned by setting new node ("0" falls back to using max_rate):
/sys/devices/system/cpu/cpufreq/interactive/sustain_load

- When CPU is running at/above go_maxspeed_load threshold, ramp the
target frequency starting from current exponentially with tunable base
(instead of immediate jump to maximum cpu rate).

Tuned by setting new node ("0" falls back to jump to max_rate):
/sys/devices/system/cpu/cpufreq/interactive/boost_factor

Defaults for the new tunning parameters are set to "0" - so no changes
in governor default behavior.

Original-Change-Id: Ie845d747239ba177e6f06b73965c3213649f8135
Reviewed-on: http://git-master/r/34583
Reviewed-by: Aleksandr Frid <afrid@nvidia.com>
Tested-by: Aleksandr Frid <afrid@nvidia.com>
Reviewed-by: Chih-Lung Huang <lhuang@nvidia.com>
Reviewed-by: Scott Williams <scwilliams@nvidia.com>
Reviewed-by: Narendra Damahe <ndamahe@nvidia.com>
Reviewed-by: Yu-Huan Hsu <yhsu@nvidia.com>
Reviewed-by: Diwakar Tundlam <dtundlam@nvidia.com>
Add ram console device to cardhu

ram console will buffer kmsg in reserved memory block, which
will be written to file /proc/last_ksmg on bootup.

Original-Change-Id: I6be8b9d22ce08040bbd95bf740a84b565e2300cf
Reviewed-on: http://git-master/r/37104
Tested-by: Alon Farchy <afarchy@nvidia.com>
Reviewed-by: Nitin Kumbhar <nkumbhar@nvidia.com>
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
arm: ventana: config: enable Hotplug

Enable the support for hotplug for ventana.

Bug 829628

Original-Change-Id: I947a238f9704081dfea257b6ffcf1d30269efa70
Reviewed-on: http://git-master/r/38699
Reviewed-by: Suresh Mangipudi <smangipudi@nvidia.com>
Tested-by: Suresh Mangipudi <smangipudi@nvidia.com>
Reviewed-by: Rakesh Bodla <rbodla@nvidia.com>
Tested-by: Gerrit_Virtual_Submit
Reviewed-by: Hanumanth Venkateswa Moganty <vmoganty@nvidia.com>
Reviewed-by: Narendra Damahe <ndamahe@nvidia.com>