module ti.sysbios.family.arm.v8a.Mmu

Memory Management Unit (MMU) Manager

This module allows the ARM processor to map a 64-bit virtual address to a 48-bit physical address and enable/disable the MMU. It does this through translation tables in memory. [ more ... ]
C synopsis target-domain sourced in ti/sysbios/family/arm/v8a/Mmu.xdc
#include <ti/sysbios/family/arm/v8a/Mmu.h>
Functions
Void 
Void 
Void 
Bool 
Bool 
Mmu_map// Add a mapping to MMU table(UInt64 vaddr, UInt64 paddr, SizeT size, Mmu_MapAttrs *attrs);
Void 
Void 
Functions common to all target modules
Defines
#define
#define
Typedefs
typedef enum
typedef enum
typedef enum
typedef Void 
typedef struct
typedef enum
Constants
extern const Assert_Id 
extern const Assert_Id 
extern const Assert_Id 
extern const Assert_Id 
extern const Assert_Id 
extern const Assert_Id 
extern const Mmu_MapAttrs 
extern const Bool 
extern const Mmu_GranuleSize 
extern const Mmu_InitFuncPtr 
extern const UInt8 
extern const UInt8 
extern const UInt8 
extern const UInt8 
extern const UInt8 
extern const UInt8 
extern const UInt8 
extern const UInt8 
extern const UInt 
 
DETAILS
This module allows the ARM processor to map a 64-bit virtual address to a 48-bit physical address and enable/disable the MMU. It does this through translation tables in memory.
Every application must register a Mmu init function (see initFunc) that contains calls to Mmu_map() to configure the MMU.
*.cfg:
  var Mmu = xdc.useModule('ti.sysbios.family.arm.v8a.Mmu');
  Mmu.initFunc = "&Mmu_initFuncDefault";
Example Mmu_initFuncDefault() provided function for evmAM6x devices:
  ...

  Void Mmu_initFuncDefault()
  {
      Bool ret;
      Mmu_MapAttrs attrs;

      Mmu_initMapAttrs(&attrs);

      // MAIR0 has a default memory type that is non-gathering and
      // non-reordering with no early write acknowledegement property.
      // In other words, strongly ordered memory type.
      attrs.attrIndx = Mmu_AttrIndx_MAIR0;

      // Map GICv3 registers
      ret = Mmu_map(0x01800000, 0x01800000, 0x00100000, &attrs);
      if (!ret) {
          goto fail;
      }

      // Map DMTimer registers
      ret = Mmu_map(0x02400000, 0x02400000, 0x000c0000, &attrs);
      if (!ret) {
          goto fail;
      }

      // Map UART registers
      ret = Mmu_map(0x02800000, 0x02800000, 0x00001000, &attrs);
      if (!ret) {
          goto fail;
      }

      // Map System Timer registers
      ret = Mmu_map(0x2A430000, 0x2A430000, 0x00001000, &attrs);
      if (!ret) {
          goto fail;
      }

      // MAIR7 has a default attribute type of Inner and Outer
      // write-back cacheable
      attrs.attrIndx = Mmu_AttrIndx_MAIR7;

      //Map MSMC SRAM
      ret = Mmu_map(0x70000000, 0x70000000, 0x00200000, &attrs);
      if (!ret) {
          goto fail;
      }

      return;

  fail:
      System_printf("Mmu config failed.\n");
      while (1);
  }

 
const Mmu_PA_MAX_WIDTH
C synopsis target-domain
#define Mmu_PA_MAX_WIDTH (UInt8)48
 
 
const Mmu_PA_SIZE_ENCODING
C synopsis target-domain
#define Mmu_PA_SIZE_ENCODING (UInt8)0x5
 
 
enum Mmu_AccessPerm

Access Permissions

C synopsis target-domain
typedef enum Mmu_AccessPerm {
    Mmu_AccessPerm_PRIV_RW_USER_NONE,
    Mmu_AccessPerm_PRIV_RW_USER_RW,
    Mmu_AccessPerm_PRIV_RO_USER_NONE,
    Mmu_AccessPerm_PRIV_RO_USER_RO
} Mmu_AccessPerm;
 
 
enum Mmu_AttrIndx

