USB: Force Fast Charge

A simple sysfs interface to force adapters that are detected as USB to
charge as AC.
OMAP4 Thermal Framework: added PCB temperature sensor

This patch adds kernel driver for PCB temperature sensor
connected on TWL6030 GPADC (Thermistor).
It calls dedicated function to start GPADC conversion and
convert the result into milli-degrees celsius.

Change-Id: I7b573182611bda187f6a38dc01ba65935c8a5c4b
Signed-off-by: Sebastien Sabatier <s-sabatier1@ti.com>
modified for TUNA board by faux123
OMAP4470: TEMP_SENSOR: Fatal threshold hardware warm reset generation

On 4470 the TSHUT signal can be mapped to the device SCRM external
warm reset logic to activate the PRM.SYS_WARMIN_RST input
when a fatal temperature threshold (TSHUT_HOT) is exceeded.
Hence, a hardware warm reset can be triggered directly on
the device upon a fatal temperature threshold crossing event.

Since this feature have been added for 4470, shutdown thresholds
can be set earlier. So, additional checking has been added to prevent
multiple writing to one time writable register.

Also this patch add corresponding sysfs debug hook functions to
enable/disable hardware reset feature.

Change-Id: I260e16e2808fddc0ecb06211a74aced8c4b12a5d
Signed-off-by: Leonid Iziumtsev <x0153368@ti.com>

Conflicts:
	drivers/staging/thermal_framework/sensor/omap_temp_sensor.c
OMAP4470: TEMP_SENSOR: Thermal sensor support for 4470

OMAP4470: TEMP_SENSOR: Thermal sensor support for 4470

Thermal sensor support is required by a new chip.

Add runtime checking for 4470 to allow usage of
thermal sensor.

Change-Id: I231826df11315a27d6174a8791c578a5abbb4257
Signed-off-by: Leonid Iziumtsev <x0153368@ti.com>
Thermal Governor: Added duty cycle governor

Add the OMAP duty cycle governor to the thermal framework.
This component will impose the policy for the PCB temp
sensor in case ondie sensor is absent.

Change-Id: I05f7272445567cf74be6f0932d7024f0d9d34dee
Signed-off-by: Eugen Mandrenko <ievgen.mandrenko@ti.com>
modified for TUNA board by faux123
fix commit
temp sensor: fix code merge errors
board/omap2plus: add missing thermal framework code from OMAPZOOM.org baseline
DRIVERS: MISC: change the DC cpufreq control to TF control

Duty cycle uses sys fs to control cpufreq. It is not safe.
The user(overclocker) can burn the device using simple script that
changes max_frequency. The thermal framework has own mechanism for
this and the patch changes the duty cycle mechanism to thermal
framework variant of cpufreq control.

Change-Id: Ifc0f8b81addb7524eb67d116e4780978739a67f3
Signed-off-by: Eugen Mandrenko <ievgen.mandrenko@ti.com>
modified for TUNA board by faux123
board/omap2plus: fix duty cycle cooling coding error
TI thermal framework: register cpufreq cooling device in module init

TI thermal framework: register cpufreq cooling device in module init

the CPUfreq cooling device is being registered in the wrong place.
We don't want to register a cooling device every time a CPU is
initialized. This is fundamentally wrong. Thus, this patch moves
the cooling device registration to module init instead.

Change-Id: I7886eb14c68e1bf696ef77e86326a62ea05b8c8b
Signed-off-by: Eduardo Valentin <eduardo.valentin@ti.com>
TI thermal framework: rework initialization sequence

TI thermal framework: rework initialization sequence

The duty cooling device is being registered in the
wrong place. We don't want to register a cooling device
every time a CPU is initialized.  Thus, this patch moves
the cooling device registration to module init instead.

Change-Id: Ib3cf55e8dde719c5736b201d9682ff515d2b1399
Signed-off-by: Eugen Mandrenko <ievgen.mandrenko@ti.com>
Signed-off-by: Eduardo Valentin <eduardo.valentin@ti.com>
omap4: add 4430 ES2.3 support

omap4: add 4430 ES2.3 support

And default to 4430 ES2.3 for unidentified silicon.

Change-Id: I06b0aa9c5f33af25345996cf9d0c994491093096
Signed-off-by: Anand Gadiyar <gadiyar@ti.com>
OMAP4: ID: Chip detection for OMAP4470

Add support for detection of the next chip in the OMAP4 family: OMAP4470 ES1.0

Change-Id: I931d3df6e69fdc3ee4a307c204a68fc9b3ff519b
Signed-off-by: Leonid Iziumtsev <x0153368@ti.com>
modified by faux123
Revert "temp sensor: fix code merge errors"

This reverts commit ccb532cccc6dbb4e7130bf0745a576767a84532e.
ARM: OMAP4: EMIF: implementation of errata i735 for PM timer

EMIF Power Management timer for Self Refresh will put the external SDRAM
in Self Refresh mode after the EMIF is idle for number of DDR clock cycles
that is set with REG_SR_TIM. The minimal value starts at 16 cycles.
However due to Errata i735, the minimal value is 512 DDR cycles as it is
required at OPP100 frequency.

Change-Id: If0748903580877aa4c1803f47e9134ee60c1dd75
Signed-off-by: Konstantyn Shlyakhovoy <x0155534@ti.com>
modified for tuna by faux123
OMAP4: HSOTG: Improved HSOTG USB EYE diagram

1. Added the ability to improve HSOTG USB EYE diagram.

 solution #1: (all 44XX CPUs family)
   Improvement of 2-3% in EYE diagram opening by playing slightly on USB
   driver output impedance.

 solution #2: (4430 CPUs)
   Improvement of up to 8% in EYE diagram opening has been accomplished by
   decreasing the internal termination impedance by increasing the SWCAP
   trim code in USBPHY_USB2PHYCM_TRIM register to 0x24.

2. Added menuconfig option for this feature:
   'System Type'--->'OMAP 44XX HSOTG Eye diagram correction'

Change-Id: Ifd0450e8eeea57e6f68d1e166fe878a39ce52f71
Signed-off-by: Volodymyr Riazantsev <x0153367@ti.com>
Signed-off-by: Ruslan Bilovol <ruslan.bilovol@ti.com>
modified for tuna by faux123
OMAP4: HSOTG: Improved HSOTG USB EYE diagram for 4460 and 4470 CPUs

OMAP4: HSOTG: Improved HSOTG USB EYE diagram for 4460 and 4470 CPUs

Added 10-15mV adjustable improvement for 4460 and 4470 CPUs

Change-Id: If12eac91f5244bc8fa25ae7adb750ea47515c0f8
Signed-off-by: Ruslan Bilovol <ruslan.bilovol@ti.com>
omap: Adding opp functions to gpu platform data.

omap: Adding opp functions to gpu platform data.

This is required for providing opp framework access to SGX kernel module.

Change-Id: Ie968a6c51ac636b70909257be4c51430c4cc3d48
Signed-off-by: Rogelio Garcia <rgarcia@ti.com>
ARM: OMAP4460: Fixed missing dependency map of OPP for iva

ARM: OMAP4460: Fixed missing dependency map of OPP for iva

Added missing dependency map of OPP-Nitro and OPP-SpeedBin for iva.
Without this line setting IVA into high OPP fail with errors:

rpres iva.0: _dep_scan_table: 1375000 volt map missing in vdd_core
rpres iva.0: omap_device_scale: Error in scan domains for vdd_iva

Change-Id: I73df4897e886a2d4c9fa22abcbc8a6f34c2a8503
Signed-off-by: Vitaly Chernooky <vitaly.chernooky@ti.com>