Subject: Re: JavaStation1 saga continues
To: None <port-sparc@netbsd.org, uwe@ptc.spbu.ru>
From: None <eeh@netbsd.org>
List: port-sparc
Date: 04/19/2001 15:23:11
	> You may be able to put the kernel heap and I/O areas above the PROM,

	That's what I currently do.  KERNBASE is at E8000000 (used to be at
	region EF, but I moved again because of assumed alignment problems; I
	haven't booted the new region E8 kernel though).

You shouldn't have alignment problems at EF000000.

	Then in pmap_bootstrap4m I just do:

	#if 0 /* uwe: original code */
	        virtual_avail = (vaddr_t)p;
	#else /* uwe: XXX: skip OpenFirmware on MRCOFFEE */
	        virtual_avail = (vaddr_t)0xf0080000;
	#endif
	        virtual_end = VM_MAX_KERNEL_ADDRESS;


Hm.  That might work.  A couple of things to keep in mind:

The OBP may use RAM outside of the f0000000-f0080000 range.  
Bootloaders have RAM allocated to them, and sometimes I/O
mappings can also be out of that range.  On sun4u machines
it appears the PROM starts allocating virtual addresses from
ffffffff and works its way down.  It allocates them as needed
so there are no separations between memory and I/O mappings.

You need to check the PROM properties to determine what's 
available and not use ranges that have already been allocated.

Eduardo