Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 21 Feb 2018 15:15:32 +0000 (UTC)
From:      Nathan Whitehorn <nwhitehorn@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r329720 - head/sys/powerpc/include
Message-ID:  <201802211515.w1LFFW4h023164@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: nwhitehorn
Date: Wed Feb 21 15:15:31 2018
New Revision: 329720
URL: https://svnweb.freebsd.org/changeset/base/329720

Log:
  Add definitions for the new Radix MMU mode on POWER9+ CPUs.

Modified:
  head/sys/powerpc/include/pte.h

Modified: head/sys/powerpc/include/pte.h
==============================================================================
--- head/sys/powerpc/include/pte.h	Wed Feb 21 15:12:14 2018	(r329719)
+++ head/sys/powerpc/include/pte.h	Wed Feb 21 15:15:31 2018	(r329720)
@@ -125,6 +125,37 @@ struct lpteg {
 #define	LPTE_RW		LPTE_BW
 #define	LPTE_RO		LPTE_BR
 
+/* POWER ISA 3.0 Radix Table Definitions */
+#define	RPTE_VALID		0x8000000000000000ULL
+#define	RPTE_LEAF		0x4000000000000000ULL /* is a PTE: always 1 */
+#define	RPTE_SW0		0x2000000000000000ULL
+#define	RPTE_RPN_MASK		0x00FFFFFFFFFFF000ULL
+#define	RPTE_RPN_SHIFT		12
+#define	RPTE_SW1		0x0000000000000800ULL
+#define	RPTE_SW2		0x0000000000000400ULL
+#define	RPTE_SW3		0x0000000000000200ULL
+#define	RPTE_R			0x0000000000000100ULL
+#define	RPTE_C			0x0000000000000080ULL
+
+#define	RPTE_ATTR_MASK		0x0000000000000030ULL
+#define	RPTE_ATTR_MEM		0x0000000000000000ULL /* PTE M */
+#define	RPTE_ATTR_SAO		0x0000000000000010ULL /* PTE WIM */
+#define	RPTE_ATTR_GUARDEDIO	0x0000000000000020ULL /* PTE IMG */
+#define	RPTE_ATTR_UNGUARDEDIO	0x0000000000000030ULL /* PTE IM */
+
+#define	RPTE_EAA_MASK		0x000000000000000FULL
+#define	RPTE_EAA_P		0x0000000000000008ULL /* Supervisor only */
+#define	RPTE_EAA_R		0x0000000000000004ULL /* Read allowed */
+#define	RPTE_EAA_W		0x0000000000000002ULL /* Write (+read) */
+#define	RPTE_EAA_X		0x0000000000000001ULL /* Execute allowed */
+
+#define	RPDE_VALID		RPTE_VALID
+#define	RPDE_LEAF		RPTE_LEAF             /* is a PTE: always 0 */
+#define	RPDE_NLB_MASK		0x0FFFFFFFFFFFFF00ULL
+#define	RPDE_NLB_SHIFT		8
+#define	RPDE_NLS_MASK		0x000000000000001FULL
+
+
 #ifndef	LOCORE
 typedef	struct pte pte_t;
 typedef	struct lpte lpte_t;



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201802211515.w1LFFW4h023164>