<!doctype linuxdoc system>
 
<article>
 
<title> XFree86 3.1.1 P9000 Server Release Notes
<author> Erik Nygren (<it>nygren@mit.edu</it>)
<date> 1995 January 15
<toc>
 
<sect> Change Log <p>
<descrip>
<tag/1995.01.15:/
	<itemize>
	<item>
	  Fixed problem with line capping in accelerated line
	  drawing. (Chris Mason)
	<item>
	  Fixed p9000QuadAlu[GXset] to be ~0 rather than 1.  (Erik Nygren)
	</itemize>
<tag/1995.01.14:/
	<itemize>
	<item>
	 <tt>Clocks</tt> line is no longer used in <tt>XF86Config</tt> file.
	 Operation should now be consistent with the operation of the
	 other servers which use programmable clocks. (Erik Nygren)
	<item>
	 Users with 1MB cards can now explicitly specify <tt>videoRam</tt>
	 in the <tt>XF86Config</tt> file when autoprobing fails.
	 The new <tt>vram_128</tt> option may also be used to force
	 the detection of 128Kx8 SIMM's. (Erik Nygren)
	<item>
	 Added p9000line.c and p9000seg.c for accelerated line drawing code
	 using the p9000 quad/clipping engine.  Blazingly fast for 1 clipping
	 rectangle, could be made faster for multiple clipping regions by
	 using software clipping. There is still a bug which causes
	 xtest to report <tt>Cap style incorrect for thin line and
	 CapNotLast</tt> for the <tt>XDrawLines</tt> tests but not
	 for the <tt>XDrawLine</tt> or <tt>XDrawSegments</tt> tests
	 [fixed in 1995.01.15 patch]. (Chris Mason)
	<item>
	 Changed p9000blt.c, and p9000win.c to wait for the quad/blit engine
	 to be free.  Before a quad/blit, check SR_ISSUE_QBN, then blit, then
	 when all blits are done, do a p9000QBNotBusy. (Chris Mason)
	<item>
	 Changed p9000init.c to clear the screen using the quad meta coord
	 drawing mode.  Appears the rect mode does not update the CINDEX
	 register correctly.  Changed the color to 1 (black) from 0. (Chris)
	<item>
	 Added p9000QuadAlu.  When drawing a quad, the p9000 equivalent to X's
	 source	is the foreground mask.  When bliting/pixel8ing/pixel1ing,
 	 it is the p9000 source mask and the p9000alu lookup table should be
 	 used. (Chris Mason)
	<item>
	 Added some more registers to p9000reg.h. (Chris Mason)
	</itemize>
<tag/1994.09.20:/
	<itemize>
	<item>
	  Fixed problem which prevented 16 bpp modes from working (Erik Nygren)
	</itemize>
<tag/1994.09.16:/
	<itemize>
	<item>
	  Added screen blanking support for 16 bpp and 32 bpp modes.
	  Screen blanking now powers down the RAMDAC rather than
	  just changing the planemask. (Chris Mason, Erik Nygren)
	<item>
	  Fixed more problems caused by switch to <tt>XF86Config</tt>
	  (Erik Nygren)
	<item>
	  Possible fix to maxclock for Orchid P9000 (Harry Langenbacher,
	  Erik Nygren)
	</itemize>
<tag/1994.09.15:/
	<itemize>
	<item>
	  Now almost always works with <tt>XF86Config</tt> changes
	  (Erik Nygren)
	<item>
	  Cursor code looks at VTSema before writing to RAMDAC.
	  This had been causing the x11perf server crash (Erik Nygren)
	</itemize>
<tag/1994.09.08:/
	<itemize>
	<item>
	  Fixed problem with xdm and restarting the server (Erik Nygren)
	<item>
	  Fixed and enabled ImageRead in CopyArea (Chris Mason)
	<item>
	  Made informational comments conform to standard :-) (Erik Nygren)
	</itemize>
<tag/1994.09.05:/
	<itemize>
	<item>
	  Fixed BIOS probe for Viper PCI (Bob Hollinger)
	<item>
	  Fixes to Orchid P9000 support (Harry Langenbacher)
	<item>
	  Changing of datatypes in clock code (Harry Langenbacher)
	<item>
	  Fixed clock and misc reg restoration so now works fine with svgalib
	  (Chris Mason, Harry, Erik)
	</itemize>
