diff options
author | Miod Vallat <miod@cvs.openbsd.org> | 2006-04-17 18:26:29 +0000 |
---|---|---|
committer | Miod Vallat <miod@cvs.openbsd.org> | 2006-04-17 18:26:29 +0000 |
commit | bdd3b5767a97dc8033ee3aef6794580824c7814a (patch) | |
tree | 098386a0dff94882fc048cb24d02bf632d26dbf1 | |
parent | f47145b744ba492e88b0f0c20f3e0b43b555fec3 (diff) |
Better constant names for the MVME188 GCSR set.
-rw-r--r-- | sys/arch/mvme88k/dev/vme.c | 4 | ||||
-rw-r--r-- | sys/arch/mvme88k/include/mvme188.h | 19 | ||||
-rw-r--r-- | sys/arch/mvme88k/mvme88k/m188_machdep.c | 6 |
3 files changed, 16 insertions, 13 deletions
diff --git a/sys/arch/mvme88k/dev/vme.c b/sys/arch/mvme88k/dev/vme.c index 8872652eeb4..51e90a062a3 100644 --- a/sys/arch/mvme88k/dev/vme.c +++ b/sys/arch/mvme88k/dev/vme.c @@ -1,4 +1,4 @@ -/* $OpenBSD: vme.c,v 1.40 2005/11/25 22:14:31 miod Exp $ */ +/* $OpenBSD: vme.c,v 1.41 2006/04/17 18:26:26 miod Exp $ */ /* * Copyright (c) 2004, Miodrag Vallat. * Copyright (c) 1999 Steve Murphree, Jr. @@ -286,7 +286,7 @@ vmeattach(parent, self, args) u_int8_t sconc; vmevecbase = 0x80; /* Hard coded for MVME188 */ - sconc = *(volatile u_int8_t *)GLB1; + sconc = *(volatile u_int8_t *)MVME188_GLOBAL1; if (ISSET(sconc, M188_SYSCON)) printf(": system controller"); printf("\n"); diff --git a/sys/arch/mvme88k/include/mvme188.h b/sys/arch/mvme88k/include/mvme188.h index 25fd1894c95..43af4ceab2c 100644 --- a/sys/arch/mvme88k/include/mvme188.h +++ b/sys/arch/mvme88k/include/mvme188.h @@ -1,4 +1,4 @@ -/* $OpenBSD: mvme188.h,v 1.23 2006/04/15 22:31:47 miod Exp $ */ +/* $OpenBSD: mvme188.h,v 1.24 2006/04/17 18:26:28 miod Exp $ */ /* * Copyright (c) 1999 Steve Murphree, Jr. * All rights reserved. @@ -84,13 +84,16 @@ #define MVME188_VIRQV 0xfff85020 #define M188_IVEC 0x40 /* vector returned upon MVME188 int */ -#define MVME188_GCSR 0xfff86000 /* global control and status reg */ -#define GLB0 0xfff86001 -#define GLB1 0xfff86003 -#define GLB2 0xfff86005 -#define GLB3 0xfff86007 -#define M188_LRST 0x00000080 -#define M188_SYSCON 0x00000040 +#define MVME188_GLOBAL0 0xfff86001 /* global control and status regs */ +#define MVME188_GLOBAL1 0xfff86003 +#define M188_LRST 0x80 +#define M188_SYSCON 0x40 +#define MVME188_BRDID 0xfff86005 +#define MVME188_CGCSR0 0xfff86007 +#define MVME188_CGCSR1 0xfff86009 +#define MVME188_CGCSR2 0xfff8600b +#define MVME188_CGCSR3 0xfff8600d +#define MVME188_CGCSR4 0xfff8600f #define MVME188_UCSR 0xfff87000 /* utility control and status reg */ #define MVME188_BASAD 0xfff87004 /* base address reg */ #define MVME188_GLBRES 0xfff8700c /* global reset reg */ diff --git a/sys/arch/mvme88k/mvme88k/m188_machdep.c b/sys/arch/mvme88k/mvme88k/m188_machdep.c index 77c275fce79..5257ff7488d 100644 --- a/sys/arch/mvme88k/mvme88k/m188_machdep.c +++ b/sys/arch/mvme88k/mvme88k/m188_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: m188_machdep.c,v 1.14 2006/04/15 15:45:24 miod Exp $ */ +/* $OpenBSD: m188_machdep.c,v 1.15 2006/04/17 18:26:28 miod Exp $ */ /* * Copyright (c) 1998, 1999, 2000, 2001 Steve Murphree, Jr. * Copyright (c) 1996 Nivas Madhur @@ -178,12 +178,12 @@ m188_reset() /* clear and disable all interrupts */ *(volatile u_int32_t *)MVME188_IENALL = 0; - if ((*(volatile u_int8_t *)GLB1) & M188_SYSCON) { + if ((*(volatile u_int8_t *)MVME188_GLOBAL1) & M188_SYSCON) { /* Force a complete VMEbus reset */ *(volatile u_int32_t *)MVME188_GLBRES = 1; } else { /* Force only a local reset */ - *(volatile u_int8_t *)GLB1 |= M188_LRST; + *(volatile u_int8_t *)MVME188_GLOBAL1 |= M188_LRST; } *(volatile u_int32_t *)MVME188_UCSR |= 0x2000; /* clear SYSFAIL */ |