get_linear_addr

Convert physical to linear address

Declaration

Source position: go32.pp line 97

  function get_linear_addr(phys_addr: DWord; size: LongInt) : DWord;

Description

Converts a physical address into a linear address.

Parameters:

phys_addr
physical address of device.
size
Size of region to map in bytes.

Return value: Linear address that can be used to access the physical memory. Notes: It's the applications responsibility to allocate and set up a descriptor for access to the memory. This function shouldn't be used to map real mode addresses.

Errors

Check the int31error variable.

See also

Name Description
allocate_ldt_descriptors Allocate a number of descriptors
set_segment_base_address Set descriptor's base address
set_segment_limit Set descriptor limit