<tag/1994.08.29:/
	<itemize>
	<item>
	  Increased number of memory regions in xf86_OSlib.h from 2 to 3
	  as needed by the Viper PCI (Erik Nygren)
	<item>
	  Changed method of short pauses in p9000vga.c to outb(0x80,0) (Erik)
	<item>
	  Rewrote routines to determine sysconfig from horizontal resolution.
	  Also added check for valid hres to probe. (Erik Nygren)
	<item>
	  Added MoveWindow acceleration for all depths.  Opaque move even
	  looks nice at 32bpp now!  (Chris Mason)
	<item>
	  Minor fixes to acceleration.  Acceleration is now enabled
	  by default (Chris Mason)
	<item>
	  Added <tt>"noaccel"</tt> option (Erik Nygren)
	<item>
	  Added some fixes for Viper PCI (Matt Thomas)
	</itemize>
<tag/1994.07.21:/
	<itemize>
	<item>
	  Preliminary Viper PCI support - totally untested so disabled
	  (Erik Nygren)
	<item>
	  Preliminary Orchid P9000 support - incomplete and totally
	  untested so disabled (Erik Nygren)
	<item>
	  Preliminary accelerated support - incomplete and not fully tested
	  so disabled (Erik Nygren and Chris Mason)
	</itemize>
