--- cci/d/mem/locate.c 2019/07/28 12:24:19 1.1.1.1 +++ cci/d/mem/locate.c 2019/07/28 12:30:15 1.1.1.2 @@ -1,6 +1,11 @@ /* - This routine locate the error at - the board level. + This routine locate the error at the board level based on 3 possible + configurations set in OPTIONS: + - bit 4 reset: 1Mb boards only, numbered 0-n + - bit 4 set: 4Mb boards only, numbered 0-n + - bit 5 set: 20 Mb of "mixed" boards configured as: + boards 0-3 => 4 4Mb boards, addr 00-16 Mb + boards 4-7 => 4 1Mb boards, addr 17-20 Mb */ #include "definitions" extern struct OPTIONS OPTIONS; @@ -64,6 +69,19 @@ long addr,exp,act; register struct mcr *MCR = (struct mcr *)0xffffb000; register struct mer *MER = (struct mer *)0xffffb020; register struct mcbr *MCBR = (struct mcbr *)0xffffb008; + if(OPTIONS.mixed) { + if(( addr & 0x3fffffff ) <= 0x00ffffff ) { + if (!(loc4mb(addr,&board,&bank,&intl))) + return(0); } + else { + if (!(locboard(addr,&board,&bank,&intl))) + return(0); + else + board = ( board - 16 ) + 4; +/* - 16 + 4 => 4x4 Mb in 4 boards 0-3 ( locboard assumes n 1Mb boards 0-n) */ + } + } + else { if(OPTIONS.fourmb) { if (!(loc4mb(addr,&board,&bank,&intl))) @@ -71,6 +89,7 @@ long addr,exp,act; else { if (!(locboard(addr,&board,&bank,&intl))) return(0); } + } intl = *CPCR & 3; /* Read Memory Interleave status */ if (intl) { if (intl==1) intl=2; @@ -116,7 +135,7 @@ long bk, exp, act; writes("\n"); } /* - locate board and bank for 1 mbyte memory array + locate board and bank for 1 mbyte memory array in n 1Mb boards 0-n */ locboard(addr,board,bank,intl) long addr; @@ -156,7 +175,7 @@ long *board, *bank,*intl; return(1); } /* - locate board and bank for 4 mbyte memory array + locate board and bank for 4 mbyte memory array in n 4Mb boards 0-n */ loc4mb(addr,board,bank,intl) long addr;