]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - include/asm-sparc64/mmu.h
Merge branch 'linus' into tracing/sysprof
[linux-2.6-omap-h63xx.git] / include / asm-sparc64 / mmu.h
index 230ba678d3b0422418d85df877b48133ceb307ba..8abc58f0f9d707b0f79d438b2c238643843539e5 100644 (file)
@@ -1,9 +1,8 @@
 #ifndef __MMU_H
 #define __MMU_H
 
-#include <linux/config.h>
+#include <linux/const.h>
 #include <asm/page.h>
-#include <asm/const.h>
 #include <asm/hypervisor.h>
 
 #define CTX_NR_BITS            13
@@ -90,18 +89,39 @@ extern void __tsb_insert(unsigned long ent, unsigned long tag, unsigned long pte
 extern void tsb_flush(unsigned long ent, unsigned long tag);
 extern void tsb_init(struct tsb *tsb, unsigned long size);
 
-typedef struct {
-       spinlock_t              lock;
-       unsigned long           sparc64_ctx_val;
+struct tsb_config {
        struct tsb              *tsb;
        unsigned long           tsb_rss_limit;
        unsigned long           tsb_nentries;
        unsigned long           tsb_reg_val;
        unsigned long           tsb_map_vaddr;
        unsigned long           tsb_map_pte;
-       struct hv_tsb_descr     tsb_descr;
+};
+
+#define MM_TSB_BASE    0
+
+#ifdef CONFIG_HUGETLB_PAGE
+#define MM_TSB_HUGE    1
+#define MM_NUM_TSBS    2
+#else
+#define MM_NUM_TSBS    1
+#endif
+
+typedef struct {
+       spinlock_t              lock;
+       unsigned long           sparc64_ctx_val;
+       unsigned long           huge_pte_count;
+       struct tsb_config       tsb_block[MM_NUM_TSBS];
+       struct hv_tsb_descr     tsb_descr[MM_NUM_TSBS];
 } mm_context_t;
 
 #endif /* !__ASSEMBLY__ */
 
+#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
+
 #endif /* __MMU_H */