Memory attribute register (MAIR) index

C synopsis target-domain
typedef enum Mmu_AttrIndx {
    Mmu_AttrIndx_MAIR0,
    Mmu_AttrIndx_MAIR1,
    Mmu_AttrIndx_MAIR2,
    Mmu_AttrIndx_MAIR3,
    Mmu_AttrIndx_MAIR4,
    Mmu_AttrIndx_MAIR5,
    Mmu_AttrIndx_MAIR6,
    Mmu_AttrIndx_MAIR7
} Mmu_AttrIndx;
 
DETAILS
SYS/BIOS defines default values for MAIR register. See MAIR0, MAIR1, MAIR2, MAIR3, MAIR4, MAIR5, MAIR6 & MAIR7 for more info on the memory type defined by each MAIR register.
 
enum Mmu_GranuleSize

Memory translation granuleSize granule size

C synopsis target-domain
typedef enum Mmu_GranuleSize {
    Mmu_GranuleSize_4KB,
    Mmu_GranuleSize_16KB,
    Mmu_GranuleSize_64KB
} Mmu_GranuleSize;
 
 
enum Mmu_Shareable

Shareability attribute

C synopsis target-domain
typedef enum Mmu_Shareable {
    Mmu_Shareable_NONE,
    Mmu_Shareable_OUTER,
    Mmu_Shareable_INNER
} Mmu_Shareable;
 
 
typedef Mmu_InitFuncPtr

Mmu init function type definition

C synopsis target-domain
typedef Void (*Mmu_InitFuncPtr)(Void);
 
 
struct Mmu_MapAttrs

Structure containing attributes for memory map entry

C synopsis target-domain
typedef struct Mmu_MapAttrs {
    Mmu_AccessPerm accessPerm;
    // privileged & user access permissions
    Bool privExecute;
    // privileged execute permission
    Bool userExecute;
    // user execute permission
    Mmu_Shareable shareable;
    // shareability field value 0-3
    Mmu_AttrIndx attrIndx;
    // stage 1 memory attributes index field for the indicated MAIRn reg value 0-7
    Bool global;
    // global mmu entry ? (used by kernel when memory protection extensions are enabled)
} Mmu_MapAttrs;
 
 
config Mmu_A_nullPointer  // module-wide

Assert raised when a pointer is null

C synopsis target-domain
extern const Assert_Id Mmu_A_nullPointer;
 
 
config Mmu_A_paddrOutOfRange  // module-wide

Assert raised when physical address passed is out of range

C synopsis target-domain
extern const Assert_Id Mmu_A_paddrOutOfRange;
 
 
config Mmu_A_unalignedPaddr  // module-wide

Assert raised if unaligned physical address passed to Mmu_map()

C synopsis target-domain
extern const Assert_Id Mmu_A_unalignedPaddr;
 
 
config Mmu_A_unalignedSize  // module-wide

Assert raised if unaligned size passed to Mmu_map()

C synopsis target-domain
extern const Assert_Id Mmu_A_unalignedSize;
 
 
config Mmu_A_unalignedVaddr  // module-wide

Assert raised if unaligned virtual address passed to Mmu_map()

C synopsis target-domain
extern const Assert_Id Mmu_A_unalignedVaddr;
 
 
config Mmu_A_vaddrOutOfRange  // module-wide

Assert raised when virtual address passed is out of range

C synopsis target-domain
extern const Assert_Id Mmu_A_vaddrOutOfRange;
 
 
config Mmu_MAIR0  // module-wide

Memory attribute 0

C synopsis target-domain
extern const UInt8 Mmu_MAIR0;
 
DETAILS
Default is memory with non-gathering, non-reordering and no early write acknowledegement property.
 
config Mmu_MAIR1  // module-wide

Memory attribute 1

