Add a second direct map window to increase the maximum RAM this platform
can deal with from 1GB to 2GB. I have no way to test with >1GB because I don't have high enough density memory to get any one box over 1GB. However, I have tested it on xp1000 & ds10 with < 1GB of memory & have verified that it does no harm.
This commit is contained in:
parent
ef92fd8274
commit
cc3fdb5fc5
@ -413,37 +413,52 @@ static driver_t tsunami_driver = {
|
|||||||
static void
|
static void
|
||||||
pchip_init(volatile tsunami_pchip *pchip, int index)
|
pchip_init(volatile tsunami_pchip *pchip, int index)
|
||||||
{
|
{
|
||||||
#if 0
|
|
||||||
|
|
||||||
/*
|
int i;
|
||||||
* The code below, if active, would attempt to
|
|
||||||
* setup the DMA base and size registers of Window 0
|
/*
|
||||||
* to emulate the placement of the direct-mapped window
|
* initialize the direct map DMA windows.
|
||||||
* on previous chipsets.
|
|
||||||
*
|
*
|
||||||
* HOWEVER: doing this means that a 64-bit card at device 11
|
* leave window 0 untouched; we'll set that up for S/G DMA for
|
||||||
* would not be able to be setup for DMA.
|
* isa devices later in the boot process
|
||||||
*
|
*
|
||||||
* For now, we just trust the SRM console to set things up
|
* window 1 goes at 2GB and has a length of 1 GB. It maps
|
||||||
* properly. This works on the xp1000, but may need to be
|
* physical address 0 - 1GB. The SRM console typically sets
|
||||||
* to be revisited for other systems.
|
* this window up here.
|
||||||
*/
|
|
||||||
|
|
||||||
printf("initializing pchip%d\n", index);
|
|
||||||
pchip->wsba[0].reg = 1L | (1024*1024*1024U & 0xfff00000U);
|
|
||||||
pchip->wsm[0].reg = (1024*1024*1024U - 1) & 0xfff00000UL;
|
|
||||||
pchip->tba[0].reg = 0;
|
|
||||||
/*
|
|
||||||
* disable windows 1, 2 and 3
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
pchip->wsba[1].reg = (2UL*1024*1024*1024) | WINDOW_ENABLE;
|
||||||
pchip->wsba[1].reg = 0;
|
pchip->wsm[1].reg = (1UL*1024*1024*1024 - 1) & 0xfff00000UL;
|
||||||
pchip->wsba[2].reg = 0;
|
pchip->tba[1].reg = 0;
|
||||||
pchip->wsba[3].reg = 0;
|
|
||||||
|
/*
|
||||||
alpha_mb();
|
* window 2 goes at 3GB and has a length of 1 GB. It maps
|
||||||
#endif
|
* physical address 1GB-2GB.
|
||||||
|
*/
|
||||||
|
|
||||||
|
pchip->wsba[2].reg = (3UL*1024*1024*1024) | WINDOW_ENABLE;
|
||||||
|
pchip->wsm[2].reg = (1UL*1024*1024*1024 - 1) & 0xfff00000UL;
|
||||||
|
pchip->tba[2].reg = 1UL*1024*1024*1024;
|
||||||
|
|
||||||
|
/*
|
||||||
|
* window 3 is disabled. The SRM console typically leaves it
|
||||||
|
* disabled
|
||||||
|
*/
|
||||||
|
|
||||||
|
pchip->wsba[3].reg = 0;
|
||||||
|
alpha_mb();
|
||||||
|
|
||||||
|
if(bootverbose) {
|
||||||
|
printf("pchip%d:\n", index);
|
||||||
|
for (i = 0; i < 4; i++) {
|
||||||
|
printf("\twsba[%d].reg = 0x%lx\n",
|
||||||
|
i, pchip->wsba[i].reg);
|
||||||
|
printf("\t wsm[%d].reg = 0x%lx\n",
|
||||||
|
i, pchip->wsm[i].reg);
|
||||||
|
printf("\t tba[%d].reg = 0x%lx\n",
|
||||||
|
i, pchip->tba[i].reg);
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#define TSUNAMI_SGMAP_BASE (8*1024*1024)
|
#define TSUNAMI_SGMAP_BASE (8*1024*1024)
|
||||||
|
Loading…
Reference in New Issue
Block a user