ia64/xen-unstable

view xen/include/asm-ia64/vhpt.h @ 9748:2f86b84d0483

[IA64] more cleanup in vhpt.h

VHPT_CCHAIN_LOOKUP removed, body is now inlined in ivt.S
vhpt_insert() is now written in C.
Cleanup within vhpt.c/.h

Signed-off-by: Tristan Gingold <tristan.gingold@bull.net>
author awilliam@xenbuild.aw
date Fri Apr 21 09:06:38 2006 -0600 (2006-04-21)
parents dc05c0ce9139
children fcfc614d3713
line source
1 #ifndef ASM_VHPT_H
2 #define ASM_VHPT_H
4 #define VHPT_ENABLED 1
5 #define VHPT_ENABLED_REGION_0_TO_6 1
6 #define VHPT_ENABLED_REGION_7 0
8 /* Size of the VHPT. */
9 #define VHPT_SIZE_LOG2 24
11 /* Number of entries in the VHPT. The size of an entry is 4*8B == 32B */
12 #define VHPT_NUM_ENTRIES (1 << (VHPT_SIZE_LOG2 - 5))
14 #ifdef CONFIG_SMP
15 # define vhpt_flush_all() smp_vhpt_flush_all()
16 #else
17 # define vhpt_flush_all() vhpt_flush()
18 #endif
19 // FIXME: These should be automatically generated
21 #define VLE_PGFLAGS_OFFSET 0
22 #define VLE_ITIR_OFFSET 8
23 #define VLE_TITAG_OFFSET 16
24 #define VLE_CCHAIN_OFFSET 24
26 #ifndef __ASSEMBLY__
27 //
28 // VHPT Long Format Entry (as recognized by hw)
29 //
30 struct vhpt_lf_entry {
31 unsigned long page_flags;
32 unsigned long itir;
33 unsigned long ti_tag;
34 unsigned long CChain;
35 };
37 #define INVALID_TI_TAG 0x8000000000000000L
39 extern void vhpt_init (void);
40 extern void zero_vhpt_stats(void);
41 extern int dump_vhpt_stats(char *buf);
42 extern void vhpt_flush_address(unsigned long vadr, unsigned long addr_range);
43 extern void vhpt_flush_address_remote(int cpu, unsigned long vadr,
44 unsigned long addr_range);
45 extern void vhpt_multiple_insert(unsigned long vaddr, unsigned long pte,
46 unsigned long logps);
47 extern void vhpt_insert (unsigned long vadr, unsigned long pte,
48 unsigned long logps);
49 extern void vhpt_flush(void);
50 extern void smp_vhpt_flush_all(void);
52 /* Currently the VHPT is allocated per CPU. */
53 DECLARE_PER_CPU (unsigned long, vhpt_paddr);
54 DECLARE_PER_CPU (unsigned long, vhpt_pend);
56 #endif /* !__ASSEMBLY */
57 #endif