C synopsis target-domain
extern const UInt8 Mmu_MAIR1;
 
DETAILS
Default is memory with non-gathering, non-reordering and early write acknowledegement property.
 
config Mmu_MAIR2  // module-wide

Memory attribute 2

C synopsis target-domain
extern const UInt8 Mmu_MAIR2;
 
DETAILS
Default is memory with non-gathering, reordering and early write acknowledegement property.
 
config Mmu_MAIR3  // module-wide

Memory attribute 3

C synopsis target-domain
extern const UInt8 Mmu_MAIR3;
 
DETAILS
Default is memory with gathering, reordering and early write acknowledegement property.
 
config Mmu_MAIR4  // module-wide

Memory attribute 4

C synopsis target-domain
extern const UInt8 Mmu_MAIR4;
 
DETAILS
Default is normal inner & outer non-cacheable memory.
 
config Mmu_MAIR5  // module-wide

Memory attribute 5

C synopsis target-domain
extern const UInt8 Mmu_MAIR5;
 
DETAILS
Default is normal outer non-cacheable, inner write-back cacheable non-transient memory.
 
config Mmu_MAIR6  // module-wide

Memory attribute 6

C synopsis target-domain
extern const UInt8 Mmu_MAIR6;
 
DETAILS
Default is normal outer & inner write-through cacheable non-transient memory.
 
config Mmu_MAIR7  // module-wide

Memory attribute 7

C synopsis target-domain
extern const UInt8 Mmu_MAIR7;
 
DETAILS
Default is normal outer and inner write-back cacheable non-transient memory.
 
config Mmu_defaultMapAttrs  // module-wide

default descriptor attributes structure

C synopsis target-domain
extern const Mmu_MapAttrs Mmu_defaultMapAttrs;
 
 
config Mmu_enableMMU  // module-wide

Configuration parameter to enable MMU

C synopsis target-domain
extern const Bool Mmu_enableMMU;
 
 
config Mmu_granuleSize  // module-wide

Memory translation granule size. Default is 4KB

C synopsis target-domain
extern const Mmu_GranuleSize Mmu_granuleSize;
 
DETAILS
The granule size determines the smallest page size that can be mapped with the MMU.
 
config Mmu_initFunc  // module-wide

MMU init function pointer

C synopsis target-domain
extern const Mmu_InitFuncPtr Mmu_initFunc;
 
DETAILS
This config param is initialized to point to an init function that will perform MMU configuration using the map runtime APIs provided by this module. The init function is called before C initialization i.e. before the data section is initialized. Therefore, care must be taken to not rely on any initialized data variables.
By default, the Mmu_initFuncDefault function designed for use with AM65x devices is used if the application doesn't provide its own implementation.
 
config Mmu_tableArrayLen  // module-wide

Length of array of MMU tables

C synopsis target-domain
extern const UInt Mmu_tableArrayLen;
 
DETAILS
MMU module allocates memory for MMU table from a table array. This config param controls number of MMU tables supported. Each table in the array is the size of the MMU table and aligned to the table's size.
NOTE
MMU table size is same as translation granule size (see granuleSize)
 
Mmu_enable()  // module-wide

Enables the MMU

C synopsis target-domain
Void Mmu_enable();
 
DETAILS
If the MMU is already enabled, then simply return. Otherwise this function does the following:
  • If the L1 program cache is enabled, invalidate all of L1 program cache.
This function enables the MMU on the core it is called from.
NOTE
This function does not change the L1 data/program cache settings.
 
Mmu_initFuncDefault()  // module-wide

default Mmu.initFunc implementation

C synopsis target-domain
Void Mmu_initFuncDefault();
 
DETAILS
provides Mmu regions for the AM65x's GIC, DMTimer, UART, SYSTIMER, and MSMC memory.
 
Mmu_initMapAttrs()  // module-wide

Initializes the map attribute structure

C synopsis target-domain
Void Mmu_initMapAttrs(Mmu_MapAttrs *descAttrs);
 
