Undervolt: clean it up, make it elegant and remove the constrain of fixed set of NUM_FREQS - its not dynamic based on the number of freqs used for scaling via an external function.

Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
Signed-off-by: Andreas Pohl <apohl79@gmail.com>
Undervolt: few minor changes, mostly for clarity.

Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
Signed-off-by: Andreas Pohl <apohl79@gmail.com>
board: mako-regulator: decrease voltage requirements.

Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
Signed-off-by: Andreas Pohl <apohl79@gmail.com>
msm: acpuclock-krait: NULL terminate L2 table for find_cur_l2_level()

find_cur_l2_level() assumes that the L2 table is NULL terminated
when it has never been terminated. Therefore, if the rate that is
read from the hardware during boot is not found in the table we
will run off the end of the table and read potential junk values.
NULL terminate all the L2 tables so that the loop in
find_cur_l2_level() is guaranteed to terminate.

Change-Id: Ia5d0213000b44def35e388fd3cadf0293344257b
Reported-by: Laura Abbot <lauraa@codeaurora.org>
Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
Signed-off-by: Andreas Pohl <apohl79@gmail.com>
msm: acpuclock-krait: Keep the secondary MUX input fixed

With use of the QSB clock source recently eliminated, only one
input of the secondary clock MUX is used on any target. Since
there is overhead involved reprogramming this MUX when changing
the CPU and L2 frequencies, change the code to just program the
MUX at boot.  Most noticeably, this removes a 1us delay from
every CPU and L2 frequency switch.

Change-Id: I5cd8c981f1be49be7dbba1310d84df439e8be83b
Signed-off-by: Matt Wagantall <mattw@codeaurora.org>
Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
Signed-off-by: Andreas Pohl <apohl79@gmail.com>
msm: acpuclock-8064: Lower VDD_DIG voltage vote for L2 at 384MHz

New characterization data shows that vdd_dig voltage for L2@384MHz
can be lowered to 0.95v. Update the data in this patch.

Change-Id: Ibdb8568eca4d4ed602c5a5fee2f433a098dfbdcd
Signed-off-by: Tianyi Gou <tgou@codeaurora.org>
Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
Signed-off-by: Andreas Pohl <apohl79@gmail.com>
mach-msm: re-organize the freq table.

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

Conflicts:

	arch/arm/mach-msm/acpuclock-8064.c
mach-msm: fix L2 tables.

Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
Signed-off-by: Andreas Pohl <apohl79@gmail.com>
cpufreq: conservative: tune for performance.

Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
Signed-off-by: Andreas Pohl <apohl79@gmail.com>
PM / cpufreq: Initialise the cpu field during conservative governor start

This change initialises the cpu id field of cs_cpu_dbs_info structure in
conservative governor and keep this consistent with other governors.
Similar initialisation is present in ondemand governor.

Signed-off-by: Amit Daniel Kachhap <amit.daniel@samsung.com>
Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
Signed-off-by: Andreas Pohl <apohl79@gmail.com>
cpufreq: conservative: update frequency when limits are relaxed

Reevaluate CPU load and update frequency immediately whenever limits
are changed. Currently conservative doesn't do that when limits are
relaxed, wasting power on systems with relatively low sampling rate.

Signed-off-by: Michal Pecio <mpecio@nvidia.com>
Reviewed-by: Thomas Renninger <trenn@suse.de>
Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
Signed-off-by: Andreas Pohl <apohl79@gmail.com>
Config: Activated conservative govenor

Signed-off-by: Andreas Pohl <apohl79@gmail.com>
drivers: otg: Activate USB fast_charge by default

Signed-off-by: Andreas Pohl <apohl79@gmail.com>