summaryrefslogtreecommitdiffstats
path: root/sys/ia64
diff options
context:
space:
mode:
authormarcel <marcel@FreeBSD.org>2004-11-21 21:40:08 +0000
committermarcel <marcel@FreeBSD.org>2004-11-21 21:40:08 +0000
commit480c409ecf45e53c6ba38e1d86ceb4fe3238a70a (patch)
treea6e8598a29ae1bee0634661b5299f68b2753f0e5 /sys/ia64
parentf90c20620f68324184b69ab66a00c4393f638a26 (diff)
downloadFreeBSD-src-480c409ecf45e53c6ba38e1d86ceb4fe3238a70a.zip
FreeBSD-src-480c409ecf45e53c6ba38e1d86ceb4fe3238a70a.tar.gz
Remove struct ia64_itir and use a plain old uint64_t instead.
Diffstat (limited to 'sys/ia64')
-rw-r--r--sys/ia64/ia64/pmap.c12
-rw-r--r--sys/ia64/include/pte.h17
2 files changed, 12 insertions, 17 deletions
diff --git a/sys/ia64/ia64/pmap.c b/sys/ia64/ia64/pmap.c
index 15ade60..ab37b87 100644
--- a/sys/ia64/ia64/pmap.c
+++ b/sys/ia64/ia64/pmap.c
@@ -1093,8 +1093,7 @@ pmap_set_pte(struct ia64_lpte *pte, vm_offset_t va, vm_offset_t pa,
pte->pte |= (wired) ? PTE_WIRED : 0;
pte->pte |= pa & PTE_PPN_MASK;
- pte->itir.ps = PAGE_SHIFT;
- pte->itir.key = 0;
+ pte->itir = PAGE_SHIFT << 2;
pte->tag = ia64_ttag(va);
@@ -2250,9 +2249,9 @@ print_trs(int type)
struct ia64_pal_result res;
int i, maxtr;
struct {
- uint64_t ifa;
- struct ia64_itir itir;
pt_entry_t pte;
+ uint64_t itir;
+ uint64_t ifa;
struct ia64_rr rr;
} buf;
static const char *manames[] = {
@@ -2287,14 +2286,15 @@ print_trs(int type)
db_printf("%d %06x %013lx %013lx %4s %d %d %d %d %d %-3s "
"%d %06x\n", (int)buf.ifa & 1, buf.rr.rr_rid,
buf.ifa >> 12, (buf.pte & PTE_PPN_MASK) >> 12,
- psnames[buf.itir.ps], (buf.pte & PTE_ED) ? 1 : 0,
+ psnames[(buf.itir & ITIR_PS_MASK) >> 2],
+ (buf.pte & PTE_ED) ? 1 : 0,
(int)(buf.pte & PTE_AR_MASK) >> 9,
(int)(buf.pte & PTE_PL_MASK) >> 7,
(pmap_lpte_dirty(&buf)) ? 1 : 0,
(pmap_lpte_accessed(&buf)) ? 1 : 0,
manames[(buf.pte & PTE_MA_MASK) >> 2],
(pmap_lpte_present(&buf)) ? 1 : 0,
- buf.itir.key);
+ (int)((buf.itir & ITIR_KEY_MASK) >> 8));
}
}
diff --git a/sys/ia64/include/pte.h b/sys/ia64/include/pte.h
index 20c5042..f57cb4d 100644
--- a/sys/ia64/include/pte.h
+++ b/sys/ia64/include/pte.h
@@ -59,6 +59,11 @@
#define PTE_MANAGED 0x0040000000000000
#define PTE_PROT_MASK 0x0700000000000000
+#define ITIR__RV1_ 0x0000000000000003
+#define ITIR_PS_MASK 0x00000000000000FC
+#define ITIR_KEY_MASK 0x00000000FFFFFF00
+#define ITIR__RV2_ 0xFFFFFFFF00000000
+
#ifndef LOCORE
typedef uint64_t pt_entry_t;
@@ -76,21 +81,11 @@ pte_atomic_set(pt_entry_t *ptep, uint64_t val)
}
/*
- * Layout of cr.itir.
- */
-struct ia64_itir {
- uint64_t __rv1__ :2; /* bits 0..1 */
- uint64_t ps :6; /* bits 2..7 */
- uint64_t key :24; /* bits 8..31 */
- uint64_t __rv2__ :32; /* bits 32..63 */
-};
-
-/*
* A long-format VHPT entry.
*/
struct ia64_lpte {
pt_entry_t pte;
- struct ia64_itir itir;
+ uint64_t itir;
uint64_t tag; /* includes ti */
uint64_t chain; /* pa of collision chain */
};
OpenPOWER on IntegriCloud