powerpc/powernv: Add support for powercap framework

Adds a generic powercap framework to change the system powercap
inband through OPAL-OCC command/response interface.

Signed-off-by: Shilpasri G Bhat <shilpa.bhat@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
このコミットが含まれているのは:
Shilpasri G Bhat
2017-08-10 09:01:18 +05:30
committed by Michael Ellerman
コミット cb8b340de2
7個のファイルの変更290行の追加1行の削除

ファイルの表示

@@ -850,6 +850,9 @@ static int __init opal_init(void)
/* Initialise OPAL kmsg dumper for flushing console on panic */
opal_kmsg_init();
/* Initialise OPAL powercap interface */
opal_powercap_init();
return 0;
}
machine_subsys_initcall(powernv, opal_init);
@@ -966,6 +969,7 @@ int opal_error_code(int rc)
case OPAL_UNSUPPORTED: return -EIO;
case OPAL_HARDWARE: return -EIO;
case OPAL_INTERNAL_ERROR: return -EIO;
case OPAL_TIMEOUT: return -ETIMEDOUT;
default:
pr_err("%s: unexpected OPAL error %d\n", __func__, rc);
return -EIO;