From 120825c1e2c0d1fac57f3692ae7fe3194fbd0b3c Mon Sep 17 00:00:00 2001 From: Ali Saidi Date: Tue, 18 May 2004 20:11:58 -0400 Subject: Added ALPHA_ACCESS_BASE to get rid of machine_defs.h --- system/alpha/console/console.c | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) (limited to 'system/alpha/console') diff --git a/system/alpha/console/console.c b/system/alpha/console/console.c index 5e9e49ce1..afdf00362 100644 --- a/system/alpha/console/console.c +++ b/system/alpha/console/console.c @@ -15,7 +15,6 @@ typedef unsigned int uint32; #define CONSOLE #include "alpha_access.h" -#include "machine_defs.h" #if 0 #include "new_aouthdr.h" @@ -34,8 +33,7 @@ typedef unsigned int uint32; #define K1BASE 0xfffffc8000000000 #define KSEG_TO_PHYS(x)(((ul)x) & ~KSEG) -#define CDR ((volatile DevConsoleRegisters *) \ - (__MAGIC_ZONE(0, 0, MAGIC_ZONE_BDOOR_DEV) + __MAGIC_BDOOR_CNSLE_OFFS)) +#define ALPHA_ACCESS_BASE 0xfffffc8000a00000 #define PHYS_TO_K1(_x) (K1BASE|(_x)) @@ -118,7 +116,7 @@ void InitConsole(void) char GetChar() { - struct AlphaAccess *k1Conf = (struct AlphaAccess *)(__MAGIC_ZONE(0, 0, MAGIC_ZONE_EV5_ALIAS)); + struct AlphaAccess *k1Conf = (struct AlphaAccess *)(ALPHA_ACCESS_BASE); return k1Conf->inputChar; } @@ -130,7 +128,7 @@ void PutChar(char c) #if 0 *(int*) PHYS_TO_K1(SLOT_D_COM1<<5) = c; #endif - struct AlphaAccess *k1Conf = (struct AlphaAccess *)(__MAGIC_ZONE(0, 0, MAGIC_ZONE_EV5_ALIAS)); + struct AlphaAccess *k1Conf = (struct AlphaAccess *)(ALPHA_ACCESS_BASE); k1Conf->outputChar = c; } @@ -144,7 +142,7 @@ int main(int argc, char **argv) { int x,i; - struct AlphaAccess *k1Conf = (struct AlphaAccess *)(__MAGIC_ZONE(0, 0, MAGIC_ZONE_EV5_ALIAS)); + struct AlphaAccess *k1Conf = (struct AlphaAccess *)(ALPHA_ACCESS_BASE); ui *k1ptr,*ksegptr; @@ -828,7 +826,7 @@ unixBoot(int go, int argc, char **argv) int i; for (i=1;i