summaryrefslogtreecommitdiffstats
path: root/sys/sparc64/include
diff options
context:
space:
mode:
Diffstat (limited to 'sys/sparc64/include')
-rw-r--r--sys/sparc64/include/asi.h20
-rw-r--r--sys/sparc64/include/cmt.h39
-rw-r--r--sys/sparc64/include/fireplane.h40
-rw-r--r--sys/sparc64/include/jbus.h39
4 files changed, 132 insertions, 6 deletions
diff --git a/sys/sparc64/include/asi.h b/sys/sparc64/include/asi.h
index 9371378..90dc3f3 100644
--- a/sys/sparc64/include/asi.h
+++ b/sys/sparc64/include/asi.h
@@ -33,7 +33,7 @@
#define _MACHINE_ASI_H_
/*
- * Standard v9 asis
+ * Standard v9 ASIs
*/
#define ASI_N 0x4
#define ASI_NL 0xc
@@ -51,7 +51,7 @@
#define ASI_SNFL 0x8b
/*
- * UltraSPARC extensions. ASIs limited to a certain family are annotated.
+ * UltraSPARC extensions - ASIs limited to a certain family are annotated.
*/
#define ASI_PHYS_USE_EC 0x14
#define ASI_PHYS_BYPASS_EC_WITH_EBIT 0x15
@@ -91,9 +91,12 @@
#define ASI_INTR_RECEIVE 0x49
#define ASI_UPA_CONFIG_REG 0x4a /* US-I, II */
-#define ASI_FIREPLANE_CONFIG_REG 0x4a /* US-III Cu */
-#define AA_FIREPLANE_CONFIG 0x0 /* US-III Cu */
-#define AA_FIREPLANE_ADDRESS 0x8 /* US-III Cu */
+#define ASI_FIREPLANE_CONFIG_REG 0x4a /* US-III{,+}, IV{,+} */
+#define AA_FIREPLANE_CONFIG 0x0 /* US-III{,+}, IV{,+} */
+#define AA_FIREPLANE_ADDRESS 0x8 /* US-III{,+}, IV{,+} */
+#define AA_FIREPLANE_CONFIG_2 0x10 /* US-IV{,+} */
+
+#define ASI_JBUS_CONFIG_REG 0x4a /* US-IIIi{,+} */
#define ASI_ESTATE_ERROR_EN_REG 0x4b
#define AA_ESTATE_CEEN 0x1
@@ -153,6 +156,11 @@
#define ASI_IIU_INST_TRAP 0x60 /* US-III family */
+#define ASI_INTR_ID 0x63 /* US-IV{,+} */
+#define AA_INTR_ID 0x0 /* US-IV{,+} */
+#define AA_CORE_ID 0x10 /* US-IV{,+} */
+#define AA_CESR_ID 0x40 /* US-IV{,+} */
+
#define ASI_ICACHE_INSTR 0x66
#define ASI_ICACHE_TAG 0x67
#define ASI_ICACHE_SNOOP_TAG 0x68 /* US-III family */
@@ -179,7 +187,7 @@
/*
* With the advent of the US-III, the numbering has changed, as additional
- * registers were inserted in between. We retain the original ordering for
+ * registers were inserted in between. We retain the original ordering for
* now, and append an A to the inserted registers.
* Exceptions are AA_SDB_INTR_D6 and AA_SDB_INTR_D7, which were appended
* at the end.
diff --git a/sys/sparc64/include/cmt.h b/sys/sparc64/include/cmt.h
new file mode 100644
index 0000000..cdeed29
--- /dev/null
+++ b/sys/sparc64/include/cmt.h
@@ -0,0 +1,39 @@
+/*-
+ * Copyright (c) 2010 Marius Strobl <marius@FreeBSD.org>
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ * $FreeBSD$
+ */
+
+#ifndef _MACHINE_CMT_H_
+#define _MACHINE_CMT_H_
+
+#define INTR_ID_ID_SHIFT (0)
+#define INTR_ID_ID_SIZE (10)
+#define INTR_ID_ID_MASK \
+ (((1 << INTR_ID_ID_SIZE) - 1) << INTR_ID_ID_SHIFT)
+
+#define INTR_ID_GET_ID(cr) ((cr & INTR_ID_ID_MASK) >> INTR_ID_ID_SHIFT)
+
+#endif /* _MACHINE_CMT_H_ */
diff --git a/sys/sparc64/include/fireplane.h b/sys/sparc64/include/fireplane.h
new file mode 100644
index 0000000..8348954
--- /dev/null
+++ b/sys/sparc64/include/fireplane.h
@@ -0,0 +1,40 @@
+/*-
+ * Copyright (c) 2010 Marius Strobl <marius@FreeBSD.org>
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ * $FreeBSD$
+ */
+
+#ifndef _MACHINE_FIREPLANE_H_
+#define _MACHINE_FIREPLANE_H_
+
+#define FIREPLANE_CR_AID_SHIFT (17)
+#define FIREPLANE_CR_AID_SIZE (10)
+#define FIREPLANE_CR_AID_MASK \
+ (((1 << FIREPLANE_CR_AID_SIZE) - 1) << FIREPLANE_CR_AID_SHIFT)
+
+#define FIREPLANE_CR_GET_AID(cr) \
+ ((cr & FIREPLANE_CR_AID_MASK) >> FIREPLANE_CR_AID_SHIFT)
+
+#endif /* _MACHINE_FIREPLANE_H_ */
diff --git a/sys/sparc64/include/jbus.h b/sys/sparc64/include/jbus.h
new file mode 100644
index 0000000..09c93b4
--- /dev/null
+++ b/sys/sparc64/include/jbus.h
@@ -0,0 +1,39 @@
+/*-
+ * Copyright (c) 2010 Marius Strobl <marius@FreeBSD.org>
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ * $FreeBSD$
+ */
+
+#ifndef _MACHINE_JBUS_H_
+#define _MACHINE_JBUS_H_
+
+#define JBUS_CR_JID_SHIFT (17)
+#define JBUS_CR_JID_SIZE (3)
+#define JBUS_CR_JID_MASK \
+ (((1 << JBUS_CR_JID_SIZE) - 1) << JBUS_CR_JID_SHIFT)
+
+#define JBUS_CR_GET_JID(cr) ((cr & JBUS_CR_JID_MASK) >> JBUS_CR_JID_SHIFT)
+
+#endif /* _MACHINE_JBUS_H_ */
OpenPOWER on IntegriCloud