Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions | Variables
mmu_64.h File Reference
#include <linux/const.h>
#include <asm/page.h>
#include <asm/hypervisor.h>

Go to the source code of this file.

Data Structures

struct  tsb
 
struct  tsb_config
 
struct  mm_context_t
 

Macros

#define CTX_NR_BITS   13
 
#define TAG_CONTEXT_BITS   ((_AC(1,UL) << CTX_NR_BITS) - _AC(1,UL))
 
#define CTX_VERSION_SHIFT   22
 
#define CTX_VERSION_MASK   ((~0UL) << CTX_VERSION_SHIFT)
 
#define CTX_PGSZ_8KB   _AC(0x0,UL)
 
#define CTX_PGSZ_64KB   _AC(0x1,UL)
 
#define CTX_PGSZ_512KB   _AC(0x2,UL)
 
#define CTX_PGSZ_4MB   _AC(0x3,UL)
 
#define CTX_PGSZ_BITS   _AC(0x7,UL)
 
#define CTX_PGSZ0_NUC_SHIFT   61
 
#define CTX_PGSZ1_NUC_SHIFT   58
 
#define CTX_PGSZ0_SHIFT   16
 
#define CTX_PGSZ1_SHIFT   19
 
#define CTX_PGSZ_MASK
 
#define CTX_PGSZ_BASE   CTX_PGSZ_8KB
 
#define CTX_PGSZ_HUGE   CTX_PGSZ_4MB
 
#define CTX_PGSZ_KERN   CTX_PGSZ_4MB
 
#define CTX_CHEETAH_PLUS_NUC
 
#define CTX_CHEETAH_PLUS_CTX0
 
#define CTX_NR_MASK   TAG_CONTEXT_BITS
 
#define CTX_HW_MASK   (CTX_NR_MASK | CTX_PGSZ_MASK)
 
#define CTX_FIRST_VERSION   ((_AC(1,UL) << CTX_VERSION_SHIFT) + _AC(1,UL))
 
#define CTX_VALID(__ctx)   (!(((__ctx.sparc64_ctx_val) ^ tlb_context_cache) & CTX_VERSION_MASK))
 
#define CTX_HWBITS(__ctx)   ((__ctx.sparc64_ctx_val) & CTX_HW_MASK)
 
#define CTX_NRBITS(__ctx)   ((__ctx.sparc64_ctx_val) & CTX_NR_MASK)
 
#define TSB_ENTRY_ALIGNMENT   16
 
#define MM_TSB_BASE   0
 
#define MM_NUM_TSBS   1
 
#define TSB_CONFIG_TSB   0x00
 
#define TSB_CONFIG_RSS_LIMIT   0x08
 
#define TSB_CONFIG_NENTRIES   0x10
 
#define TSB_CONFIG_REG_VAL   0x18
 
#define TSB_CONFIG_MAP_VADDR   0x20
 
#define TSB_CONFIG_MAP_PTE   0x28
 

Functions

struct tsb __attribute__ ((aligned(TSB_ENTRY_ALIGNMENT)))
 
void __tsb_insert (unsigned long ent, unsigned long tag, unsigned long pte)
 
void tsb_flush (unsigned long ent, unsigned long tag)
 
void tsb_init (struct tsb *tsb, unsigned long size)
 

Variables

unsigned long tag
 
unsigned long pte
 
struct tsb_config __attribute__
 

Macro Definition Documentation

#define CTX_CHEETAH_PLUS_CTX0
Value:

Definition at line 44 of file mmu_64.h.

#define CTX_CHEETAH_PLUS_NUC
Value:

Definition at line 40 of file mmu_64.h.

#define CTX_FIRST_VERSION   ((_AC(1,UL) << CTX_VERSION_SHIFT) + _AC(1,UL))

Definition at line 55 of file mmu_64.h.

#define CTX_HW_MASK   (CTX_NR_MASK | CTX_PGSZ_MASK)

Definition at line 53 of file mmu_64.h.

