pub fn cppc_read(cppc_reg_id: u32) -> SbiRetExpand description
Read the CPPC register identified by given cppc_reg_id.
§Parameters
The cppc_reg_id parameter specifies the CPPC register ID.
§Return value
SbiRet.value will contain the register value. When supervisor mode XLEN is 32, the SbiRet.value
will only contain the lower 32 bits of the CPPC register value.
The possible error codes returned in SbiRet.error are shown in the table below:
| Return code | Description |
|---|---|
SbiRet::success() | Read completed successfully. |
SbiRet::invalid_param() | cppc_reg_id is reserved. |
SbiRet::not_supported() | cppc_reg_id is not implemented by the platform. |
SbiRet::denied() | cppc_reg_id is a write-only register. |
SbiRet::failed() | The read request failed for unspecified or unknown other reasons. |
This function is defined in RISC-V SBI Specification chapter 14.2.