PM / AVS: VP: add public API for using in SmartReflex

Some SmartReflex calibration algorithms require direct access to
Voltage Processor. Patch introduces the following API:
- int omap_vp_update_errorgain(struct device *v_dev, u8 errorgain);
- int omap_vp_enable(struct device *v_dev, u32 target_volt);
- void omap_vp_disable(struct device *v_dev);
- u32 omap_vp_get_voltage(struct device *v_dev);
- bool omap_vp_check_tranxdone(struct device *v_dev);
- void omap_vp_clear_tranxdone(struct device *v_dev);

Signed-off-by: Andrii Tseglytskyi <andrii.tseglytskyi@ti.com>
PM / AVS: VP: introduce irqsave lock for VP regmap

VP API function which retrieves current voltage is used
in atomic context - in SmartReflex interrupt handler, therefore
default regmap lock is not enough - it doesn't disable interrupts,
and it can't be used for synchronization between IRQ context
and kernel thread context where regulator_get_voltage() is typically
used. spin_lock_irqsave / spin_unlock_irqrestore functions should be
used here, otherwise a deadlock may occur.

Signed-off-by: Andrii Tseglytskyi <andrii.tseglytskyi@ti.com>
PM / AVS: SmartReflex: introduce SmartReflex Algorithms module

Now SmartReflex is designed to work without such abstraction
as "SmartReflex class". It is designed to choose appropriate
calibration algorithm, according to it settings retrieved from
device tree. Algorithms module is a container of calibration
logic. All algorithms are "private". The only API which is
exported is:

Init algorithms on boot:
- int sr_init_algs(struct omap_sr *sr);
- int sr_deinit_algs(struct omap_sr *sr);

"Getters" for calibration algorithms. Used for appropriate initialization
of driver callbacks, according to DTB parameters (calibration type,
voltage type and loop type).

sr_start_calibration_pfunc
sr_get_start_calibration_func(enum omap_sr_calibration_period period);

sr_stop_calibration_pfunc
sr_get_stop_calibration_func(enum omap_sr_calibration_period period);

sr_start_loop_pfunc
sr_get_start_loop_func(enum omap_sr_calibration_loop loop);

sr_stop_loop_pfunc
sr_get_stop_loop_func(enum omap_sr_calibration_loop loop);

Right now the following instances are implemented:
- Continuous claibration. Was used in class 3
- Periodic calibration. Was used in class 1.5
- HW calibration loop. Was used in class 3 and 1.5

Other algorithms are not covered by this patch.
Their implementation is pending. It will be introduced asap.

Signed-off-by: Andrii Tseglytskyi <andrii.tseglytskyi@ti.com>
PM / AVS: SmartReflex: start using Algorithms module

SmartReflex Algorithms is already introduced. Now it is
started to be used. Patch adds it appropriate initialization
and needed calls for calibration start/stop.

Signed-off-by: Andrii Tseglytskyi <andrii.tseglytskyi@ti.com>
PM / AVS: SmartReflex: sr_class is removed as useless

Since SmartReflex Algorithm module is started being used,
SmartReflex class is not needed any more. Now it usage is
removed from driver.

Signed-off-by: Andrii Tseglytskyi <andrii.tseglytskyi@ti.com>
ARM: dts: OMAP4430: add device node for AVS

Patch adds AVS device node definition for MPU voltagedomain.
Current DTB entry contains data to make SmartReflex working
as class 3.0 - continuous calibration, HW loop.

Signed-off-by: Andrii Tseglytskyi <andrii.tseglytskyi@ti.com>
TEST: call SmartReflex enable/disable during cpufreq tarnsition

Signed-off-by: Andrii Tseglytskyi <andrii.tseglytskyi@ti.com>
TEST: use SmartReflex supplier for cpufreq scaling

Signed-off-by: Andrii Tseglytskyi <andrii.tseglytskyi@ti.com>
TEST: introduce set voltage API for SmartReflex

Signed-off-by: Andrii Tseglytskyi <andrii.tseglytskyi@ti.com>
ARM: dts: OMAP4430: modify AVS to work as class 0

Signed-off-by: Andrii Tseglytskyi <andrii.tseglytskyi@ti.com>
Revert "ARM: dts: OMAP4430: modify AVS to work as class 0"

This reverts commit bc970d58a71ee6792035b6a65569b065db815031.
ARM: dts: OMAP4430: modify smartreflex_mpu device node for class 1.5

Patch adds needed data to make Smartreflex driver working as
class 1.5 - periodic calibration, HW loop

Signed-off-by: Andrii Tseglytskyi <andrii.tseglytskyi@ti.com>