WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [xen-unstable] [IA64] Declarations for PKR

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] [IA64] Declarations for PKR
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Fri, 07 Sep 2007 09:12:46 -0700
Delivery-date: Fri, 07 Sep 2007 09:16:33 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Alex Williamson <alex.williamson@xxxxxx>
# Date 1185833231 21600
# Node ID 522a1932111f225bf4ab05d9260fc1f49160b0de
# Parent  32825349924d2e39d081cf192eee82fb5c46c878
[IA64] Declarations for PKR

Added new declarations for protection keys and define
XEN_IA64_NPKRS representing number of PKRs for PV domains.

Signed-off-by: Dietmar Hahn <dietmar.hahn@xxxxxxxxxxxxxxxxxxx>
---
 xen/arch/ia64/xen/fw_emul.c         |    2 +-
 xen/include/asm-ia64/xenkregs.h     |   24 ++++++++++++++++++++----
 xen/include/asm-ia64/xenprocessor.h |   13 +++++++++++++
 3 files changed, 34 insertions(+), 5 deletions(-)

diff -r 32825349924d -r 522a1932111f xen/arch/ia64/xen/fw_emul.c
--- a/xen/arch/ia64/xen/fw_emul.c       Mon Jul 30 16:01:05 2007 -0600
+++ b/xen/arch/ia64/xen/fw_emul.c       Mon Jul 30 16:07:11 2007 -0600
@@ -669,7 +669,7 @@ xen_pal_emulator(unsigned long index, u6
                                 { .vw = 1,
                                   .phys_add_size = 44,
                                   .key_size = 16,
-                                  .max_pkr = 15,
+                                  .max_pkr = XEN_IA64_NPKRS,
                                   .hash_tag_id = 0x30,
                                   .max_dtr_entry = NDTRS - 1,
                                   .max_itr_entry = NITRS - 1,
diff -r 32825349924d -r 522a1932111f xen/include/asm-ia64/xenkregs.h
--- a/xen/include/asm-ia64/xenkregs.h   Mon Jul 30 16:01:05 2007 -0600
+++ b/xen/include/asm-ia64/xenkregs.h   Mon Jul 30 16:07:11 2007 -0600
@@ -38,13 +38,29 @@
 /* Some cr.itir declarations. */
 #define        IA64_ITIR_PS            2
 #define        IA64_ITIR_PS_LEN        6
-#define IA64_ITIR_PS_MASK      (((__IA64_UL(1) << IA64_ITIR_PS_LEN) - 1) \
-                                                       << IA64_ITIR_PS)
+#define        IA64_ITIR_PS_MASK       (((__IA64_UL(1) << IA64_ITIR_PS_LEN) - 
1) \
+                                                       << IA64_ITIR_PS)
 #define        IA64_ITIR_KEY           8
 #define        IA64_ITIR_KEY_LEN       24
 #define        IA64_ITIR_KEY_MASK      (((__IA64_UL(1) << IA64_ITIR_KEY_LEN) - 
1) \
                                                        << IA64_ITIR_KEY)
-#define IA64_ITIR_PS_KEY(_ps, _key)    (((_ps) << IA64_ITIR_PS) | \
-                                       (((_key) << IA64_ITIR_KEY)))
+#define        IA64_ITIR_PS_KEY(_ps, _key)     (((_ps) << IA64_ITIR_PS) | \
+                                        (((_key) << IA64_ITIR_KEY)))
+
+/* Define Protection Key Register (PKR) */
+#define        IA64_PKR_V              0
+#define        IA64_PKR_WD             1
+#define        IA64_PKR_RD             2
+#define        IA64_PKR_XD             3
+#define        IA64_PKR_MBZ0           4
+#define        IA64_PKR_KEY            8
+#define        IA64_PKR_KEY_LEN        24
+#define        IA64_PKR_MBZ1           32
+
+#define        IA64_PKR_VALID          (1 << IA64_PKR_V)
+#define        IA64_PKR_KEY_MASK       (((__IA64_UL(1) << IA64_PKR_KEY_LEN) - 
1) \
+                                                       << IA64_PKR_KEY)
+
+#define        XEN_IA64_NPKRS          15      /* Number of pkr's in PV */
 
 #endif /* _ASM_IA64_XENKREGS_H */
diff -r 32825349924d -r 522a1932111f xen/include/asm-ia64/xenprocessor.h
--- a/xen/include/asm-ia64/xenprocessor.h       Mon Jul 30 16:01:05 2007 -0600
+++ b/xen/include/asm-ia64/xenprocessor.h       Mon Jul 30 16:07:11 2007 -0600
@@ -237,6 +237,19 @@ typedef union {
     u64 itir;
 } ia64_itir_t;
 
+typedef union {
+       u64 val;
+       struct {
+               u64 v  : 1;
+               u64 wd : 1;
+               u64 rd : 1;
+               u64 xd : 1;
+               u64 reserved1 : 4;
+               u64 key : 24;
+               u64 reserved2 : 32;
+       };
+} ia64_pkr_t;
+
 #define dump_execution_state() printk("FIXME: implement ia64 
dump_execution_state()\n");
 
 #endif // _ASM_IA64_XENPROCESSOR_H

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] [IA64] Declarations for PKR, Xen patchbot-unstable <=