Home | History | Annotate | Line # | Download | only in docs
VMEbus-RAM revision 1.1.4.2
      1  1.1.4.2  nathanw 	$NetBSD: VMEbus-RAM,v 1.1.4.2 2002/02/28 04:10:52 nathanw Exp $
      2  1.1.4.2  nathanw 
      3  1.1.4.2  nathanw NetBSD/mvme68k: VMEbus RAM card configuration
      4  1.1.4.2  nathanw ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      5  1.1.4.2  nathanw 
      6  1.1.4.2  nathanw NetBSD-mvme68k can be configured to support additional RAM boards
      7  1.1.4.2  nathanw accessed over the VMEbus.
      8  1.1.4.2  nathanw 
      9  1.1.4.2  nathanw This file describes where to configure your VMEbus RAM and how to
     10  1.1.4.2  nathanw point the kernel in the direction of it.
     11  1.1.4.2  nathanw 
     12  1.1.4.2  nathanw The MVME147 board has a fairly primitive VMEbus controller chip. The
     13  1.1.4.2  nathanw mapping of cpu address to VMEbus address is hardwired and so dictates
     14  1.1.4.2  nathanw what can be seen where by the 68030. From the cpu's perspective, A24
     15  1.1.4.2  nathanw space spans 0x00000000 to 0x00ffffff. However, onboard RAM also spans
     16  1.1.4.2  nathanw this space. With 8Mb of onboard RAM, only the top 8Mb of VMEbus A24
     17  1.1.4.2  nathanw space can be seen. With 16Mb onboard, there is no easy way to get at
     18  1.1.4.2  nathanw A24 space at all!
     19  1.1.4.2  nathanw 
     20  1.1.4.2  nathanw The other MVME boards have a more sophisticated VMEbus controller
     21  1.1.4.2  nathanw which can remap segments of VMEbus address space anywhere in the CPU's
     22  1.1.4.2  nathanw address space. This document will assume the remap is `transparent',
     23  1.1.4.2  nathanw ie. no translation is taking place. The same restriction as MVME147
     24  1.1.4.2  nathanw applies to these boards in that, without translation, a region of
     25  1.1.4.2  nathanw VMEbus address space is masked by onboard RAM. The size of this region
     26  1.1.4.2  nathanw depends entirely on the size of onboard RAM.
     27  1.1.4.2  nathanw 
     28  1.1.4.2  nathanw The best place for VMEbus RAM cards is somewhere in A32D32 VMEbus address
     29  1.1.4.2  nathanw space. Obviously, if your VMEbus RAM card doesn't respond to that space
     30  1.1.4.2  nathanw then you'll have to locate it elsewhere. Typically, you may find it
     31  1.1.4.2  nathanw responds to A24D16 only, in which case the CPU-relative address you need
     32  1.1.4.2  nathanw to specify below will be in the 16MB region starting at 0xZZZZZZZZ.
     33  1.1.4.2  nathanw 
     34  1.1.4.2  nathanw For A32D32, choose an address which is resonably close to the end of the
     35  1.1.4.2  nathanw MVME board's RAM. That is, if you have 32MB of onboard RAM, set the
     36  1.1.4.2  nathanw VMEbus RAM board to appear at A32:02000000.
     37  1.1.4.2  nathanw 
     38  1.1.4.2  nathanw This starting address needs to be written to the MVME board's NVRAM at
     39  1.1.4.2  nathanw address 0xfffe0764 for MVME147, and 0xff, as follows:
     40  1.1.4.2  nathanw 
     41  1.1.4.2  nathanw 	147Bug> mm fffe0764 ;L
     42  1.1.4.2  nathanw 	FFFE0764 00000000? 01000000   <cr>	<--- you type 01000000
     43  1.1.4.2  nathanw 	FFFE0768 00000000? .          <cr>
     44  1.1.4.2  nathanw 	147Bug>
     45  1.1.4.2  nathanw 
     46  1.1.4.2  nathanw Next, you need to configure the end address of VMEbus RAM. Assuming
     47  1.1.4.2  nathanw your RAM card is 8Mb in size, this would be 0x017fffff. You need to
     48  1.1.4.2  nathanw write this value to NVRAM address 0xfffe0768, as follows:
     49  1.1.4.2  nathanw 
     50  1.1.4.2  nathanw 	147Bug> mm fffe0768 ;L
     51  1.1.4.2  nathanw 	FFFE0768 00000000? 017fffff   <cr>	<--- you type 017fffff
     52  1.1.4.2  nathanw 	FFFE076c 00000000? .          <cr>
     53  1.1.4.2  nathanw 	147Bug>
     54  1.1.4.2  nathanw 
     55  1.1.4.2  nathanw You could obviously combine the above two steps.
     56  1.1.4.2  nathanw 
     57  1.1.4.2  nathanw If you have more than one VMEbus RAM card, you must configure them so
     58  1.1.4.2  nathanw that they appear physically contiguous in A32 address space. So, to add
     59  1.1.4.2  nathanw another 8Mb card in addition to the card above, it should be jumpered
     60  1.1.4.2  nathanw to start at 0x01800000. In this case, you would change NVRAM location
     61  1.1.4.2  nathanw 0xfffe0768 to be 0x01ffffff.
     62  1.1.4.2  nathanw 
     63  1.1.4.2  nathanw If NVRAM location 0xfffe0764 is zero, the kernel assumes you only have
     64  1.1.4.2  nathanw onboard RAM and will not attempt to use any VMEbus RAM.
     65  1.1.4.2  nathanw 
     66  1.1.4.2  nathanw 
     67  1.1.4.2  nathanw Some extra notes on VMEbus RAM cards
     68  1.1.4.2  nathanw ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     69  1.1.4.2  nathanw 
     70  1.1.4.2  nathanw So... You've got your nice shiny VMEbus RAM card up and running with
     71  1.1.4.2  nathanw NetBSD, and you're wondering why your system runs slower than it did
     72  1.1.4.2  nathanw with less RAM!
     73  1.1.4.2  nathanw 
     74  1.1.4.2  nathanw The simple answer is "Motorola got it wrong". (Or at least that's my
     75  1.1.4.2  nathanw opinion. If anyone can cure the following, let me know!)
     76  1.1.4.2  nathanw 
     77  1.1.4.2  nathanw In their infinite wisdom, the designers of the MVME147 decided that
     78  1.1.4.2  nathanw they would disable the 68030's cache on *any* access to the VMEbus.
     79  1.1.4.2  nathanw The upshot is that the cache only works for onboard RAM, not VMEbus
     80  1.1.4.2  nathanw RAM, hence your system runs slower. As far as I can see, the only
     81  1.1.4.2  nathanw way to cure this is to physically cut a trace on the circuit board
     82  1.1.4.2  nathanw and use the MMU to control caching on a page-by-page basis...
     83  1.1.4.2  nathanw 
     84  1.1.4.2  nathanw Anyhow, hopefully the above instructions have finally put to rest
     85  1.1.4.2  nathanw the most asked question about the mvme68k port.
     86  1.1.4.2  nathanw 
     87  1.1.4.2  nathanw Cheers,
     88  1.1.4.2  nathanw Steve Woodford: scw (a] netbsd.org
     89