← Home

hip

Hypervisor Interrupt Pending Register

Address: 0x644 (1604) · Privilege: S · Length: SXLEN · Writable · Defined by: H

The `hip` register is an HSXLEN-bit read/write register that indicates pending interrupts at the hypervisor level. It contains interrupt-pending bits for both VS-level and hypervisor-specific interrupts.

Fields

RV32

31:2423:1615:87:0
—SGEIP—VSEIP—VSTIP—VSSIP—

RV64

63:5655:4847:4039:3231:2423:1615:87:0
—SGEIP—VSEIP—VSTIP—VSSIP—
BitsFieldAliasDescriptionTypeReset
[12]SGEIPPending interrupt bit for supervisor guest external interrupts (SGEI). This bit is 1 if and only if the logical AND of `hgeip` and `hgeie` is nonzero.RO-H0
[10]VSEIPPending interrupt bit for VS-level external interrupts (VSEI). This bit is the logical OR of `vseip` from `hvip`, the interrupt from `hgeip` selected by `hstatus.VGEIN`, and any other external interrupt signal directed to VS-level.RO-H0
[6]VSTIPPending interrupt bit for VS-level timer interrupts (VSTI). This bit is the logical OR of `vstip` from `hvip` and any other timer interrupt directed to VS-level.RO-H0
[2]VSSIPPending interrupt bit for VS-level software interrupts (VSSI). This bit is an alias of the `vssip` bit in `hvip`.RO-H0

Software read

XReg res = 0;

# SGEIP: 1 iff bitwise AND of hgeip and hgeie is nonzero
if (($bits(CSR[hgeie]) & $bits(CSR[hgeip])) != 0) {
  res[12] = 1'b1;
}

# VSEIP: logical OR of hvip.VSEIP and platform-specific sources
if (CSR[hvip].VSEIP == 1'b1) {
  res[10] = 1'b1;
}

# VSTIP: logical OR of hvip.VSTIP and vstimecmp comparison (if Sstc)
if (implemented?(ExtensionName::Sstc)) {
  if ((CSR[hvip].VSTIP == 1'b1) || ((read_mtime() + CSR[htimedelta].DELTA) >= CSR[vstimecmp].TIME)) {
    res[6] = 1'b1;
  }
} else {
  if (CSR[hvip].VSTIP == 1'b1) {
    res[6] = 1'b1;
  }
}

# VSSIP: alias of hvip.VSSIP
if (CSR[hvip].VSSIP == 1'b1) {
  res[2] = 1'b1;
}

return res;

Version af3eaf9+cheriot.f635218

Data from the RISC-V Unified Database, copyright RISC-V International and contributors.

CHERIoT extensions from the CHERIoT specification and Sail model, copyright Microsoft and the CHERIoT Platform contributors.

This site is provided as a community resource and is NOT affiliated with nor endorsed by RISC-V International.