ARGUMENTS
attrs — Pointer to map attribute struct
 
Mmu_isEnabled()  // module-wide

Determines if the MMU is enabled

C synopsis target-domain
Bool Mmu_isEnabled();
 
 
Mmu_map()  // module-wide

Add a mapping to MMU table

C synopsis target-domain
Bool Mmu_map(UInt64 vaddr, UInt64 paddr, SizeT size, Mmu_MapAttrs *attrs);
 
ARGUMENTS
vaddr — Virtual address (aligned to granuleSize)
paddr — Physical address (aligned to granuleSize)
size — Region size (aligned to granuleSize)
attrs — Memory region attributes
RETURNS
Status (True-success, False-failed)
DETAILS
This API adds a mapping for the given virtual and physical address to the MMU table and sets the memory attributes as per the attributes passed to the function.
This API internally disables interrupts before updating the MMU table. The interrupts may be disabled for a long period of time. It is therefore recommended to either call this API in the Mmu.initFunc or in main().
The smallest mapping size (page size) supported is determined by the granuleSize. The largess mapping size supported is 2^PA_MAX_WIDTH-1.
 
Mmu_setMAIR()  // module-wide

Sets the memory attribute encoding in the MAIRn register

C synopsis target-domain
Void Mmu_setMAIR(UInt8 attrIndx, UInt8 attr);
 
ARGUMENTS
attrIndx — Memory attribute index
attr — Memory attribute encoding
DETAILS
MAIR provides the memory attribute encodings to the possible attrIndx values in a long-descriptor format translation table entry for stage 1 translations.
attrIndx[2:0] selects the ATTRn bit-field in the MAIR register.
Memory Attribute Indirection Register (MAIR) bit assignments:
         --------------------------------------------------------------
        |63     |    56|55     |     48|47     |     40|39     |     32|
         --------------------------------------------------------------
  MAIR  |     ATTR7    |     ATTR6     |     ATTR5     |     ATTR4     |
         --------------------------------------------------------------
        |31     |    24|23     |     16|15     |      8|7      |      0|
         --------------------------------------------------------------
  MAIR  |     ATTR3    |     ATTR2     |     ATTR1     |     ATTR0     |
         --------------------------------------------------------------
SYS/BIOS has 8 MAIR config params (MAIR0, MAIR2, ...) that are initialized to default value. In order to have a custom memory attribute, a user can either change the MAIRn config param in the application's cfg script or call this runtime API.
For more details on MAIR encodings please refer v8A ARM Architecture Reference Manual
NOTE
This function only invalidates the TLB and does not flush the cache. If the cacheability attribute of a region of memory is changed by modifying the MAIR entry for the region, the application needs to flush and invalidate the region of memory from the cache.
 
Mmu_tlbInvAll()  // module-wide

Invalidate entire TLB (both data and instruction)

C synopsis target-domain
Void Mmu_tlbInvAll();
 
Module-Wide Built-Ins

C synopsis target-domain
Types_ModuleId Mmu_Module_id();
// Get this module's unique id
 
Bool Mmu_Module_startupDone();
// Test if this module has completed startup
 
IHeap_Handle Mmu_Module_heap();
// The heap from which this module allocates memory
 
Bool Mmu_Module_hasMask();
// Test whether this module has a diagnostics mask
 
Bits16 Mmu_Module_getMask();
// Returns the diagnostics mask for this module
 
Void Mmu_Module_setMask(Bits16 mask);
// Set the diagnostics mask for this module
 
