Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/sh3/include add SH3_{PHYS, P1SEG, P2SEG}_TO_{PHYS, P1S...
details: https://anonhg.NetBSD.org/src/rev/ec58be045392
branches: trunk
changeset: 480528:ec58be045392
user: msaitoh <msaitoh%NetBSD.org@localhost>
date: Fri Jan 14 19:09:35 2000 +0000
description:
add SH3_{PHYS,P1SEG,P2SEG}_TO_{PHYS,P1SEG,P2SEG} macros
diffstat:
sys/arch/sh3/include/cpu.h | 11 ++++++++++-
1 files changed, 10 insertions(+), 1 deletions(-)
diffs (25 lines):
diff -r 67494fe5bee1 -r ec58be045392 sys/arch/sh3/include/cpu.h
--- a/sys/arch/sh3/include/cpu.h Fri Jan 14 18:37:58 2000 +0000
+++ b/sys/arch/sh3/include/cpu.h Fri Jan 14 19:09:35 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: cpu.h,v 1.5 1999/12/24 08:29:23 msaitoh Exp $ */
+/* $NetBSD: cpu.h,v 1.6 2000/01/14 19:09:35 msaitoh Exp $ */
/*-
* Copyright (c) 1990 The Regents of the University of California.
@@ -125,6 +125,15 @@
#define SH3_P4SEG_BASE 0xe0000000
#define SH3_P4SEG_END 0xffffffff
+#define SH3_PHYS_MASK 0x1fffffff
+#define SH3_P1234SEG_SIZE 0x20000000
+
+#define SH3_P1SEG_TO_PHYS(x) ((unsigned)(x) & SH3_PHYS_MASK)
+#define SH3_P2SEG_TO_PHYS(x) ((unsigned)(x) & SH3_PHYS_MASK)
+#define SH3_PHYS_TO_P1SEG(x) ((unsigned)(x) | SH3_P1SEG_BASE)
+#define SH3_PHYS_TO_P2SEG(x) ((unsigned)(x) | SH3_P2SEG_BASE)
+#define SH3_P1SEG_TO_P2SEG(x) ((unsigned)(x) | SH3_P1234SEG_SIZE)
+
/*
* pull in #defines for kinds of processors
*/
Home |
Main Index |
Thread Index |
Old Index