<tag/1994.07.08:/
	<itemize>
	<item>
	  16 and 32 bpp TrueColor support (Erik Nygren)
	<item>
	  Color restoration hopefully fixed (Erik Nygren)
	<item>
	  Changes to how <tt>"Modes"</tt> line in Xconfig is processed
	<item>
	  Removed banking support   :-(
	</itemize>
</descrip>

I've started adding in support for other cards and for acceleration.
Due to its untested nature, it is disabled.  A define at the top of
<tt>p9000.h</tt> controls all of these features.  The Viper PCI code is
untested and probably won't work the first time!  The Orchid P9000
code is incomplete and is waiting for a few mods by Harry to change the
way it deals with the clock.  The acceleration code has been started
on but probably won't work.  It's provided more to give our developers
a common base to start from.  Notice the new global variable
<tt>p9000BytesPerPixel</tt>, BTW.  Before working on any acceleration, please
contact <it>nygren@mit.edu</it> so we don't duplicate efforts.  The code
in <tt>p9000blt.c</tt> should work, but the stuff in <tt>p9000im.c</tt>
probably won't.

For Diamond Viper PCI owners, you'll need to get the <tt>PCIDUMP.EXE</tt>
program from the Unixware P9000 server for now.  Run it under DOS and
use the values to fill in <tt>MemBase</tt> and <tt>IOBase</tt> in the
<tt>Device</tt> section of <tt>XF86Config</tt>.  These values will change
whenever you move cards around or add cards.

I've started adding in support for other cards and for acceleration.
Due to its untested nature, much of it is disabled.  A define at the top of
<tt>p9000.h</tt> controls all of these features.  

<sect> Supported Cards <p> 

<sect1> Diamond Viper VLB <p>
 All Viper VLB's should work with this server, hopefully&hellip;  :-) Due
to Diamond's putting the same BIOS in some Viper VLB's as are used in
Viper PCI's, the probe may detect you have a Viper PCI when you really
have a Viper VLB.  If this happens, put <tt>chipset "vipervlb"</tt>
into your <tt>XF86Config</tt> file.

<sect1> Diamond Viper PCI <p>
This should now work, thanks to help from Bob Hollinger and Matt Thomas.
You may to specify the chipset <tt>"viperpci"</tt> in your <tt>XF86Config</tt>
file.
You'll also need to specify an <tt>IOBase</tt> and a <tt>MemBase</tt>.
You can obtain these values with <tt>PCIDUMP.EXE</tt>.
This program may be obtained
by sending email to <it>xserver@summit.novell.com</it> with the two lines:
<verb>
send
*p9k
</verb>
You should run this program and change these values after you
add more PCI cards or move existing cards to different slots.
According to David DeWolfe (<it>SXDJD@orca.alaska.edu</it>),
you need to run <tt>PCIDUMP.EXE</tt> after a clean boot
to DOS (with no <tt>AUTOEXEC.BAT</tt> or <tt>CONFIG.SYS</tt>).
This may be accomplished by holding down the <tt>SHIFT</tt>
key while <tt>DOS</tt> is booting.

Eventually we would like to autodetect the <tt>IOBase</tt> and
<tt>memBase</tt>, but this doesn't yet work.

<sect> Orchid P9000 and random clones <p>
The Orchid P9000 and other cards based on the Weitek board design
(such as the STAR 2000) should now work.  Talk to
<it>harry@brain.jpl.nasa.gov</it>
if you have problems with this.  Specify the chipset <tt>"orchidp9000"</tt> in
the <tt>Device</tt> section of <tt>XF86Config</tt>

<sect> Viper Pro and other P9100 and P9130 cards (UNSUPPORTED!!!) <p>
These are NOT supported yet.  We don't have the hardware to write and
or test drivers for them on.  The docs I have says the P9100 has a
different interface than the P9000.  As a result, they may need an
entirely new server.  If you need support for one of these cards, you
should look into XInside's AcceleratedX.  It's a commercial product
that costs about &dollar;99.  Send email to <it>info@xinside.com</it>
for more information.  Their P9000 server is also much faster than
ours at present (but then this server is free :-)

<sect> Acceleration <p>
Some of the acceleration code is working, but
there are probably still bugs.  Only a very small number of
accelerated features have been implemented.  Before working on any
acceleration, please contact <it>nygren@mit.edu</it> so we don't duplicate
efforts.  Acceleration may be turned off with the <tt>"noaccel"</tt> option.
The following things are now accelerated:
<itemize>
   <item> Hardware cursor (8/16/32bpp)
   <item> MoveWindow (8/16/32bpp)
   <item> CopyArea (8bpp)
</itemize>

<sect> High Color and TrueColor <p>
Support for 16 and 24 bit truecolor is now supported.  Note that 24
bit color is really 32 bits per pixel.  Use the <tt>-bpp</tt> option when
starting the server.  Examples:
<verb>
	startx -- -bpp 32
	startx -- -bpp 16
	startx -- -bpp 16 -weight 555
	startx -- -bpp 16 -weight 565
</verb>
Note that many programs do not yet work properly with these modes.
Don't tell me.  Tell the authors unless they've already fixed it.
It's their fault&hellip  :-)

Example problems:
<descrip>
   <tag/xv 3.00/     Works fine in 32 bpp and in 16 bpp with 24 bit images.
		     Has problems with colors in 8 bit images in 8 bpp mode.
   <tag/Mosaic 2.1/  Has problems with colormap in both 16 bpp and 32 bpp.
		     Newer versions of Mosaic such as 2.4 do work.
   <tag/mpeg_play/   Doesn't work at all in 16 bpp mode.  Works fine
  		     24 bpp mode when compiled with -DRS6000 and when
		     run with ``<tt>-dither color</tt>''
   <tag/xpaint 2.1/   Works great in both modes but has a bug in the
                     color requester for the selection tool.
		     I think later versions may have fixed this.
</descrip>

<sect> Random Notes <p>
Text restoration should now be fixed.  Color restoration should
also be fixed.  You can now even run the server at the same time as svgalib
programs!!!

Diamond has actually been fairly open and helpful.  No NDA's were
signed by anyone who wrote code and Diamond claims that none of the
information they provided is proprietary.

One unresolved issue is the maximum clock speed.  It is currently set
to 135 MHz with a warning printed over 110 MHz.  Diamond claims that
this is the max in their docs, but examination has shown some Viper's
to contain 110 MHz bt485's.  Without 135 MHz, it is not possible for
people to with large monitors to run at 1280x1024.  Diamond claims
that all Vipers have 135MHz bt485's or compatibles.  If you have
something slower, call their tech support and they will send you
a RMA to get the board replaced.

<sect> Operating System Notes <p>
Any operating system that can memory map linear regions in really
high memory should work.  This should include Linux, FreeBSD, SVR4,
and more.

<sect1> NetBSD <p>
If you have NetBSD, you will need to install the aperture driver.
Extract the file <tt>apNetBSD.shar</tt>
(in <tt>xc/programs/Xserver/hw/xfree86/etc/apNetBSD.shar</tt>) and read
the <tt>README</tt> contained therein.

<sect> XF86Config <p>
The <tt>modes</tt> line in the <tt>XF86Config</tt> file is now handled
differently.
The virtual line is now ignored entirely.  Each mode on the mode
line is looked at and the first usable mode is selected (ie the first
one which works with available memory, etc).  Any other modes which
are valid and have the same dimensions are also used.  And other modes
are ignored.

The current supported keywords in the <tt>Device</tt> section
of the <tt>XF86Config</tt> file are:
<descrip>
   <tag/VideoRAM/	1024 or 2048  (use 2048 for ``3MB'' Orchid P9000's)
   <tag/ChipSet/	<tt>"vipervlb"</tt> or <tt>"viperpci"</tt> or
			<tt>"orchidp9000"</tt>
   <tag/MemBase/	
			<descrip>
			<tag/Viper VLB:/ 0xA0000000 or 0x20000000 or 0x80000000
<!-- Converted square brackets to parentheses -->
				(0x80000000 is default if none spec'd)
			<tag/Orchid P9000:/ 0xC0000000 or 0xD0000000 or
				 0xE0000000
				(this MUST be set to correspond to the jumpers)
			<tag/Viper PCI:/ any value corresponding to the output
				of <tt>PCIDUMP.EXE</tt>
			</descrip>
   <tag/IOBase/		
			<descrip>
			<tag/Viper PCI:/ any value corresponding to the output
				of <tt>PCIDUMP.EXE</tt>
			<tag/Others:/ unused
			</descrip>
   <tag/Clocks/		any values between 25 and 135 corresponding to the
			clocks for the mode entries being used.
			This line may now be omitted and clocks will
			be matched automatically.
   <tag/Option/		<descrip>
			<tag/&dquot;sw_cursor&dquot;/
			   use software cursor
			<tag/&dquot;vram_128&dquot;/
			   use if you have 1024K VRAM in 128Kx8 SIMMS
			<tag/&dquot;sync_on_green&dquot;/
			   generate sync pulses on the green signal.  Most
			   (all?) P9000 based boards don't support this.
			<tag/&dquot;noaccel&dquot;/
			   do not do hardware acceleration if
				it's causing problems for you
			</descrip>
   <tag/Modes/		almost any valid mode (there are constraints on
				the horiz res so not all values are possible)
			
</descrip>
The current supported keywords in the Display section
of the <tt>XF86Config</tt> file are:
<descrip>
   <tag/Depth/
		<descrip>
		<tag/8:/ use 8 bits per pixel for 256 colors (default)
		<tag/15 or 16:/ use 16 bits per pixel for up to 65K colors
		<tag/24 or 32:/ use 32 bits per pixel (sparse 24 bpp)
				for up to 16 million colors
		</descrip>
   <tag/Weight/		555 or 565 if Depth is 15 or 16.  Otherwise this
				is ignored.  These are the Red, Green,
				and Blue bits per pixel (default=565)
</descrip>
Here's a portion of a sample <tt>XF86Config</tt> file for the Viper VLB:
<verb>
Section "Device"
    Identifier "ViperVLB"
    VendorName "Diamond"
    BoardName "Viper VLB"
    Videoram 2048                        # This is mandatory
    Membase 0x80000000                   # This is mandatory on non-ViperVLB's
    IOBase  0xe000			 # Use this ONLY on ViperPCI's
EndSection

Section "Screen"
    Driver "accel"
    Device "ViperVLB"
    Monitor "NEC4FGe"
    Subsection "Display"
	Depth 8   # This line is optional
        Modes "1024x768" "800x600"
    EndSubsection
EndSection
</verb>

<sect> Known Bugs <p>
There are currently problems with the server when used in conjunction
with xdm, olvwm, and VT switching under Linux.  

If the cursor changes while you're in a VT, the cursor won't look
right when you return from the VT until it is moved between windows
(and changes color and shape).

Autoprobing doesn't always properly detect cards with 1024K of VRAM.
If you have a problem with this, try putting <tt>VideoRAM 1024</tt>
into the <tt>Device</tt> section of your <tt>XF86Config</tt> file.  If
this still doesn't help, try adding <tt>Option "vram_128"</tt>.

<sect> Credits <p>
Major contributors to P9000 code:
<itemize>
<item> Erik Nygren (<it>nygren@mit.edu</it>)
<item> Harry Langenbacher (<it>harry@brain.jpl.nasa.gov</it>)
<item> Chris Mason (<it>mason@mail.csh.rit.edu</it>) 
</itemize>
Thanks to Matt Thomas (<it>thomas@lkg.dec.com</it>) and Bob Hollinger
(<it>bob@interaccess.com</it>) for helping to get the Viper PCI server working.

Special thanks to David Moews (<it>dmoews@xraysgi.ims.uconn.edu</it>)
whose banking patch could unfortunately not be included.

Special thanks to Henrik Harmsen (<it>d9hh@dtek.chalmers.se</it>)
whose 16bpp and 32bpp accelerated blit code won't be included until 
the next XFree86 release.

Thanks to Andy, David, Dave, Michael, Bob, all the XFree86 core team
people, and everyone else!

During the course of the next few months, people will be working on
acceleration, etc.  Please send any patches to me (<it>nygren@mit.edu</it>).

<verb>
$XConsortium: P9000.sgml,v 1.4 95/01/27 16:14:28 kaleb Exp $
$XFree86: xc/programs/Xserver/hw/xfree86/doc/sgml/P9000.sgml,v 3.7 1995/01/25 11:08:51 dawes Exp $
</verb>

</article>