Configuration settings sourced in ti/sysbios/family/arm/v8a/Mmu.xdc
var Mmu = xdc.useModule('ti.sysbios.family.arm.v8a.Mmu');
module-wide constants & types
    const Mmu.PA_MAX_WIDTH//  = 48;
    const Mmu.PA_SIZE_ENCODING//  = 0x5;
 
    values of type Mmu.AccessPerm// Access Permissions
        const Mmu.AccessPerm_PRIV_RW_USER_NONE;
        const Mmu.AccessPerm_PRIV_RW_USER_RW;
        const Mmu.AccessPerm_PRIV_RO_USER_NONE;
        const Mmu.AccessPerm_PRIV_RO_USER_RO;
 
        const Mmu.AttrIndx_MAIR0;
        const Mmu.AttrIndx_MAIR1;
        const Mmu.AttrIndx_MAIR2;
        const Mmu.AttrIndx_MAIR3;
        const Mmu.AttrIndx_MAIR4;
        const Mmu.AttrIndx_MAIR5;
        const Mmu.AttrIndx_MAIR6;
        const Mmu.AttrIndx_MAIR7;
 
        const Mmu.GranuleSize_4KB;
        const Mmu.GranuleSize_16KB;
        const Mmu.GranuleSize_64KB;
 
        const Mmu.Shareable_NONE;
        const Mmu.Shareable_OUTER;
        const Mmu.Shareable_INNER;
 
        obj.privExecute// privileged execute permission = Bool  ...
        obj.userExecute// user execute permission = Bool  ...
module-wide config parameters
        msg: "A_nullPointer: Pointer is null"
    };
        msg: "A_paddrOutOfRange: Physical address is out of range"
    };
        msg: "A_unalignedPaddr: Physical address not page aligned"
    };
        msg: "A_unalignedSize: Mmu mapping size not page aligned"
    };
        msg: "A_unalignedVaddr: Virtual address not page aligned"
    };
        msg: "A_vaddrOutOfRange: Virtual address is out of range"
    };
    Mmu.MAIR0// Memory attribute 0 = UInt8 0x00;
    Mmu.MAIR1// Memory attribute 1 = UInt8 0x04;
    Mmu.MAIR2// Memory attribute 2 = UInt8 0x08;
    Mmu.MAIR3// Memory attribute 3 = UInt8 0x0C;
    Mmu.MAIR4// Memory attribute 4 = UInt8 0x44;
    Mmu.MAIR5// Memory attribute 5 = UInt8 0x4F;
    Mmu.MAIR6// Memory attribute 6 = UInt8 0xBB;
    Mmu.MAIR7// Memory attribute 7 = UInt8 0xFF;
        accessPerm: Mmu.AccessPerm_PRIV_RW_USER_NONE,
        privExecute: true,
        userExecute: false,
        shareable: Mmu.Shareable_OUTER,
        attrIndx: Mmu.AttrIndx_MAIR0,
        global: true
    };
 
    Mmu.tableArraySection// Contains a table array and some state variables. This section is uninitialized = String ".data.ti_sysbios_family_arm_v8a_Mmu_tableArray";
 
 
const Mmu.PA_MAX_WIDTH
Configuration settings
const Mmu.PA_MAX_WIDTH = 48;
 
C SYNOPSIS
 
const Mmu.PA_SIZE_ENCODING
Configuration settings
const Mmu.PA_SIZE_ENCODING = 0x5;
 
C SYNOPSIS
 
enum Mmu.AccessPerm

Access Permissions

Configuration settings
values of type Mmu.AccessPerm
    const Mmu.AccessPerm_PRIV_RW_USER_NONE;
    const Mmu.AccessPerm_PRIV_RW_USER_RW;
    const Mmu.AccessPerm_PRIV_RO_USER_NONE;
    const Mmu.AccessPerm_PRIV_RO_USER_RO;
 
C SYNOPSIS
 
enum Mmu.AttrIndx

Memory attribute register (MAIR) index

Configuration settings
values of type Mmu.AttrIndx
    const Mmu.AttrIndx_MAIR0;
    const Mmu.AttrIndx_MAIR1;
    const Mmu.AttrIndx_MAIR2;
    const Mmu.AttrIndx_MAIR3;
    const Mmu.AttrIndx_MAIR4;
    const Mmu.AttrIndx_MAIR5;
    const Mmu.AttrIndx_MAIR6;
    const Mmu.AttrIndx_MAIR7;
 