#define CTX_HWBITS (   __ctx)    ((__ctx.sparc64_ctx_val) & CTX_HW_MASK)

Definition at line 58 of file mmu_64.h.

#define CTX_NR_BITS   13

Definition at line 8 of file mmu_64.h.

#define CTX_NR_MASK   TAG_CONTEXT_BITS

Definition at line 52 of file mmu_64.h.

#define CTX_NRBITS (   __ctx)    ((__ctx.sparc64_ctx_val) & CTX_NR_MASK)

Definition at line 59 of file mmu_64.h.

#define CTX_PGSZ0_NUC_SHIFT   61

Definition at line 26 of file mmu_64.h.

#define CTX_PGSZ0_SHIFT   16

Definition at line 28 of file mmu_64.h.

#define CTX_PGSZ1_NUC_SHIFT   58

Definition at line 27 of file mmu_64.h.

#define CTX_PGSZ1_SHIFT   19

Definition at line 29 of file mmu_64.h.

#define CTX_PGSZ_4MB   _AC(0x3,UL)

Definition at line 24 of file mmu_64.h.

#define CTX_PGSZ_512KB   _AC(0x2,UL)

Definition at line 23 of file mmu_64.h.

#define CTX_PGSZ_64KB   _AC(0x1,UL)

Definition at line 22 of file mmu_64.h.

#define CTX_PGSZ_8KB   _AC(0x0,UL)

Definition at line 21 of file mmu_64.h.

#define CTX_PGSZ_BASE   CTX_PGSZ_8KB

Definition at line 33 of file mmu_64.h.

#define CTX_PGSZ_BITS   _AC(0x7,UL)

Definition at line 25 of file mmu_64.h.

#define CTX_PGSZ_HUGE   CTX_PGSZ_4MB

Definition at line 34 of file mmu_64.h.

#define CTX_PGSZ_KERN   CTX_PGSZ_4MB

Definition at line 35 of file mmu_64.h.

#define CTX_PGSZ_MASK
Value:

Definition at line 30 of file mmu_64.h.

#define CTX_VALID (   __ctx)    (!(((__ctx.sparc64_ctx_val) ^ tlb_context_cache) & CTX_VERSION_MASK))

Definition at line 56 of file mmu_64.h.

#define CTX_VERSION_MASK   ((~0UL) << CTX_VERSION_SHIFT)

Definition at line 19 of file mmu_64.h.

#define CTX_VERSION_SHIFT   22

Definition at line 18 of file mmu_64.h.

#define MM_NUM_TSBS   1

Definition at line 89 of file mmu_64.h.

#define MM_TSB_BASE   0

Definition at line 83 of file mmu_64.h.

#define TAG_CONTEXT_BITS   ((_AC(1,UL) << CTX_NR_BITS) - _AC(1,UL))

Definition at line 10 of file mmu_64.h.

#define TSB_CONFIG_MAP_PTE   0x28

Definition at line 108 of file mmu_64.h.

#define TSB_CONFIG_MAP_VADDR   0x20

Definition at line 107 of file mmu_64.h.

#define TSB_CONFIG_NENTRIES   0x10

Definition at line 105 of file mmu_64.h.

#define TSB_CONFIG_REG_VAL   0x18

Definition at line 106 of file mmu_64.h.

#define TSB_CONFIG_RSS_LIMIT   0x08

Definition at line 104 of file mmu_64.h.

#define TSB_CONFIG_TSB   0x00

Definition at line 103 of file mmu_64.h.

#define TSB_ENTRY_ALIGNMENT   16

Definition at line 63 of file mmu_64.h.

Function Documentation

void __tsb_insert ( unsigned long  ent,
unsigned long  tag,
unsigned long  pte 
)
void tsb_flush ( unsigned long  ent,
unsigned long  tag 
)
void tsb_init ( struct tsb tsb,
unsigned long  size 
)

Variable Documentation

unsigned long pte

Definition at line 70 of file mmu_64.h.

unsigned long tag

Definition at line 69 of file mmu_64.h.