PM / OPP: Add OPP sharing information to OPP library
PM / OPP: Add OPP sharing information to OPP library

An opp can be shared by multiple devices, for example its very common
for CPUs to share the OPPs, i.e. when they share clock/voltage rails.

This patch adds support of shared OPPs to the OPP library.

Instead of a single device, dev_opp will now contain a list of devices
that use it. It also senses if the device (we are trying to initialize
OPPs for) shares OPPs with a device added earlier and in that case we
update the list of devices managed by OPPs instead of duplicating OPPs
again.

The same infrastructure will be used for the old OPP bindings, with
later patches.

Reviewed-by: Stephen Boyd <010521127f513270fe503d86ab8316ac5147f4b7@codeaurora.org>
Reviewed-by: Bartlomiej Zolnierkiewicz <24970bf3d8506c473367e9292a8e5eb43a40bda0@samsung.com>
Signed-off-by: Viresh Kumar <5ff32272b3d9f86512eddc8e0af523fc6f7924e5@linaro.org>
Signed-off-by: Rafael J. Wysocki <27ffc44a8ec6a212fba98cfc3246c6ce8ab131e0@intel.com>

KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs