riscv haskell: globalPT is at maxPTLevel
This commit is contained in:
parent
939201f782
commit
c46a641f7f
|
@ -39,10 +39,6 @@ import SEL4.API.Invocation.RISCV64 as ArchInv
|
|||
|
||||
{- Constants -}
|
||||
|
||||
-- counting from 0, i.e. number of levels = maxPTLevel + 1 = top-level table
|
||||
maxPTLevel :: Int
|
||||
maxPTLevel = 2
|
||||
|
||||
ipcBufferSizeBits :: Int
|
||||
ipcBufferSizeBits = 10
|
||||
|
||||
|
|
|
@ -32,8 +32,13 @@ data KernelState = RISCVKernelState {
|
|||
riscvKSKernelVSpace :: PPtr Word -> RISCVVSpaceRegionUse
|
||||
}
|
||||
|
||||
-- counting from 0 at bottom, i.e. number of levels = maxPTLevel + 1;
|
||||
-- maxPTLevel = level of top-level root table
|
||||
maxPTLevel :: Int
|
||||
maxPTLevel = 2
|
||||
|
||||
riscvKSGlobalPT :: KernelState -> PPtr PTE
|
||||
riscvKSGlobalPT s = head (riscvKSGlobalPTs s 0)
|
||||
riscvKSGlobalPT s = head (riscvKSGlobalPTs s maxPTLevel)
|
||||
|
||||
newKernelState :: PAddr -> (KernelState, [PAddr])
|
||||
newKernelState _ = error "No initial state defined for RISC-V"
|
||||
|
|
Loading…
Reference in New Issue