Function sbi_rt::cppc_probe

source ·
pub fn cppc_probe(cppc_reg_id: u32) -> SbiRet
Expand description

Probe whether the CPPC register is implemented or not by the platform.

§Parameters

The cppc_reg_id parameter specifies the CPPC register ID.

§Return value

If the register is implemented, SbiRet.value will contain the register width. If the register is not implemented, SbiRet.value will be set to 0.

The possible error codes returned in SbiRet.error are shown in the table below:

Return codeDescription
SbiRet::success()Probe completed successfully.
SbiRet::invalid_param()cppc_reg_id is reserved.
SbiRet::failed()The probe request failed for unspecified or unknown other reasons.

This function is defined in RISC-V SBI Specification chapter 14.1.