aboutsummaryrefslogtreecommitdiff
path: root/sys/sparc64/include/ofw_nexus.h
diff options
context:
space:
mode:
authorThomas Moestl <tmm@FreeBSD.org>2002-01-02 18:27:13 +0000
committerThomas Moestl <tmm@FreeBSD.org>2002-01-02 18:27:13 +0000
commitca8712b098b36464d11a7dd20e2d0459121a2ace (patch)
tree340672f4fc1ef14cda5cb9c13bc47efc91a816f0 /sys/sparc64/include/ofw_nexus.h
parent477609fb13b77f8c6a7edb7bed45c08ceaa11a41 (diff)
downloadsrc-ca8712b098b36464d11a7dd20e2d0459121a2ace.tar.gz
src-ca8712b098b36464d11a7dd20e2d0459121a2ace.zip
Correct the defintion of struct ofw_upa_regs, and use it instead of
struct ofw_nexus_reg. Implement UPA device memory management in the nexus driver. Adapt the psycho driver to these changes, and do some minor cleanup work while being there.
Notes
Notes: svn path=/head/; revision=88823
Diffstat (limited to 'sys/sparc64/include/ofw_nexus.h')
-rw-r--r--sys/sparc64/include/ofw_nexus.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/sys/sparc64/include/ofw_nexus.h b/sys/sparc64/include/ofw_nexus.h
index c920a9cfc833..7ee0c401910e 100644
--- a/sys/sparc64/include/ofw_nexus.h
+++ b/sys/sparc64/include/ofw_nexus.h
@@ -41,7 +41,6 @@
struct upa_regs {
u_int32_t phys_hi;
- u_int32_t phys_mid;
u_int32_t phys_lo;
u_int32_t size_hi;
u_int32_t size_lo;
@@ -57,6 +56,11 @@ struct upa_ranges {
u_int32_t size_lo;
};
+#define UPA_REG_PHYS(r) \
+ (((u_int64_t)(r)->phys_hi << 32) | (u_int64_t)(r)->phys_lo)
+#define UPA_REG_SIZE(r) \
+ (((u_int64_t)(r)->size_hi << 32) | (u_int64_t)(r)->size_lo)
+
#define UPA_RANGE_CHILD(r) \
(((u_int64_t)(r)->child_hi << 32) | (u_int64_t)(r)->child_lo)
#define UPA_RANGE_PHYS(r) \