DETAILS
SYS/BIOS defines default values for MAIR register. See MAIR0, MAIR1, MAIR2, MAIR3, MAIR4, MAIR5, MAIR6 & MAIR7 for more info on the memory type defined by each MAIR register.
C SYNOPSIS
 
enum Mmu.GranuleSize

Memory translation granuleSize granule size

Configuration settings
values of type Mmu.GranuleSize
    const Mmu.GranuleSize_4KB;
    const Mmu.GranuleSize_16KB;
    const Mmu.GranuleSize_64KB;
 
C SYNOPSIS
 
enum Mmu.Shareable

Shareability attribute

Configuration settings
values of type Mmu.Shareable
    const Mmu.Shareable_NONE;
    const Mmu.Shareable_OUTER;
    const Mmu.Shareable_INNER;
 
C SYNOPSIS
 
struct Mmu.MapAttrs

Structure containing attributes for memory map entry

Configuration settings
var obj = new Mmu.MapAttrs;
 
    obj.accessPerm = Mmu.AccessPerm  ...
    // privileged & user access permissions
    obj.privExecute = Bool  ...
    // privileged execute permission
    obj.userExecute = Bool  ...
    // user execute permission
    obj.shareable = Mmu.Shareable  ...
    // shareability field value 0-3
    obj.attrIndx = Mmu.AttrIndx  ...
    // stage 1 memory attributes index field for the indicated MAIRn reg value 0-7
    obj.global = Bool  ...
    // global mmu entry ? (used by kernel when memory protection extensions are enabled)
 
C SYNOPSIS
 
config Mmu.A_nullPointer  // module-wide

Assert raised when a pointer is null

Configuration settings
Mmu.A_nullPointer = Assert.Desc {
    msg: "A_nullPointer: Pointer is null"
};
 
C SYNOPSIS
 
config Mmu.A_paddrOutOfRange  // module-wide

Assert raised when physical address passed is out of range

Configuration settings
Mmu.A_paddrOutOfRange = Assert.Desc {
    msg: "A_paddrOutOfRange: Physical address is out of range"
};
 
C SYNOPSIS
 
config Mmu.A_unalignedPaddr  // module-wide

Assert raised if unaligned physical address passed to Mmu_map()

Configuration settings
Mmu.A_unalignedPaddr = Assert.Desc {
    msg: "A_unalignedPaddr: Physical address not page aligned"
};
 
C SYNOPSIS
 
config Mmu.A_unalignedSize  // module-wide

Assert raised if unaligned size passed to Mmu_map()

Configuration settings
Mmu.A_unalignedSize = Assert.Desc {
    msg: "A_unalignedSize: Mmu mapping size not page aligned"
};
 
C SYNOPSIS
 
config Mmu.A_unalignedVaddr  // module-wide

Assert raised if unaligned virtual address passed to Mmu_map()

Configuration settings
Mmu.A_unalignedVaddr = Assert.Desc {
    msg: "A_unalignedVaddr: Virtual address not page aligned"
};
 
C SYNOPSIS
 
config Mmu.A_vaddrOutOfRange  // module-wide

Assert raised when virtual address passed is out of range

Configuration settings
Mmu.A_vaddrOutOfRange = Assert.Desc {
    msg: "A_vaddrOutOfRange: Virtual address is out of range"
};
 
C SYNOPSIS
 
config Mmu.MAIR0  // module-wide

Memory attribute 0

Configuration settings
Mmu.MAIR0 = UInt8 0x00;
 
DETAILS
Default is memory with non-gathering, non-reordering and no early write acknowledegement property.
C SYNOPSIS
 
config Mmu.MAIR1  // module-wide

Memory attribute 1

Configuration settings
Mmu.MAIR1 = UInt8 0x04;
 
DETAILS
Default is memory with non-gathering, non-reordering and early write acknowledegement property.
C SYNOPSIS
 
config Mmu.MAIR2  // module-wide

Memory attribute 2

Configuration settings
Mmu.MAIR2 = UInt8 0x08;
 
