NAME

vm_bind_l2 - Makes binding from a level 2 page table to a physical page frame.

SYNOPSIS

#include <charm.h>

Status vm_bind_l2( Vaddr va, int pfn, Cap ptcap, Cap bindcap, PTE pte );

PARAMETERS

va Specifies the virtual address to which the physical memory is to be mapped.

pfn Specifies the physical page frame containing the root page table into which the entry is being made.

ptcap The write capability associated with pfn.

bindcap A capability for the page frame described in the pte entry. If the mapping specifies a read-write protection this must be the write capability, if the mapping specifies any other mapping it must be the read capability.

pte The page table entry to be entered into the root page table.

DESCRIPTION

This function makes an entry in a level 2 page table.

RETURN VALUES

Upon the successful completion, the vm_bind_l2() function returns [SUCCESS].

ERRORS

If the vm_bind_l2() function fails, a Status is returned that corresponds to one of the following values:

[VA_INVALID] The given virtual address is not valid.

[VA_ALREADY_BACKED] The given virtual address is already mapped to an address in physical memory.

[INVALID_PT_CAP] The capability specified by ptcap is invalid.

[INVALID_BIND_CAP] The capability specified by bindcap is invalid.

[PTE_INVALID] The page table entry is malformed.

RELATED INFORMATION

pm_change_caps(), vm_bind_l1(), vm_flush().

Notes for Gurus

See vm_bind_l1 notes

last updated: 11/2/99