DETAILS
Default is memory with non-gathering, reordering and early write acknowledegement property.
C SYNOPSIS
 
config Mmu.MAIR3  // module-wide

Memory attribute 3

Configuration settings
Mmu.MAIR3 = UInt8 0x0C;
 
DETAILS
Default is memory with gathering, reordering and early write acknowledegement property.
C SYNOPSIS
 
config Mmu.MAIR4  // module-wide

Memory attribute 4

Configuration settings
Mmu.MAIR4 = UInt8 0x44;
 
DETAILS
Default is normal inner & outer non-cacheable memory.
C SYNOPSIS
 
config Mmu.MAIR5  // module-wide

Memory attribute 5

Configuration settings
Mmu.MAIR5 = UInt8 0x4F;
 
DETAILS
Default is normal outer non-cacheable, inner write-back cacheable non-transient memory.
C SYNOPSIS
 
config Mmu.MAIR6  // module-wide

Memory attribute 6

Configuration settings
Mmu.MAIR6 = UInt8 0xBB;
 
DETAILS
Default is normal outer & inner write-through cacheable non-transient memory.
C SYNOPSIS
 
config Mmu.MAIR7  // module-wide

Memory attribute 7

Configuration settings
Mmu.MAIR7 = UInt8 0xFF;
 
DETAILS
Default is normal outer and inner write-back cacheable non-transient memory.
C SYNOPSIS
 
config Mmu.defaultMapAttrs  // module-wide

default descriptor attributes structure

Configuration settings
Mmu.defaultMapAttrs = Mmu.MapAttrs {
    accessPerm: Mmu.AccessPerm_PRIV_RW_USER_NONE,
    privExecute: true,
    userExecute: false,
    shareable: Mmu.Shareable_OUTER,
    attrIndx: Mmu.AttrIndx_MAIR0,
    global: true
};
 
C SYNOPSIS
 
config Mmu.enableMMU  // module-wide

Configuration parameter to enable MMU

Configuration settings
Mmu.enableMMU = Bool true;
 
C SYNOPSIS
 
config Mmu.granuleSize  // module-wide

Memory translation granule size. Default is 4KB

Configuration settings
 
DETAILS
The granule size determines the smallest page size that can be mapped with the MMU.
C SYNOPSIS
 
config Mmu.initFunc  // module-wide

MMU init function pointer

Configuration settings
Mmu.initFunc = Void(*)(Void) Mmu.initFuncDefault;
 
DETAILS
This config param is initialized to point to an init function that will perform MMU configuration using the map runtime APIs provided by this module. The init function is called before C initialization i.e. before the data section is initialized. Therefore, care must be taken to not rely on any initialized data variables.
By default, the Mmu_initFuncDefault function designed for use with AM65x devices is used if the application doesn't provide its own implementation.
C SYNOPSIS
 
config Mmu.tableArrayLen  // module-wide

Length of array of MMU tables

Configuration settings
Mmu.tableArrayLen = UInt 16;
 
DETAILS
MMU module allocates memory for MMU table from a table array. This config param controls number of MMU tables supported. Each table in the array is the size of the MMU table and aligned to the table's size.
NOTE
MMU table size is same as translation granule size (see granuleSize)
C SYNOPSIS
 
metaonly config Mmu.common$  // module-wide

Common module configuration parameters

Configuration settings
Mmu.common$ = Types.Common$ undefined;
 
DETAILS
All modules have this configuration parameter. Its name contains the '$' character to ensure it does not conflict with configuration parameters declared by the module. This allows new configuration parameters to be added in the future without any chance of breaking existing modules.
 
metaonly config Mmu.tableArraySection  // module-wide

Contains a table array and some state variables. This section is uninitialized

Configuration settings
Mmu.tableArraySection = String ".data.ti_sysbios_family_arm_v8a_Mmu_tableArray";
 
DETAILS
Note: Memory containing the table array must be marked as inner & and outer shareable, and inner and outer write-back write-allocate cacheable.
generated on Thu, 23 May 2019 00:22:57 GMT